BCC function node help

Hi, I’m looking for a function that will calculate a BCC character. I’ve seen some examples on the forum but nothing which gives me what I need.
I’m talking to a serial device which outputs binary buffers.

The description of the BCC “The scope of the block check character BCC is as specified in ISO/IEC 1745:1975, and is from the character immediately following the first SOH or STX character detected up to and including the ETX character which terminates the message. The calculated BCC is placed immediately following the ETX”

Example:

Message received:


SOH>P0<STX>(C62FEE91AC2DF811)<ETX>c

BCC= c

Message sent:


<SOH>P2<STX>(4B6A48E8D544FF54)<ETX>b

BCC = b

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.