# Modbus addressing is different type of address

**URL:** <https://forum.inductiveautomation.com/t/modbus-addressing-is-different-type-of-address/87047>\
**Category:** General Discussion\
**Tags:** ignition81, modbus\
**Created:** [March 8, 2024, 4:43pm UTC](https://forum.inductiveautomation.com/t/modbus-addressing-is-different-type-of-address/87047 "2024-03-08T16:43:37Z")\
**Posts on this page:** 17\
**Page:** 1

<div class="post-metadata">

**Author:** ![Parth\_Pandya](https://avatars.discourse-cdn.com/v4/letter/p/5f9b8f/32.png) [@Parth\_Pandya](https://forum.inductiveautomation.com/u/Parth_Pandya)\
**Post date:** [March 8, 2024, 4:43pm UTC](https://forum.inductiveautomation.com/t/modbus-addressing-is-different-type-of-address/87047/1 "2024-03-08T16:43:37Z")

</div>

![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/0/2/02ba7c2d756bd388fe1a21da0d88d26661f42dfe.png)  
hi, we added a power meter device which support modbus but their addressing looks different. can anyone help me how i can add this in modbus addressing?

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [March 8, 2024, 4:54pm UTC](https://forum.inductiveautomation.com/t/modbus-addressing-is-different-type-of-address/87047/2 "2024-03-08T16:54:52Z")

</div>

Function code 0x03 is for reading holding registers, while 0x04 is for reading Input Registers. You should try both (maybe it supports both identically).

OPC Item Paths in Ignition would look like this:

```auto
n.HRI0
n.HRI2
n.HRI4
n.HRUI6
n.HRUI8
n.HRI10
...

```

Where `n` is the device's node address. You can leave out the `n.` if zero.

Note that the list of addresses starts at offset **zero** , so you must use **Zero-based addressing** in the Ignition device settings (advanced).

> **[Modbus Addressing | Ignition User Manual](https://www.docs.inductiveautomation.com/docs/8.1/ignition-modules/opc-ua/opc-ua-drivers/modbus/modbus-addressing#manually-addressing-a-modbus-device)**
>
> Manually Addressing a Modbus Device

Most of those values are shown with divisors. You would use the linear scaling feature in each Ignition tag to convert those to floating point values.

> **[Tag Scaling Properties | Ignition User Manual](https://www.docs.inductiveautomation.com/docs/8.1/platform/tags/tag-properties/tag-scaling-properties#linear-scaling)**
>
> Configuring a Tag's scaling will condition the data for use within the Ignition Designer. Scaling will take the raw PLC value driving a Tag, do some math, and use the resulting value as the value of that Tag. Scaling works both ways. When you write...

---

<div class="post-metadata">

**Author:** ![Parth\_Pandya](https://avatars.discourse-cdn.com/v4/letter/p/5f9b8f/32.png) [@Parth\_Pandya](https://forum.inductiveautomation.com/u/Parth_Pandya)\
**Post date:** [March 11, 2024, 3:31pm UTC](https://forum.inductiveautomation.com/t/modbus-addressing-is-different-type-of-address/87047/3 "2024-03-11T15:31:50Z")

</div>

![modbus1](https://us1.discourse-cdn.com/inductiveautomation/original/3X/6/6/66e8dc1deabb192f239cd52881bf9e938def12ec.png)  
 ![modbus](https://us1.discourse-cdn.com/inductiveautomation/original/3X/7/2/72b71fec984c42293b4b2d8cd2253eae149ebf15.png)  
[![](https://us1.discourse-cdn.com/inductiveautomation/original/3X/0/2/02ba7c2d756bd388fe1a21da0d88d26661f42dfe.png) ](https://us1.discourse-cdn.com/inductiveautomation/original/3X/0/2/02ba7c2d756bd388fe1a21da0d88d26661f42dfe.png)

let say i want to show the value of the address 0008H unsigned Long how to do that i did this way which is in image but still bad value. can you help?

---

<div class="post-metadata">

**Author:** ![Kevin.Herron](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kevin.herron/32/7259_2.png) [@Kevin.Herron](https://forum.inductiveautomation.com/u/Kevin.Herron)\
**Post date:** [March 11, 2024, 3:37pm UTC](https://forum.inductiveautomation.com/t/modbus-addressing-is-different-type-of-address/87047/4 "2024-03-11T15:37:31Z")

</div>

Have you tried changing the device/unit/slave id from its default of 0 to e.g. 1?

Try something like: `[ION]1.HRUI8`

---

<div class="post-metadata">

**Author:** ![Parth\_Pandya](https://avatars.discourse-cdn.com/v4/letter/p/5f9b8f/32.png) [@Parth\_Pandya](https://forum.inductiveautomation.com/u/Parth_Pandya)\
**Post date:** [March 11, 2024, 3:39pm UTC](https://forum.inductiveautomation.com/t/modbus-addressing-is-different-type-of-address/87047/5 "2024-03-11T15:39:52Z")

</div>

yes i did. no luck

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/9/6/960f2826f9f5ae3439f1d0af281401b2bdfe7cf8.png)

---

<div class="post-metadata">

**Author:** ![Kevin.Herron](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kevin.herron/32/7259_2.png) [@Kevin.Herron](https://forum.inductiveautomation.com/u/Kevin.Herron)\
**Post date:** [March 11, 2024, 3:41pm UTC](https://forum.inductiveautomation.com/t/modbus-addressing-is-different-type-of-address/87047/6 "2024-03-11T15:41:05Z")

</div>

Check the Ignition logs for errors.

See if any other Modbus client software can read the registers. If so, compare settings or Wireshark captures.

---

<div class="post-metadata">

**Author:** ![Parth\_Pandya](https://avatars.discourse-cdn.com/v4/letter/p/5f9b8f/32.png) [@Parth\_Pandya](https://forum.inductiveautomation.com/u/Parth_Pandya)\
**Post date:** [March 11, 2024, 3:43pm UTC](https://forum.inductiveautomation.com/t/modbus-addressing-is-different-type-of-address/87047/7 "2024-03-11T15:43:07Z")

</div>

![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/3/4/3404b9765ba5ae36db12aed1866bbcff5309236b.png)

---

<div class="post-metadata">

**Author:** ![Cory.grube](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/cory.grube/32/20476_2.png) [@Cory.grube](https://forum.inductiveautomation.com/u/Cory.grube)\
**Post date:** [March 11, 2024, 4:03pm UTC](https://forum.inductiveautomation.com/t/modbus-addressing-is-different-type-of-address/87047/8 "2024-03-11T16:03:39Z")

</div>

Looks like the first address in the manual is 0. I suspect you need to enable [zero-based addressing](https://docs.inductiveautomation.com/docs/8.1/ignition-modules/opc-ua/opc-ua-drivers/modbus/connecting-to-modbus-device#advanced) in your modbus device connection. If this configuration is wrong, you could be reading registers without data (or a register that's just plain invalid).

Also, it looks like you might be trying to use Modbus Address Mapping. I recommend you stay away from that - it'll only add complexity and confusion. Just do direct addressing in each tag.

---

<div class="post-metadata">

**Author:** ![Parth\_Pandya](https://avatars.discourse-cdn.com/v4/letter/p/5f9b8f/32.png) [@Parth\_Pandya](https://forum.inductiveautomation.com/u/Parth_Pandya)\
**Post date:** [March 11, 2024, 4:07pm UTC](https://forum.inductiveautomation.com/t/modbus-addressing-is-different-type-of-address/87047/9 "2024-03-11T16:07:38Z")

</div>

![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/2/7/27123dbca0f0e64879565d5e25d080d79eb0177a.png)

---

<div class="post-metadata">

**Author:** ![Parth\_Pandya](https://avatars.discourse-cdn.com/v4/letter/p/5f9b8f/32.png) [@Parth\_Pandya](https://forum.inductiveautomation.com/u/Parth_Pandya)\
**Post date:** [March 11, 2024, 4:29pm UTC](https://forum.inductiveautomation.com/t/modbus-addressing-is-different-type-of-address/87047/10 "2024-03-11T16:29:02Z")

</div>

i am not using mapping. i am using OPC tags

---

<div class="post-metadata">

**Author:** ![Parth\_Pandya](https://avatars.discourse-cdn.com/v4/letter/p/5f9b8f/32.png) [@Parth\_Pandya](https://forum.inductiveautomation.com/u/Parth_Pandya)\
**Post date:** [March 11, 2024, 5:39pm UTC](https://forum.inductiveautomation.com/t/modbus-addressing-is-different-type-of-address/87047/11 "2024-03-11T17:39:52Z")

</div>

it works now thanks guys for your help. need final help values from 0000H to 00008H coming perfectly once i start with 0040, 0042, 0044...,004A, 000A or any after 8H is showing wrong values some are very very big numbers, may be i am putting wrong number in Hax? the OPC Path is "[ION]1.HRUI42" wring value. but "[ION]1.HRUI8" correct.  
do i need to change hax to dec number?

---

<div class="post-metadata">

**Author:** ![Cory.grube](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/cory.grube/32/20476_2.png) [@Cory.grube](https://forum.inductiveautomation.com/u/Cory.grube)\
**Post date:** [March 11, 2024, 5:45pm UTC](https://forum.inductiveautomation.com/t/modbus-addressing-is-different-type-of-address/87047/12 "2024-03-11T17:45:16Z")

</div>

Yes, you'll definitely need to convert those hex addresses to decimal. e.g. 000A becomes HRI10, 0040 becomes HRUI64.  
Glad you got them reading!

---

<div class="post-metadata">

**Author:** ![Parth\_Pandya](https://avatars.discourse-cdn.com/v4/letter/p/5f9b8f/32.png) [@Parth\_Pandya](https://forum.inductiveautomation.com/u/Parth_Pandya)\
**Post date:** [March 11, 2024, 5:57pm UTC](https://forum.inductiveautomation.com/t/modbus-addressing-is-different-type-of-address/87047/13 "2024-03-11T17:57:06Z")

</div>

no luck, when i am converting them to dec its coming as bad

---

<div class="post-metadata">

**Author:** ![Kevin.Herron](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kevin.herron/32/7259_2.png) [@Kevin.Herron](https://forum.inductiveautomation.com/u/Kevin.Herron)\
**Post date:** [March 11, 2024, 6:14pm UTC](https://forum.inductiveautomation.com/t/modbus-addressing-is-different-type-of-address/87047/14 "2024-03-11T18:14:55Z")

</div>

You might need to turn the "Span Gaps" setting to False.

---

<div class="post-metadata">

**Author:** ![Cory.grube](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/cory.grube/32/20476_2.png) [@Cory.grube](https://forum.inductiveautomation.com/u/Cory.grube)\
**Post date:** [March 11, 2024, 6:15pm UTC](https://forum.inductiveautomation.com/t/modbus-addressing-is-different-type-of-address/87047/15 "2024-03-11T18:15:38Z")

</div>

Try disabling all `[ION]` tags with bad quality. The modbus driver groups multiple read/write registers together for efficiency - you may have an error in a single tag that causes multiple tags to fail. This might also be addressed by the Span Gaps setting Kevin mentioned.

From there, enable/create one tag at a time and see what works and what doesn't. You may also need to check the logs or run wireshark to get more detailed information about what exactly is failing, and why.

---

<div class="post-metadata">

**Author:** ![Parth\_Pandya](https://avatars.discourse-cdn.com/v4/letter/p/5f9b8f/32.png) [@Parth\_Pandya](https://forum.inductiveautomation.com/u/Parth_Pandya)\
**Post date:** [March 11, 2024, 6:41pm UTC](https://forum.inductiveautomation.com/t/modbus-addressing-is-different-type-of-address/87047/16 "2024-03-11T18:41:50Z")

</div>

yes you are right, i did one by one tags i have added 3 tags which are good and able to read values as soon as i am adding another tags which are after 0008H getting bad and thn other 3 tags which are goods showing error .

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/f/e/fe9304a4e8f3b01673d1d2e8e1d62797c8c0bab9.png)  
 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/d/e/de7b07b5464dd16849290d86c545cd64510342e8.png)

when i am converting 42H to 66 dec it showing bad.  
with 42H showing some value which is absolutely wrong

---

<div class="post-metadata">

**Author:** ![Cory.grube](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/cory.grube/32/20476_2.png) [@Cory.grube](https://forum.inductiveautomation.com/u/Cory.grube)\
**Post date:** [March 11, 2024, 6:54pm UTC](https://forum.inductiveautomation.com/t/modbus-addressing-is-different-type-of-address/87047/17 "2024-03-11T18:54:09Z")

</div>

I see you've got L1V defined and working - that should be looking at HRUI64, correct? Is it working as intended and reading a reasonable value (scaled by x10)?

Any other points further down you can test? Sometimes modbus devices can simply behave in unexpected ways due to how they're programmed. I've seen power meters return NaN for registers when there's no line side voltage, I've seen them max out registers when the meter is unconfigured (all registers 32767), etc. If it's only affecting L2, it could simply be something with the meter itself or the physical configuration.
