Prev: 0292 Up: Map Next: 02B7
029D: decode_packet_number: Get the packet address from the Magazine Row Address Group.
Used by the routine at NMI_ISR.
decode_packet_number 029D CALL hamming_decode_hl Hamming 8/4 decode the byte at address in HL.
02A0 LD A,B Return if result is $FF.
02A1 CP $FF
02A3 RET Z
02A4 AND $08 Else copy bit 3 of result into bit 0 of E.
02A6 RRCA
02A7 RRCA
02A8 RRCA
02A9 LD E,A
02AA INC HL Hamming 8/4 decode the next byte.
02AB CALL hamming_decode_hl
02AE LD A,B Return if result is $FF.
02AF CP $FF
02B1 RET Z
02B2 AND A Else shift result left and add E.
02B3 RLCA
02B4 ADD A,E
02B5 LD B,A Return resulting packet number in B.
02B6 RET
Prev: 0292 Up: Map Next: 02B7