Back to home page

DOS ain't dead

Forum index page

Log in | Register

Back to the forum
Board view  Mix view

Datalight ROM-DOS floppy image creation (Emulation)

posted by ecm Homepage E-mail, Düsseldorf, Germany, 08.12.2020, 16:29

I just added two options that help initialising the boot sector loader. Before this commit, _BOOTFILE had to point to a 512-bytes file complete with the BPB properly initialised already. If that is not the case, the new options _BOOTJUMPFILE and _BOOTCODEFILE allow specifying loader fragments to initialise, while the script will write the BPB itself. The jump file should be 3 or 11 bytes long, taken from the beginning of the loader file. The code file, for FAT12 or FAT16, should be 450 (or 448 or 446) bytes taken starting from offset 3Eh in the loader file. Here is an example, using dd. Your X could be used instead, too.

bootimg$ dd if=../ldosboot/boot12.bin bs=1 skip=$((0x3E)) of=code.bin
450+0 records in
450+0 records out
450 bytes copied, 0.00307256 s, 146 kB/s
bootimg$ dd if=../ldosboot/boot12.bin bs=1 skip=0 count=11 of=jump.bin
11+0 records in
11+0 records out
11 bytes copied, 0.000261832 s, 42.0 kB/s
bootimg$ nasm -I ../lmacros/ bootimg.asm -D_PAYLOADFILE=::empty -D_BOOTJUMPFILE="'jump.bin'" -D_BOOTCODEFILE="'code.bin'"
bootimg$

---
l

 

Complete thread:

Back to the forum
Board view  Mix view
22649 Postings in 2111 Threads, 402 registered users, 779 users online (0 registered, 779 guests)
DOS ain't dead | Admin contact
RSS Feed
powered by my little forum