progress on FAT16 support

This commit is contained in:
Dennis Gunia
2024-01-12 13:29:20 +01:00
parent ee2f22df09
commit 507eb3a017
40 changed files with 19699 additions and 6346 deletions

View File

@@ -0,0 +1,16 @@
; a contains data
; bc destroied
; carry is set if odd, reset if even
calc_parity:
ld c,0 ;parity data
ld b,8 ;bit counter
calc_parity_loop:
rrca
jr nc,calc_parity_loop_2 ;if not zero then skip increment
inc c
calc_parity_loop_2:
djnz calc_parity_loop
ld a,c
rra ;carry is set to bit 0 of high-counter.
;if bit1 is set -> odd # of 1s else even # of 1s
ret