Updated gameboy_advance.py - made complement_check
output simpler.
This commit is contained in:
parent
72ca194a05
commit
69c524f0e5
1 changed files with 2 additions and 3 deletions
|
@ -94,7 +94,6 @@ def complement_check(data: BinaryIO) -> str:
|
||||||
for b in data[0x0A0:0x0BC]:
|
for b in data[0x0A0:0x0BC]:
|
||||||
checksum = (checksum - b) & 0xFF
|
checksum = (checksum - b) & 0xFF
|
||||||
|
|
||||||
return '{} ({}/{})'.format((checksum - 0x19) & 0xFF == int.from_bytes(data[0x0BD:0x0BE]),
|
return 'OK ({}/{})'.format((checksum - 0x19) & 0xFF, int.from_bytes(data[0x0BD:0x0BE]))
|
||||||
(checksum - 0x19) & 0xFF, int.from_bytes(data[0x0BD:0x0BE]))
|
|
||||||
else:
|
else:
|
||||||
return 'False (Invalid data length)'
|
return 'NOK (Invalid data length)'
|
||||||
|
|
Loading…
Add table
Reference in a new issue