; ; A standard CPM 2.2 Bios arrangement ; This linkage allows debugging DOS+ using pre-existing bios. ; ; The returned values from conout and home are optional. The home ; value allows monitoring and controlling disk soft error operations. ; These optional values are returned by cbf BIOS/ROM on Kaypro 4 (83) ; which system DOES NOT disturb IX, IY, nor alternate registers. entry boot; 0 boot none none entry wboot; 1 wboot " " entry const; 2 console status " A=0FFH ready ; =0 not ready entry conin; 3 console input " A=console char entry conout; 4 console output C=console char X/Y screen pos entry list; 5 list output C=list char none entry punch; 6 punch output C=punch char " entry reader; 7 reader input none A=reader char entry home; 8 home disk " ^system table entry seldsk; 9 select disk C=drv # (0..15) HL=^Disk table ; E : 1 bit (lsb) ; = 1 for re-access ; = 0 for 1st access ; (for disk sensing etc) entry settrk; 10 select track BC=track # none entry setsec; 11 select sector BC=sector # " entry setdma; 12 set DMA address BC=DMA address " entry read; 13 read 128 bytes none A = 0 no error ; A <> 0 error entry write; 14 write 128 bytes; C=0 write data A = 0 no error ; C=1 wrt dir. A <> 0 error ; C=2 wrt unalloc entry listst; 15 list status none A = 0ffh ready ; A = 0 not ready entry sectrn; 16 sector translate BC = sect HL = sector # ; DE = ^table ; (from select) ; ; Optional timer service routine, patchable address in DOS+ offset 16h ; Value is 040h (string address only) for cbf BIOS/ROM on Kaypro 4/83 ; XX time BC =0 get pointer only HL=pointer to time array ; BC <> 0 allows hard- HL+0^ date LSB days since ; ware to be updated HL+1^ date MSB (1=1978/1/1) ; if a routine call. HL+2^ hour (bcd) ; ignored if timead HL+3^ minute (bcd) ; is purely an address. HL+4^ seconds (bcd) ; BC^ time to set. (no secs) ; CARRY clear, NZ on exit. ; ; Optional entries, cbf bios/rom on Kaypro 4 (83) ;entry punsta; 24 punch status none A = 0ffh ready ; A = 0 not ready ;entry rdrsta; 25 reader status none A = 0ffh ready ; A = 0 not ready ;entry gorom; 26 ROM executor @hl a,b,c,d,e a,f,d,e,h,l ; & hl = locn 3 (sees 4000h up) ; boot equ $; 0 initialize wboot equ boot+3; 1 warm boot const equ wboot+3; 2 console status conin equ const+3; 3 console input conout equ conin+3; 4 console output list equ conout+3; 5 list output punch equ list+3; 6 punch output reader equ punch+3; 7 reader input home equ reader+3; 8 home disk seldsk equ home+3; 9 select disk settrk equ seldsk+3; 10 select track setsec equ settrk+3; 11 select sector setdma equ setsec+3; 12 set DMA address read equ setdma+3; 13 read 128 bytes write equ read+3; 14 write 128 bytes listst equ write+3; 15 list status sectrn equ listst+3; 16 sector translate ; ; Optional entries used cbf Kaypro 4/83 bios punsta equ sectrn+24; 24 punch status rdrsta equ punsta+3; 25 reader status gorom equ rdrsta+3; 26 access Bank 0 ROM (hl^) routine ; passing a,b,c,d,e, hl=locn 3-4 ; returning a,f,d,e,h,l ; (only memory from 04000h up is ; visible to the ROM procedures) end