Sounds like your calculating a checksum?
perl> $hex = '0FB0306F207265616420746869733F';;
perl> print unpack '%32C*', pack 'H*', $hex;;
1329
And if you need the result in hex
perl> print unpack 'H*', pack 'N', unpack '%32C*', pack 'H*', $hex;;
00000531
Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
Lingua non convalesco, consenesco et abolesco. -- Rule 1 has a caveat! -- Who broke the cabal?
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.