Page 1 of 1

kernel 200+18

Posted: Thu Nov 22, 2012 5:24 pm
by mihok
Hey everyone,

So Ive been trying out OS development and everything has gone pretty good so far. I can output to the VGA controller and clear the screen, etc

I dont really have a problem just a curious question about something that I accidently did and seem to be stuck with now. Reading the bare bones tutorial on how to boot from grub using start1 and start2 in my img file, I call the command kernel 200+18 and then call boot. Which had worked perfectly fine until I accidently typed too quickly and ended up typing kernel 200+19. Good news was that it still managed to boot but now it seems I have to call 19 now all the time, instead of 18?

This is supposed to be the address of where the kernel is im assuming, what does the +18 do and why am I able to run with 200+19 now?

Thanks!

Re: kernel 200+18

Posted: Thu Nov 22, 2012 5:38 pm
by VolTeK
mihok wrote:why am I able to run with 200+19 now?
We don't know, you tell us.


You have the source, and the tools to debug and find out what is at the address of 200+18.

Re: kernel 200+18

Posted: Thu Nov 22, 2012 5:40 pm
by thepowersgang
If I recall correctly, the +18/+19 is the size of the data to load in sectors (or some similarly sized block of data).

May I note that this technique of loading is rather sensitive to size changes, it's better to set up a full grub install on the disk (with a filesystem).

Re: kernel 200+18

Posted: Fri Nov 23, 2012 4:57 am
by egos
Yes, moreover you can make GRUB installation more convenient (look at my last post here). But I don't remember what CPU mode (RM or PM) is active when GRUB boots "pure" sectors. Maybe "pure" sectors are booted in RM :?: