I'm trying to implement the logic below:
if bcc = STX or bcc = CR, then bcc := +1 (increment of 1).
bcc is a byte and i'm trying to increment it by 1 if this condition above is true.
my code is:
IF message_byte[11] = 16#0D OR message_byte[11] = 16#02 THEN message_byte[11] := message_byte[11] + TO_BYTE(1); END_IF
where message_byte is an array of bytes and I want to access a specific one. However, it gives me an error when saying it can't be added.
any help is appreciated