Bootloader

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
shikhin
Member
Member
Posts: 274
Joined: Sat Oct 09, 2010 3:35 am
Libera.chat IRC: shikhin
Contact:

Re: Bootloader

Post by shikhin »

Uhm.... So how to convert the Kernel into ELF format. Any clues? Or am I wrong and something else needs to be done?
http://shikhin.in/

Current status: Gandr.
User avatar
quanganht
Member
Member
Posts: 301
Joined: Fri May 16, 2008 7:13 pm
Location: Hanoi, Vietnam

Re: Bootloader

Post by quanganht »

More readings, please. You can simply add a multiboot header to your binary file.
"Programmers are tools for converting caffeine into code."
shikhin
Member
Member
Posts: 274
Joined: Sat Oct 09, 2010 3:35 am
Libera.chat IRC: shikhin
Contact:

Re: Bootloader

Post by shikhin »

And how to do that. Can you explain a bit thoroughly, or tell me what shall I read? And further more, what is a multi boot header?
Can you explain this to me?
http://shikhin.in/

Current status: Gandr.
User avatar
JamesM
Member
Member
Posts: 2935
Joined: Tue Jul 10, 2007 5:27 am
Location: York, United Kingdom
Contact:

Re: Bootloader

Post by JamesM »

http://wiki.osdev.org/GRUB # See the line "See the [[multiboot specification]] if you..."
http://www.jamesmolloy.co.uk/tutorial_h ... nesis.html # Tells you what the multiboot header is about.
User avatar
Combuster
Member
Member
Posts: 9301
Joined: Wed Oct 18, 2006 3:45 am
Libera.chat IRC: [com]buster
Location: On the balcony, where I can actually keep 1½m distance
Contact:

Re: Bootloader

Post by Combuster »

Shikhin wrote:What is a multi boot header?
Have you even bothered to use google?
"Certainly avoid yourself. He is a newbie and might not realize it. You'll hate his code deeply a few years down the road." - Sortie
[ My OS ] [ VDisk/SFS ]
shikhin
Member
Member
Posts: 274
Joined: Sat Oct 09, 2010 3:35 am
Libera.chat IRC: shikhin
Contact:

Re: Bootloader

Post by shikhin »

Yeah! I found everything needed and guess now this thread is OFFICIALLY SOLVED.
http://shikhin.in/

Current status: Gandr.
CelestialMechanic
Member
Member
Posts: 52
Joined: Mon Oct 11, 2010 11:37 pm
Location: Milwaukee, Wisconsin

Re: Bootloader

Post by CelestialMechanic »

Shikhin,

In looking at the code for your boot sector, two errors leaped out at me.

1) You have 0xf8 for the media byte in the BPB (boot parameter block). The value 0xf8 is for hard drives. The rest of the values in the BPB are those for a 3.5 inch 1440K floppy. The value should be 0xf0.

2) You have the file name in lower case, "krnldr sys". FAT only recognizes upper case. When the file is copied to a FAT12/16 volume the name is converted to upper case, "KRNLDR SYS". If you change the case on the string ImageName it will match the case on the floppy and then you won't get a "file not found" error.

I hope this helps.
Microsoft is over if you want it.
Post Reply