Page 1 of 1

Complete Bootloader

Posted: Sat Dec 29, 2007 5:30 pm
by djnorthyy
Hey,

I have been tearing the internet apart for a tutorial(s) on how to develop a complete 2 stage bootloader. Eventually i would be nice to have it support network boot, although i know this is a big step!

I know there is always GRUB out there but I feel it would be a good learning tool and I am intent on developing every compont of my operating system myself. I know that is a lot to ask but I feel it is a challenge!

This bootloader needs to be able to load a kernel.bin file. 32bit protected mode. Is there anyway it could hadle 64bit as well? I know that would mean changing the kernel. The kernel would be coded in C/C++ as much as possible. The bootloader needs to be able to cope with all this.

Any link, docs, tutorials on this topic will be apprieated!

Harry.

Posted: Sat Dec 29, 2007 5:54 pm
by lukem95
osdever.net
grub source code
the osdev.org wiki
other sources... look through the project list

Bootloader

Posted: Sat Dec 29, 2007 8:07 pm
by djnorthyy
Thanks for that, i will check them out.

I have completed all the tutorials over at BrokenThorn apart from the MSVC++ one. Where can i go from here because this bootloader does not actually load a kernel file, it just displays text on the screen? Sorry if i am being completly stupid! :)

Harry.

Posted: Sat Dec 29, 2007 9:57 pm
by Dex
You could look at "OS Development for Dummies - OS Loader", that may help you.
http://alexfru.chat.ru/epm.html#los4d

Anything else?

Posted: Sun Dec 30, 2007 3:36 pm
by djnorthyy
Thanks, is there any advice on how to finish off the bootloader I developed from the tutorial over at BrokenThorn?

Posted: Sun Dec 30, 2007 6:03 pm
by lukem95
yeah, depending on the filesystem/bootmedium your using, you need to get your bootloader to:

+ write basic disk i/o driver using BIOS ints
+ write a basic filesystem driver, probably gonna be a FAT one
+ load the kernel (.bin is easiest) into memory
+ set up protected mode (optional)
+ jmp to the address you loaded the kernel at