Go to homepage
1 / 5
Sep 2016

The asterisk is the field marker for the checksum which follows it. It’s a field marker character just like the letters are.

For example, from your log “N10 G92 X0 Y0 Z0 A0 B0*107” means: Line number 10, command G92 (set position), with arguments values of 0 for X, Y, Z, A, and B axis. And a checksum of “107”. The checksum is simply the XOR of the ASCII values of the characters that proceed it. In this case, their hexadecimal values are:

‘N’ = 0x4E
‘1’ = 0x31
‘0’ = 0x30
’ ’ = 0x20
‘G’ = 0x47
‘9’ = 0x39
‘2’ = 0x32
’ ’ = 0x20
‘X’ = 0x58
‘0’ = 0x30
’ ’ = 0x20
‘Y’ = 0x59
‘0’ = 0x30
’ ’ = 0x20
‘Z’ = 0x5A
‘0’ = 0x30
’ ’ = 0x20
‘A’ = 0x41
‘0’ = 0x30
’ ’ = 0x20
‘B’ = 0x42
‘0’ = 0x30

XOR those values together and you get 0x6B which has a decimal value of 107, hence the “*107” for the checksum in what is transmitted.

And the curse of being a computer programmer is that I knew all of those ASCII values without having to look any of them up…