cardosocea
Member
In the old modicons, would see a word XOR on itself as a way to clear the word.
as far as the base to the power of the position thing, any programmer should be able to immediately determine that 2# 1010 = decimal 10.
Yes... that wasn't a problem. However, say number 91, if you want to send it over a serial port in ASCII, you convert it to 91 with a function like itoa() in C, and put it in an array with 3 positions and then send.
However, if you have the first four bits of a byte with a 9 (1001) and the other four bits with a 1 (0001) and you ask for that to be sent over in hexadecimal, you'll get 91 transmitted on your serial port.
It's just a peculiarity of bits and bytes, but left the guy blown away. But again, as far as I know (unless you're using some really old OMRON's) this isn't that interesting as BCD isn't that used anymore.