Getting a OS going quickly.
Re:Getting a OS going quickly.
I don't want to run FritzOS. I am just cannibalizing some of its code. Is that OK? I compiled the above ASM instructions and now I want to put them onto a floppy. How do I make the compiled code into the boot strip on the floppy?
Thank you for your time,
Arrummzen
Thank you for your time,
Arrummzen
Re:Getting a OS going quickly.
dd if=<your boot.bin> of=/dev/<your floppy drive>
and reboot to test your code.
and reboot to test your code.
Re:Getting a OS going quickly.
Yep! It works! Will you give a link to some documents on protected mode and the BIOS functions. By the way, thanks for the link to your source code. MUCH essayer to understand the the BSD code. Is there a big table or something with a list of every X86 ASM instruction and every register with a brief description of each? I don't want a big document I just want the basics, 1 page devoted to each instruction or something.
Thank you for your time,
Arrummzen
Thank you for your time,
Arrummzen
Re:Getting a OS going quickly.
This is the Intel Instruction Set Refernece, it is 6.62mb in size but it gives you a complete description of each instruction.
ftp://download.intel.com/design/Pentium ... 547109.pdf
hope this helps.
ftp://download.intel.com/design/Pentium ... 547109.pdf
hope this helps.
Re:Getting a OS going quickly.
I believe he/she meant 'it's easier to understand than then BSD code'
Re:Getting a OS going quickly.
IMHO your code is was essayer for me to wrap my mind around. Its small and strait to the point.
Any idea ware I can get a hard copy of that pdf (without printing it?).
Thank you for your time,
Arrummzen
Any idea ware I can get a hard copy of that pdf (without printing it?).
Thank you for your time,
Arrummzen
Re:Getting a OS going quickly.
What about BIOS calls? Someone has to have put together a big reference book with all the BIOS call, CPU instructions and registers in it.
Thank you for your time,
Arrummzen
Thank you for your time,
Arrummzen
Re:Getting a OS going quickly.
I have another question. Whats the easiest way to get a C kernel loaded? I am using the gcc tools to compile/build my kernel. I more or less copied the FritzOS boot loader. I don't want to use a ASM and C kernel like Fritz douse. Is there anyway I can load my C kernel without ASM? If so, how do I declare main, how do compile and build it and then put it on the floppy (what are the commands)? What is the in-line ASM macro in gcc (I want to embed ASM code in my C code)?
Thank you for your time,
Arrummzen
Thank you for your time,
Arrummzen
Re:Getting a OS going quickly.
The easiest way (So I've been told) is to create your kernel in elf format and get GRUB to load it for you.
Try these: HelpPC (For BIOS Interrupts/Instruction set), Ralf Brown's Interrupt List (For...*drumroll*...interrupts and ports), the NASM manual for a description of the intel instructions, the intel opcode manual (Usually number 2 of a series of 3/processor. There was a recent link on here). All those are easily accessible via google, so I'm not gonna go find them for you.
Try these: HelpPC (For BIOS Interrupts/Instruction set), Ralf Brown's Interrupt List (For...*drumroll*...interrupts and ports), the NASM manual for a description of the intel instructions, the intel opcode manual (Usually number 2 of a series of 3/processor. There was a recent link on here). All those are easily accessible via google, so I'm not gonna go find them for you.
Re:Getting a OS going quickly.
use grub. there is msdos floppy disks with grub on them, all you have to do is copy your kernel file over to the grub disk, its that simple.James wrote: I have another question. Whats the easiest way to get a C kernel loaded? I am using the gcc tools to compile/build my kernel. I more or less copied the FritzOS boot loader. I don't want to use a ASM and C kernel like Fritz douse. Is there anyway I can load my C kernel without ASM? If so, how do I declare main, how do compile and build it and then put it on the floppy (what are the commands)? What is the in-line ASM macro in gcc (I want to embed ASM code in my C code)?
-- Stu --
Re:Getting a OS going quickly.
The Asmmbly command in GCC is in AT&T syntax...if you want NASM syntax in your C code, you do this:
#define inasm(s) asm( ".intel_syntax no_prefix" ); asm(s);asm(".att_syntax prefix" );
and in your main C code, do this ( with pk0.3 that I posted above ):
void start()
{
// stuff
// asm code in GCC:
inasm( "Your Assembly Stuff Here" );
inasm( "mov eax, 1\n
mov ebx, 2" );
}
#define inasm(s) asm( ".intel_syntax no_prefix" ); asm(s);asm(".att_syntax prefix" );
and in your main C code, do this ( with pk0.3 that I posted above ):
void start()
{
// stuff
// asm code in GCC:
inasm( "Your Assembly Stuff Here" );
inasm( "mov eax, 1\n
mov ebx, 2" );
}