Bootloader, booting from CD
Bootloader, booting from CD
Welcome
I want to write bootloader. It will be on floppy. I want this bootloader to boot CD, that is actually inserted.
Now I have simple bootloader that prints text on the screen.
Can someone give me some ideas about how to boot CD?
Thanks in advance
I want to write bootloader. It will be on floppy. I want this bootloader to boot CD, that is actually inserted.
Now I have simple bootloader that prints text on the screen.
Can someone give me some ideas about how to boot CD?
Thanks in advance
-
- Member
- Posts: 116
- Joined: Wed Oct 22, 2008 2:21 am
- Location: Roma,Italy
Re: Bootloader, booting from CD
Hello,
Easy way: Burn your floppy image with CD Burner software( in some cd burner software
there is a function to create cd boot)
Hard way(my favourite): Write your raw cd iso image and burn it to cd
Easy way: Burn your floppy image with CD Burner software( in some cd burner software
there is a function to create cd boot)
Hard way(my favourite): Write your raw cd iso image and burn it to cd
Re: Bootloader, booting from CD
I mean something diffrent.
I HAVE TO write my own bootloader, that boots CD.
I HAVE TO write my own bootloader, that boots CD.
Re: Bootloader, booting from CD
Why not boot straight from the CD with El Torito?
Re: Bootloader, booting from CD
I don't know how to do it.mrnoob wrote:Why not boot straight from the CD with El Torito?
Can you tell me more about it?
- 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:
Re: Bootloader, booting from CD
From our own wiki: Bootable CD. Please search in the future.
Re: Bootloader, booting from CD
But I don't want to create bootable CD. I want to make bootloader that will be reading from CD.
Re: Bootloader, booting from CD
So, do you want a bootloader that gets loaded from the floppy but then can read from a CD? or do you want a bootloader on a CD which can read from the CD?
In either case, you've been provided with the information to accomplish either task.
Also, I'm sure there are various BIOS Interrupts that you can use to read sectors and such. Do some research.
In either case, you've been provided with the information to accomplish either task.
Also, I'm sure there are various BIOS Interrupts that you can use to read sectors and such. Do some research.
Website: https://joscor.com
- Troy Martin
- Member
- Posts: 1686
- Joined: Fri Apr 18, 2008 4:40 pm
- Location: Langley, Vancouver, BC, Canada
- Contact:
Re: Bootloader, booting from CD
E: I don't think the BIOS ints would do too well with the 2352-byte sectors, so you'd probably be going for direct hardware access.
Re: Bootloader, booting from CD
Other than use the above mefords, you will need to write a ATAPI driver, you will need the above pdf for programming info.
Also you can look at DexOS ATAPI driver, to code a driver you need to start at the basic's and add more funtions etc.
Here is a example of a basic ATAPI driver i coded, it demos setting up vesa, going to pmode, drawing a basic GUI and a simple CD player (ATAPI driver) all in less than 512bytes, has it boots and runs from the boot sector of a floppy.
Also you can look at DexOS ATAPI driver, to code a driver you need to start at the basic's and add more funtions etc.
Here is a example of a basic ATAPI driver i coded, it demos setting up vesa, going to pmode, drawing a basic GUI and a simple CD player (ATAPI driver) all in less than 512bytes, has it boots and runs from the boot sector of a floppy.
- Attachments
-
- vesa.asm
- (2.18 KiB) Downloaded 132 times
-
- Ata_Atapi1.asm
- (5.79 KiB) Downloaded 108 times
-
- CdPod.asm
- (7.16 KiB) Downloaded 82 times
-
- Member
- Posts: 524
- Joined: Sun Nov 09, 2008 2:55 am
- Location: Pennsylvania, USA
Re: Bootloader, booting from CD
Some BIOSes have EDD extensions. These extensions include ATAPI support. If your bootloader loads your kernel while in real mode, you can use a modified int 0x13 interface to load it.
Specifications:
http://www.phoenix.com/NR/rdonlyres/9BE ... sedd11.pdf
Specifications:
http://www.phoenix.com/NR/rdonlyres/9BE ... sedd11.pdf
Re: Bootloader, booting from CD
I read some information about Int 13 h extensions and about ElTorito Specifaction and I managed to write what I want.
It looks:
I put CD with my bootloader into CDROM, then I remove it then I insert some bootable CD for example livecd of UBuntu i press enter and livecd shout be booted.
I read about ElTorito and I know that BootRecordVolume is in 17 sector, I can find there pointer to Booting Catalog and in Booting Catalog I find pointer to bootable image of CD.
To use sectors I use function 42h of int 13h.
Program works good in Bochs, it boots windows, linux and other CDs, but when I tests program in real it can not read bootable image.
Does someone knows what has happened?
It looks:
I put CD with my bootloader into CDROM, then I remove it then I insert some bootable CD for example livecd of UBuntu i press enter and livecd shout be booted.
I read about ElTorito and I know that BootRecordVolume is in 17 sector, I can find there pointer to Booting Catalog and in Booting Catalog I find pointer to bootable image of CD.
To use sectors I use function 42h of int 13h.
Program works good in Bochs, it boots windows, linux and other CDs, but when I tests program in real it can not read bootable image.
Does someone knows what has happened?
Re: Bootloader, booting from CD
i think it's because those extensions: Bochs BIOS have it, but your pc doesn't
Re: Bootloader, booting from CD
But when I checked function 41h of int 13h it shows that I have support. It shows even when I boot my computer from CD.
Interesting think is that reading is bad it means I want to read 17 sector offset 47h on CD(8847h) but my program reads from addres F247h.
It happens with every CD I boot. Isn't int 13h extensions standard in these days?
Interesting think is that reading is bad it means I want to read 17 sector offset 47h on CD(8847h) but my program reads from addres F247h.
It happens with every CD I boot. Isn't int 13h extensions standard in these days?