Skip to content

Instantly share code, notes, and snippets.

@nv-h
Created March 4, 2022 07:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nv-h/ab2d5bb5ebe4f324fb110fdc05ea4e7b to your computer and use it in GitHub Desktop.
Save nv-h/ab2d5bb5ebe4f324fb110fdc05ea4e7b to your computer and use it in GitHub Desktop.
hex_str = '10010000214601360121470136007EFE09D21901'
sum = sum(int(b) for b in bytearray.fromhex(hex_str)) & 0xff
print(hex((0x100-(sum)) & 0xff))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment