Can I Read 32 Bit Values from Modbus Holding Registers in LabVIEW?

Updated Dec 19, 2019

Reported In

Software

  • LabVIEW

Issue Details

The PLC that I am using sends out data values that require an unsigned 32 bit representation. By default, the Modbus read function in LabVIEW has an output which has a U16 representation. Can I modify this representation?
How can I read the values that need a U32 representation?

Solution

In case of Modbus, the holding registers have a data type of Unsigned Word (U16) and that is not configurable. However, in many cases, other devices, like PLCs, may generate data in types other than I16 format. These large data types are converted to registers. For example, a pressure sensor may split a 32-bit floating point value across two 16-bit registers.

To make sense of these registers you will have to join the registers and type cast them into meaningful values.