I have a few questions regarding OS development that really have me stuck right now:
1. So say I have 2 seperate pieces of assembly code, how Can I write one to one sector of a cd (not a floppy, I don't have a floppy drive), and one to another?
2. I do not want to use grub, or any premade bootloaders, but all of the tutorials I have read on how to write my own seem to either not give any examples, or give one massive example with tons of extra features that are overcomplicated. How, in the very most basic form, can I run a second sector on a cd (like the one made above) without any error handling or extra features?
I am new to OS coding, so it would be nice If I could get some help with these.
Thanks!
Writing to alternate sectors on CD?
Hmmmm. Well, I've written up a nice tutorial on how to make a bootloader and/or an MBR -- but it's mostly for booting hard drive (& floppy) kernels. Booting a CD is tricky. And developing an OS on a CD is like doing a NY Times Sunday crossword puzzle in pen, times a million -- unless this is a RW CD?
I'd have to recommend getting a debug version of Bochs (at sourceforge, perhaps), building a hard disk image on your main drive (that part is really easy), and maybe using Norton Diskedit (it's in any Norton Utilities package) to write info to that disk image. My tutorial would help at that point -- I could email it.
I'd have to recommend getting a debug version of Bochs (at sourceforge, perhaps), building a hard disk image on your main drive (that part is really easy), and maybe using Norton Diskedit (it's in any Norton Utilities package) to write info to that disk image. My tutorial would help at that point -- I could email it.
I use a CD RW(actually a couple to speed things up), and I have a laptop sitting right next to me that I would rather use for testing, as I can look at my code and test at the same time (and I can also be sure that if something odd happens, its not the emulator).
It would be great if you could email me the tutorial as well! ( my email is [email protected])
Oh and, Is there another way besides Norton utilities? (Is Norton Utilities free?)
Thanks!
It would be great if you could email me the tutorial as well! ( my email is [email protected])
Oh and, Is there another way besides Norton utilities? (Is Norton Utilities free?)
Thanks!
- Steve the Pirate
- Member
- Posts: 152
- Joined: Fri Dec 15, 2006 7:01 am
- Location: Brisbane, Australia
- Contact:
- Combuster
- 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:
You can use your own bootloader in conjunction with the Bootable CD tutorial. The input is however a bootable floppy image.
The easiest way to boot from a CD is to use a bootable floppy image or hdd image, without a floppy drive, you will need a program that can making floppy image without a floppy, than you can add your program and bootloader to it.
Most cd burn software includes in the menu, a "make CD bootable", click on it and point it to your floppy image, that's it the cd will be bootable.
Note: When you boot from it, it will emulate a floppy and you can load the file with int 13h, but as soon as you move to PMode emulaton will stop.
Also this may help: http://board.flatassembler.net/topic.php?t=4415
Most cd burn software includes in the menu, a "make CD bootable", click on it and point it to your floppy image, that's it the cd will be bootable.
Note: When you boot from it, it will emulate a floppy and you can load the file with int 13h, but as soon as you move to PMode emulaton will stop.
Also this may help: http://board.flatassembler.net/topic.php?t=4415