BOCHS: Wie konfigurieren?
-
Ich möchte gerne ein rawbinary unter bochs ausführen (emulieren) lassen.
Please choose one: [5] 5 00000000000i[ ] lt_dlhandle is 0x8271000 00000000000i[PLGIN] loaded plugin libbx_x.la 00000000000i[ ] installing x module as the Bochs GUI 00000000000i[ ] using log file bochsout.txt ======================================================================== Bochs is exiting with the following message: [BIOS ] Could not read the boot disk ========================================================================
Diese Meldung bekomme ich.
Hier meine .bochsrc Datei.
############################################################### # bochsrc.txt file for DLX Linux disk image. ############################################################### # how much memory the emulated machine will have megs: 32 # filename of ROM images romimage: file=$BXSHARE/BIOS-bochs-latest, address=0xf0000 vgaromimage: file=$BXSHARE/VGABIOS-lgpl-latest # what disk images will be used floppya: 1_44=floppya.img, status=inserted floppyb: 1_44=floppyb.img, status=inserted # hard disk ata0: enabled=1, ioaddr1=0x1f0, ioaddr2=0x3f0, irq=14 ata0-master: type=disk, path="./mybin.bin", cylinders=1, heads=1, spt=1 # choose the boot disk. boot: c # default config interface is textconfig. #config_interface: textconfig #config_interface: wx #display_library: x # other choices: win32 sdl wx carbon amigaos beos macintosh nogui rfb term svga # where do we send log messages? log: bochsout.txt # disable the mouse, since DLX is text only mouse: enabled=0 # enable key mapping, using US layout as default. # # NOTE: In Bochs 1.4, keyboard mapping is only 100% implemented on X windows. # However, the key mapping tables are used in the paste function, so # in the DLX Linux example I'm enabling keyboard_mapping so that paste # will work. Cut&Paste is currently implemented on win32 and X windows only. #keyboard_mapping: enabled=1, map=$BXSHARE/keymaps/x11-pc-us.map #keyboard_mapping: enabled=1, map=$BXSHARE/keymaps/x11-pc-fr.map keyboard_mapping: enabled=1, map=$BXSHARE/keymaps/x11-pc-de.map #keyboard_mapping: enabled=1, map=$BXSHARE/keymaps/x11-pc-es.map
Liegt wohl an diesem codeabschnitt:
# hard disk ata0: enabled=1, ioaddr1=0x1f0, ioaddr2=0x3f0, irq=14 ata0-master: type=disk, path="./mybin.bin", cylinders=1, heads=1, spt=1
.bochsrc befindet sich in /root/bochs.
Genau so wie meien binary (mybin.bin).Allerding habe ich recht wenig ahnung von bochs. Das mitgelieferte dlxlinux läuft problemlos.(Von da hab ich auch diese config kopiert und etwas abgeändert)
An dem oben genannten Abschnitt habe ich (außer dem Namen meiner binary) ABSOLUT NICHTS abgeändert.Ich habe leider acuh keien AHnung WIE ich das abändern soll.
Kann mir da jemand weiterhelfen?
(SuSE 9.2)MfG, euer Bochs
-
Mach deine binary in den ordner /usr/share/bochs/dlxlinux und start sie dann von dort aus so: bochs -q 'boot:a' 'floppya: 1_44=deinname.bin, status=inserted'
So funktionierts jedenfalls bei mir, ich hab auch nicht wirklich viel ahnung von bochs, ich saß da mal stunden dran bis ich meine binary testen konnte.
-
Storm.Xapek.de schrieb:
Mach deine binary in den ordner /usr/share/bochs/dlxlinux und start sie dann von dort aus so: bochs -q 'boot:a' 'floppya: 1_44=deinname.bin, status=inserted'
So funktionierts jedenfalls bei mir, ich hab auch nicht wirklich viel ahnung von bochs, ich saß da mal stunden dran bis ich meine binary testen konnte.thx. Habs noch nicht ausprobiert, klingt aber richtig.
-
Storm.Xapek.de schrieb:
Mach deine binary in den ordner /usr/share/bochs/dlxlinux und start sie dann von dort aus so: bochs -q 'boot:a' 'floppya: 1_44=deinname.bin, status=inserted'
So funktionierts jedenfalls bei mir, ich hab auch nicht wirklich viel ahnung von bochs, ich saß da mal stunden dran bis ich meine binary testen konnte.funkt...
Nächstes KLEINES problemchen:
Wie macht man in bochs snapshots? Wenn ich auf "snapshot" klicke, dann wird das angezeigt:00001388000e[XGUI ] snapshot button failed, mode not implemented
-
Mach doch einen von deinem Betriebssystem aus. Unter linux bei KDE z.B KSnapshot
PS: Wie sieht dein code aus. Meiner gibt immerwieder das ABC aus (ich weis nicht besonders einfallsreich):;REAL MODE == 16 Bits [BITS 16] ;Boot sector address [ORG 0x7C00] anfang: mov al, 'a' start: ;loop ;write cmp al, 'z' jz anfang add al, 1 mov ah, 0Eh mov bh, 0Fh mov bl, 0 int 10h ;loop jmp start times 510-($-$$) db 0 dw 0AA55h
-
Storm.Xapek.de schrieb:
Mach doch einen von deinem Betriebssystem aus. Unter linux bei KDE z.B KSnapshot
PS: Wie sieht dein code aus. Meiner gibt immerwieder das ABC aus (ich weis nicht besonders einfallsreich):;REAL MODE == 16 Bits [BITS 16] ;Boot sector address [ORG 0x7C00] anfang: mov al, 'a' start: ;loop ;write cmp al, 'z' jz anfang add al, 1 mov ah, 0Eh mov bh, 0Fh mov bl, 0 int 10h ;loop jmp start times 510-($-$$) db 0 dw 0AA55h
So kann ich natürlich auch scrennshots machen. Aber wenns es bocsh könnte, wäre es bequemer.
ps: Mein prog ist auch nicht einfallsreicher (AT&T syntax)
.arch i386 .code16 .section .data .section .text .global _start _start: call init_graphic_mode call setpalette movw $0xa000 , %ax movw %ax , %es xorw %di , %di movw $320*200 , %cx .loop1: movb %bl , %al stosb inc %bx loop .loop1 xorw %ax , %ax movw $0x60 , %dx here: inb %dx , %al cmpb $0x1 , %al jne here call init_text_mode ret ############################################### init_graphic_mode: movw $0x0013 , %ax int $0x10 ret init_text_mode: movw $0x0003 , %ax int $0x10 ret setpalette: pusha xorb %cl , %cl .sp_loop1: movw $0x3c8 , %dx movb %cl , %al outb %al , %dx inc %dx xorb %al , %al outb %al , %dx outb %al , %dx movb %cl , %al outb %al , %dx cmpb $255 , %cl inc %cx jne .sp_loop1 popa ret .org 510 .short 0xaa55
Und so schaut das aus: SCREENSHOT