Modbus DL06 TMRA Timer Accumulator

In DL06 when using TMRA instruction the Accumulator value is stored at TA# and is a double word BCD value. Can anyone tell me how to configure the Modbus driver to read this location properly so that I can display the decimal value of the Timers accumulator?

…likewise, how to configure the V# memory location for the preset value, so that I can enter it as decimal on the screen with an implied decimal?

Thanks,

Mike

Think you are going to need to use actual modbus addressing. I think the type you want is HRBCD_32, but you will need to know the register number for the first holding register. I have some Schneider plc’s that use topological addressing when programming, but in ignition i have to use modbus addressing.

Edit:
The DL06 manual shows holding registers are from 768 to 3839, so your ignition tag would be something like [device_name]1HRBCD_32768 where the 1 being the device ID (If you device id is 1, that is the default and you can omit it.) and 768 being the first holding register of you double word. Similarly your preset value, assuming it is a single word would be something like [device_name]1HR768

The DL06 modbus addressing says something about Timer input registers are on addresses 0 through 127, so you may need to use[device_name]1IRBCD_320 instead. Also your device setup in ignition will need to use zero based addressing.

A decimal representation used in Modbus typically comes in 2 words of 2 bytes each.
You must refer to your device manual to understand how data should be read. A typical case is BCD conversion, but I’ve seen a lot of devices that lets you read data as INT (32 bits) and then you must apply a mathematical operation over it: example divide by 100.

If read with BCD, don’t worry, Ignition will write in BCD doing the conversion behind scenes.

See the numerical scaling options for OPC tags.

1 Like

Thanks @pturmel

Yes, applying Scaling in Tag Configurations**

AutomationDirect has a spreadsheet that will calculate the Modbus addresses for various DirectLogic memory registers. It’s available here: AutomationDirect Technical Support - Technical and Application Notes It’s listed as ‘AN-MISC-010’.

For TMRA0, for example, the Modbus address would be 6145. In Ignition, that would be [devicename]HRBCD_326145.

Also note that the ‘Reverse Word Order’ check box needs to be checked in the driver page.

1 Like