I am writing an RS232 programme which it sends data in ASCII format
which is good as i can read out from an edit box however i need to
create a check sum. The edit box contains text like 45 F3 A4 33 which
are ascii representations of hex values. To create the check sum I
need to do sum calculations. I need to convert the string into real
numbers and exclusive or the values to give me the check sum value
I.E.
0x45 eor 0xF3 eor 0xA4 eor 0x33 = 0x21 or the hex number converted to
decimal
69 eor 243 eor 164 eor 51 = 33 decimal or 0x21.
The result decimal result will the need changing back to ascii, i
think that this can be done with the IntToHex function.
Is there an easy way to do the string to hex conversion?
Any help would be greatly appreciated
Colin