X-Git-Url: http://cloudbase.mooo.com/gitweb/avrcpm.git/blobdiff_plain/5482d75ffeb537629e1fe0a82c3eb22986dcbbc5..2217c8551dde4e881d8e25ac7472c7fc1f103092:/avr/dsk_fsys.asm diff --git a/avr/dsk_fsys.asm b/avr/dsk_fsys.asm index 46389d2..e39783e 100644 --- a/avr/dsk_fsys.asm +++ b/avr/dsk_fsys.asm @@ -184,7 +184,7 @@ dsk_getpartentry: mul zh,zl ldiw z,hostparttbl add zl,_tmp0 - add zh,_tmp1 + adc zh,_tmp1 ret ; ==================================================================== @@ -364,6 +364,9 @@ tmpdpb: .byte 16 .cseg +str_CPM_Disk: + .db 10,"",0 + ; DPBs for varios fixed formats ; dpb data starts at 2. byte @@ -607,14 +610,10 @@ dsk_tst_avrcpmhd: ; ==================================================================== -pstrn_YAZE: - .db 10,"",0 - - dsk_tst_yaze: ldiw y,hostbuf - ldiw z,pstrn_YAZE*2 + ldiw z,str_CPM_Disk*2 lpm temp2,z+ ; get length rcall strncmp_p brne dsk_tyze_not @@ -678,8 +677,8 @@ dsk_tmyz80_not: ; Registers : temp drive # ; ; -------------------------------------------------------------------- -; Description: Test, if first 6 tracks are filled with 0xE5, -; and Size = 8192 KB. +; Description: Test, if Size = 8192 KB and +; first 6 tracks are filled with 0xE5. ; Actually, only the first phys. sector is tested, since ; the other 47 sectors are not in memory at this time. ; ==================================================================== @@ -694,10 +693,15 @@ dsk_tst_simhd: cpc temp2,temp brne dsk_tsimhd_not ;wrong size + ldiw y,hostbuf+128-10 + ldiw z,str_CPM_Disk*2 + lpm temp2,z+ ; get length + rcall strncmp_p + breq dsk_tsimhd_found + ldiw z,hostbuf ldi temp2,high(512) clr _tmp0 ;low(512) - dsk_tsimhd_loop: ld temp,z+ cpi temp,0xE5 @@ -707,6 +711,7 @@ dsk_tsimhd_loop: dec temp2 brne dsk_tsimhd_loop +dsk_tsimhd_found: ori temp,0xff ret