Starting Kernel from Bootsector

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.
Post Reply
User avatar
ollie123
Member
Member
Posts: 26
Joined: Tue May 27, 2008 2:42 am
Location: Great Yarmouth, Norfolk, United Kingdom

Starting Kernel from Bootsector

Post by ollie123 »

I'm back with another question. How can I start my kernel from my bootsector? Do I need to manipulate the memory in any way? Is there code that I can add to my bootsector to start my kernel directly? I would appreciate a response.

Thanks,
Ollie :D.

PS: I'm sorry if I keep posting questions like this. I have only just started programming operating systems, and I keep running into bugs.
Last edited by ollie123 on Mon Jun 02, 2008 11:45 am, edited 1 time in total.
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:

Post by Combuster »

Assuming that you have at least followed the many tutorials around, what about them do you not understand?
"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 ]
User avatar
ollie123
Member
Member
Posts: 26
Joined: Tue May 27, 2008 2:42 am
Location: Great Yarmouth, Norfolk, United Kingdom

Post by ollie123 »

Combuster wrote:Assuming that you have at least followed the many tutorials around, what about them do you not understand?
There's alot of tutorials, which one should I pick? :(
NEW TO OPERATING SYSTEM DEVELOPMENT
Good OS Development Tutorials: http://www.brokenthorn.com/Resources/OSDevIndex.html
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:

Post by Combuster »

Try one. If it doesn't help go to the next and so on. Nine out of ten you'll have your answer before you see the end of the list :D
"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 ]
User avatar
suthers
Member
Member
Posts: 672
Joined: Tue Feb 20, 2007 3:00 pm
Location: London UK
Contact:

Post by suthers »

Though I should let you do this yourself I can recommend:
http://www.osdever.net/tutorials/loading_sectors.php
http://www.osdever.net/tutorials/ch01.php
Are you planning on working in real or protected mode?
Jules
User avatar
suthers
Member
Member
Posts: 672
Joined: Tue Feb 20, 2007 3:00 pm
Location: London UK
Contact:

Re: Starting Kernel from Bootsector

Post by suthers »

ollie123 wrote: PS: I'm sorry if I keep posting questions like this. I have only just started programming operating systems, and I keep running into bugs.
I think nobody here can claimed to have got very far in their OS before encountering a bug (certainly not me...). Its not meant to be easy...
huxuelei
Member
Member
Posts: 35
Joined: Tue May 27, 2008 8:32 am

Post by huxuelei »

why not use GRUB as your bootloader?
User avatar
ollie123
Member
Member
Posts: 26
Joined: Tue May 27, 2008 2:42 am
Location: Great Yarmouth, Norfolk, United Kingdom

Post by ollie123 »

huxuelei wrote:why not use GRUB as your bootloader?
I would use GRUB, but I still want to learn how to write bootsectors.
NEW TO OPERATING SYSTEM DEVELOPMENT
Good OS Development Tutorials: http://www.brokenthorn.com/Resources/OSDevIndex.html
indiocolifa
Member
Member
Posts: 41
Joined: Sat May 24, 2008 12:41 pm
Location: La Plata, Argentina

Post by indiocolifa »

If you can write some assembly, try to write your own simple bootloader. Its an excellent practice. My own bootloader is near complete.
Post Reply