Hi all,
BCD to Integer instruction in STEP7 reads the contents specified in the input parameter as a three digit number in binary coded decimal format (BCD,+-999) and converts this number to an integer value. I understand that twelve less significant bits represents value and bit no.12 represents sign. Am I right?
My purpose is to convert eight bits ( MSB represents sign bit; bits:6,5,4 represent one BCD digit and 3,2,1,0 represent second BCD digit) to decimal value.
Could you give me some tip how to start up with this problem?
Regards,
gumis
BCD to Integer instruction in STEP7 reads the contents specified in the input parameter as a three digit number in binary coded decimal format (BCD,+-999) and converts this number to an integer value. I understand that twelve less significant bits represents value and bit no.12 represents sign. Am I right?
My purpose is to convert eight bits ( MSB represents sign bit; bits:6,5,4 represent one BCD digit and 3,2,1,0 represent second BCD digit) to decimal value.
Could you give me some tip how to start up with this problem?
Regards,
gumis