Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - Mat

Pages: [1]
1
Open Discussion / ModbusTCP display value of partial register.
« on: April 21, 2023, 11:38:04 AM »
Is it possible to return the value of a group of bits from a register?
I am trying to display the J1939 codes from a generator controller. The data is spread across two 16bit registers. The first 5 bits are the FMI number, the next 19 bits are the SPN number, and the last 8 bits are unused.
I would like to do a MessageDisplayByValue, but I do not see a way to mask bits or define a start bit and quantity.

- Version of AdvancedHMI  3.99x
- Version of Visual Studio 2022 17.4.1
- Operating System Windows 10
- Hardware Dell PC
- PLC make and model CAT EMCP 4
- Communication Driver ModbusTCPCom

From the manual for the EMCP 4 controller:
Bits 31:24 = UNUSED, set to zeros
Bits 23:5 = SPN (0 to 524287)
Bits 4:0 = FMI (0 to 31)

Pages: [1]