Bochs isn't working

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
tm-

Bochs isn't working

Post by tm- »

When I try to run Bochs, it gives me an error message:
[BIOS] Not a bootable disk

I'm new with this, so I don't have any idea what should I do now. And here's my bochsrc.txt:

Code: Select all

# how much memory the emulated machine will have
# if you have less than 64MB of memory in your actuall computer, set this lower(16 is good)
megs: 32

# filename of ROM images
# note that if before a filename we put "../" then the file is looked
# for in the directory above that the current directory(the one the configuration
# file is in).
romimage: file="BIOS-bochs-latest", address=0xf0000
vgaromimage: file="VGABIOS-elpin-2.40"

# we want a floppy drive(called a), the disk image that we are using is called "1.44"
floppya: 1_44="a.img", status=inserted

# choose the boot disk.
boot: floppy

# where do we send log/error messages?
log: bochsout.txt

# disable the mouse unless your OS uses it
mouse: enabled=0
What should I do now??
User avatar
Candy
Member
Member
Posts: 3882
Joined: Tue Oct 17, 2006 11:33 pm
Location: Eindhoven

Re:Bochs isn't working

Post by Candy »

Does your bootsector end in 0x55 0xAA? That's at offset 510 and 511 decimal from the start of it.

If not, that's required or the disk just really isn't bootable.

Small note: most non-bootable disks also have a bootsector, which then displays "this disk isn't bootable".
tm-

Re:Bochs isn't working

Post by tm- »

Yes, there is that signature. Here's what I have done:
-format floppy disk
-partcopy bootsec.bin 0 200 -f0

And the bootsector is from http://www.osdever.net/tutorials/hello_ ... ?the_id=85
(the lowest one, hello world bootloader)

And I use NASM to create that bootsec.bin.
AR

Re:Bochs isn't working

Post by AR »

floppya: 1_44="a.img", status=inserted
This line is saying to emulate a floppy disk drive using the file "a.img", since you are trying to use a real floppy drive it should say:

Code: Select all

floppya: 1_44="a:", status=inserted
User avatar
Candy
Member
Member
Posts: 3882
Joined: Tue Oct 17, 2006 11:33 pm
Location: Eindhoven

Re:Bochs isn't working

Post by Candy »

AR wrote:
floppya: 1_44="a.img", status=inserted
This line is saying to emulate a floppy disk drive using the file "a.img", since you are trying to use a real floppy drive it should say:

Code: Select all

floppya: 1_44="a:", status=inserted
For completeness: if you use a Unix-derivate it should read

Code: Select all

floppya: 1_44="/dev/fd0", status=inserted
tm-

Re:Bochs isn't working

Post by tm- »

Yes, that fixed the problem! Thanks!
Post Reply