booting from a cd.

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
crazygray1
Member
Member
Posts: 168
Joined: Thu Nov 22, 2007 7:18 pm
Location: USA,Hawaii,Honolulu(Seriously)

booting from a cd.

Post by crazygray1 »

I don't have a floppy drive and I want to boot from a cd. Only problem is I can't figure out how to read from a cd.

by the way I did check google.
Codname: Cipher
Working On: Design Doc(CFFS file system)
User avatar
crazygray1
Member
Member
Posts: 168
Joined: Thu Nov 22, 2007 7:18 pm
Location: USA,Hawaii,Honolulu(Seriously)

Post by crazygray1 »

I figure that you use int 13 and use the right drive number I think. But what would be the cd-rom drive number.
Codname: Cipher
Working On: Design Doc(CFFS file system)
User avatar
neon
Member
Member
Posts: 1567
Joined: Sun Feb 18, 2007 7:28 pm
Contact:

Post by neon »

If you wanted, you can just use use emulation to run the floppy image from CD. i.e, using your CD imaging program, just create a new bootable CD, and use your floppy image. MagicISO is great for this.

This is the easy way of doing this though.
OS Development Series | Wiki | os | ncc
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}
User avatar
crazygray1
Member
Member
Posts: 168
Joined: Thu Nov 22, 2007 7:18 pm
Location: USA,Hawaii,Honolulu(Seriously)

Post by crazygray1 »

What's the hard way.
I'm actually looking more for how to write code for it.
Codname: Cipher
Working On: Design Doc(CFFS file system)
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 »

You can do the same thing from the command line: Bootable CD
"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
crazygray1
Member
Member
Posts: 168
Joined: Thu Nov 22, 2007 7:18 pm
Location: USA,Hawaii,Honolulu(Seriously)

Post by crazygray1 »

Oh so your saying that the code for loading from a floppy works the same on cds?
Codname: Cipher
Working On: Design Doc(CFFS file system)
User avatar
Solar
Member
Member
Posts: 7615
Joined: Thu Nov 16, 2006 12:01 pm
Location: Germany
Contact:

Post by Solar »

As has been said, that's "the easy way". Check El Torito.
Every good solution is obvious once you've found it.
User avatar
crazygray1
Member
Member
Posts: 168
Joined: Thu Nov 22, 2007 7:18 pm
Location: USA,Hawaii,Honolulu(Seriously)

Post by crazygray1 »

Oh thanks. This clears it up a bit. :D
Codname: Cipher
Working On: Design Doc(CFFS file system)
Post Reply