Add include file for BPB data

This commit is contained in:
Nero 2020-03-31 13:04:13 +00:00
parent eabb1d9fa9
commit 73fb2b1e81
2 changed files with 30 additions and 1 deletions

View File

@ -9,7 +9,7 @@ QEMU = qemu-system-$(QEMU_ARCH)
QEMU_ARGS = $(addprefix --option-rom ,$(ROMS))
NASM = nasm
NASM_ARGS = -s -I. -Ilib -w-macro-params -DFLOPPY=$(FLOPPY)
NASM_ARGS = -s -I. -Iinc -w-macro-params -DFLOPPY=$(FLOPPY)
EMUL = utils/emul

29
inc/bpb.inc Normal file
View File

@ -0,0 +1,29 @@
; DOS 3.31 Bios Parameter Block
bpb_ss: equ 0x00 ; WORD sector size
bpb_sc: equ 0x02 ; BYTE sector / cluster
bpb_rsc: equ 0x03 ; WORD reserved sector count
bpb_fn: equ 0x05 ; BYTE fat number
bpb_rde: equ 0x06 ; WORD root dir entries
bpb_ts: equ 0x08 ; WORD total sectors
bpb_md: equ 0x0A ; BYTE media descriptor
bpb_sf: equ 0x0B ; WORD sectors / fat
bpb_spt: equ 0x0D ; WORD sectors per track
bpb_nos: equ 0x0F ; WORD number of sides
bpb_po: equ 0x11 ; DWORD partition offset
bpb_lts: equ 0x15 ; DWORD large total sectors
; DOS 4.0 Extended Bios Parameter Block
bpb4_dn: equ 0x19 ; BYTE drive number
bpb4_sig: equ 0x1B ; BYTE 29h
bpb4_ser: equ 0x1C ; DWORD serial
; DOS 7.1 Extended Bios Parameter Block
bpb7_lsf: equ 0x19 ; DWORD large sectors / fat
bpb7_rdc: equ 0x21 ; DWORD root directory cluster
bpb7_fsc: equ 0x25 ; WORD fsinfo sector
bpb7_bsc: equ 0x27 ; WORD backup boot sector
bpb7_dn: equ 0x35 ; BYTE drive number
bpb7_sig: equ 0x37 ; BYTE 28h or 29h
bpb7_ser: equ 0x38 ; DWORD serial
bpb_len: equ 0x4F