Search FAQs
How to bit-pack 16 bits into a SCADAPack x70 analog object associated with a Modbus holding register
When using SCADAPack x70 devices, it may be desirable to pack 16 bits into a Modbus register. This is typically wanted when the SCADAPack is acting as a Modbus Server. When using RemoteConnect all protocol facing values need to be in “objects” in the SCADAPack database.
Logic:
If you need to pack 16 bits into a Modbus register, a user will create an object associated with a Modbus address. The Logic Variable Type will be “T_SPx70_UINT”
In the logic editor the user will use a combination of “BIT_TO_WORD” and “WORD_TO_UINT” function blocks. The inputs to the “BIT_TO_WORD” block can be a combination of Elementary variables and Derived variables that are part of the x70 object database.
Below are visual examples of the objects and logic needed to bit-pack an object with 16 bits. The 16 bits will be available in Modbus register 40001 (object ModbusBitPack). Any SCADA/RTU/PLC client can poll for Modbus register 40001 and get the bit-packed value.
![Object List Object List](https://ckm-content.se.com/ckmContent/servlet/servlet.ImageServer?id=0158V00000BYRjAQAX&oid=00DA0000000abSmMAI)
![Logic Example Logic Example](https://ckm-content.se.com/ckmContent/servlet/servlet.ImageServer?id=0158V00000BYRjBQAX&oid=00DA0000000abSmMAI)
Logic:
If you need to pack 16 bits into a Modbus register, a user will create an object associated with a Modbus address. The Logic Variable Type will be “T_SPx70_UINT”
In the logic editor the user will use a combination of “BIT_TO_WORD” and “WORD_TO_UINT” function blocks. The inputs to the “BIT_TO_WORD” block can be a combination of Elementary variables and Derived variables that are part of the x70 object database.
Below are visual examples of the objects and logic needed to bit-pack an object with 16 bits. The 16 bits will be available in Modbus register 40001 (object ModbusBitPack). Any SCADA/RTU/PLC client can poll for Modbus register 40001 and get the bit-packed value.
Released for:Schneider Electric New Zealand
Explore more
Range:
Explore more
Range: