You have to convert the byte array of the reply from the plc to an analog number. Make sure the number the plc is sending is an integer value or a real floating point value. If what you get is a floating point value it seems that you have to use the IEEE 754-1985 algorithm to make the conversion. Google it or take a look on what the wikipedia says: