flat assembler
Message board for the users of flat assembler.

Index > OS Construction > help about Assembly,Boachs,FritzOS(kernel),kernel.asm,

Author
Thread Post new topic Reply to topic
darius



Joined: 02 Dec 2005
Posts: 2
darius
hi to everyone,
I need an urgent help about assembly and os development!!
I will be very very happy if anybody gives me any idea,help,solution way...

My problem is to implement a clone of old DOS game(supaplex) on bare PC hardware.
So I will implement only the bare minumum parts necessary for the game.
but most of the startup code have been prapered already for me..

I use FAT12 boot loader.The boot sector source code will be supplied to me.
I am expected to implement a clone of DOS game ,supaplex.In order to achieve this,
ı need to modify the kernel sources.
The problem is to implement the game without the runtime help of any other OPERATING SYSTEM or SYSTEM BIOS.Thus I will have to improve the kernel given to me by
codding drivers for PIT,PIC and KEYBOARD.
But I do not know much thing about this ??
can anybody gives ideas about from where I should start??

KERNEL: the kernel is slightly modifed version of FritzOS .it contains basic code for a limited C library. ( MEMORY:memset ,strlen , I/O: inportb ,outportb ; CPU: cli,st,reboot; Console Output: printf ,gotoxy,clrscr,Print(C++) Console_input:getch ;
Stdarg.h )
These are very simple versions and do not conform to ANSI standards.
I can aslo use limited C++ functionality by using classes .
The program will begin at extern “C” void start () ,there are no command line parameters and the function cannot return.

So I have additional required functionalities for kernel:

• Setting up interrupt handlers and IDTR, additionally enabling them by sti
• Need to update the GDT to build the IDT (there are several items, research first)
• need to redirect IRQ0-IRQ7 from INT08h-INT0fh to higher interrupts (INT00h-INT1FH reserved for the CPU)
• A complete keyboard driver (interrupt driven, not polling – IRQ1) which can accept multiple keys at once (e.g.: SPACE+UP, etc)
• A timer driver (IRQ0)
• need to store a level in C++ code probably as a pre-populated array

but how I can do all this? I do not where to start ..


I have the os.tar.gz (FritzOS ) which contain the necessary system to compile my code and a generate a floppy image.

I can use PC emulator BOCHS

CPU state: Kernel must be prepare the IDTR and stay in protected mode.Since it will be evaluated by using the BOCHS debugger .

Required file from me:
Kernel32.cpp , kernel.asm (boot.asm and loader.asm is ready in advance)


So Can anybody help me how can I achieve above problem ???
Any resources, any experiment like this ,any idea , any starting idea , ... ??
As I sad before ,I even do not know from where I should start.
plz help..
Thank you in advance,
I am looking forward to hear from you!! Smile
Post 02 Dec 2005, 23:57
View user's profile Send private message Reply with quote
DC740



Joined: 01 Oct 2004
Posts: 74
Location: Argentina
DC740
looks like homework from the university.... what are you studying?? Rolling Eyes (I'm curious hehe Wink )
Post 03 Dec 2005, 01:16
View user's profile Send private message Reply with quote
Dex4u



Joined: 08 Feb 2005
Posts: 1601
Location: web
Dex4u
You do not need to set up "GDT" etc, for a Dos clone, as Dos is realmode, you only need that for pmode.
So you can also use BIOS int's, also you will need to implement any Dos int's that the game user's.
Maybe you will be best using unrealmode.
Your best bet is to use a cut down freedos, i have one down to 100k, that would run your program.
Post 03 Dec 2005, 13:25
View user's profile Send private message Reply with quote
crc



Joined: 21 Jun 2003
Posts: 637
Location: Penndel, PA [USA]
crc
Dex, the original poster said:

Quote:
The problem is to implement the game without the runtime help of any other OPERATING SYSTEM or SYSTEM BIOS.


This means that he can't use FreeDOS or any BIOS interrupts to develop the game.
Post 03 Dec 2005, 15:47
View user's profile Send private message Visit poster's website Reply with quote
Dex4u



Joined: 08 Feb 2005
Posts: 1601
Location: web
Dex4u
@crc, i must have mist that bit Embarassed .
Post 03 Dec 2005, 20:12
View user's profile Send private message Reply with quote
Nevar



Joined: 17 Nov 2005
Posts: 1
Location: Polska
Nevar
Quote:
The problem is to implement the game without the runtime help of any other OPERATING SYSTEM or SYSTEM BIOS.


I think that you mustn't use protected mode, and why you do not want to use BIOS interrupts ?
Post 04 Dec 2005, 00:05
View user's profile Send private message Visit poster's website Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2020, Tomasz Grysztar. Also on GitHub, YouTube, Twitter.

Website powered by rwasa.