# Holding Register for Modbus TCP

**URL:** <https://forum.inductiveautomation.com/t/holding-register-for-modbus-tcp/51633>\
**Category:** Ignition\
**Tags:** ignition81\
**Created:** [October 5, 2021, 7:11pm UTC](https://forum.inductiveautomation.com/t/holding-register-for-modbus-tcp/51633 "2021-10-05T19:11:50Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![loc.le](https://avatars.discourse-cdn.com/v4/letter/l/94ad74/32.png) [@loc.le](https://forum.inductiveautomation.com/u/loc.le)\
**Post date:** [October 5, 2021, 7:11pm UTC](https://forum.inductiveautomation.com/t/holding-register-for-modbus-tcp/51633/1 "2021-10-05T19:11:50Z")

</div>

I am trying to create some tags to get data from Zebra Fx9600 RFID reader. But the data I got from the tags are not what I expect. Can you help me to see what is the problem with my settings? Many thanks

![tagsetting](https://us1.discourse-cdn.com/inductiveautomation/original/3X/6/7/67df175f59c7dcf1a71f843e89920b6e4aa040f1.png)  
 ![returnValueOfTag](https://us1.discourse-cdn.com/inductiveautomation/original/3X/4/a/4a346a5754df6324c737f7f3adc88628e1025488.png)

 ![Device_guide](https://us1.discourse-cdn.com/inductiveautomation/original/3X/4/7/47aae0418cce3f791a2782895dfaffe965a2b900.png)

---

<div class="post-metadata">

**Author:** ![loc.le](https://avatars.discourse-cdn.com/v4/letter/l/94ad74/32.png) [@loc.le](https://forum.inductiveautomation.com/u/loc.le)\
**Post date:** [October 5, 2021, 7:12pm UTC](https://forum.inductiveautomation.com/t/holding-register-for-modbus-tcp/51633/2 "2021-10-05T19:12:20Z")

</div>

![setting1](https://us1.discourse-cdn.com/inductiveautomation/original/3X/2/0/20ba17e99ca5b412bad6a5544db77fb325ec22bc.png)  
 ![setting2](https://us1.discourse-cdn.com/inductiveautomation/original/3X/7/1/71b5a8bdd188fb343f98972e03975e87829dc386.png)  
 ![Status](https://us1.discourse-cdn.com/inductiveautomation/original/3X/1/e/1e3419275bfc97257e33361029d80e772533c933.png)

---

<div class="post-metadata">

**Author:** ![Matrix\_Engineering](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/matrix_engineering/32/19781_2.png) [@Matrix\_Engineering](https://forum.inductiveautomation.com/u/Matrix_Engineering)\
**Post date:** [October 5, 2021, 7:13pm UTC](https://forum.inductiveautomation.com/t/holding-register-for-modbus-tcp/51633/3 "2021-10-05T19:13:54Z")

</div>

Welcome!

The most common thing is to change the reverse word order and one based addressing in advanced settings (might need both)

---

<div class="post-metadata">

**Author:** ![loc.le](https://avatars.discourse-cdn.com/v4/letter/l/94ad74/32.png) [@loc.le](https://forum.inductiveautomation.com/u/loc.le)\
**Post date:** [October 5, 2021, 7:24pm UTC](https://forum.inductiveautomation.com/t/holding-register-for-modbus-tcp/51633/4 "2021-10-05T19:24:18Z")

</div>

Thank you, I tried all possible ways and add 1 to holding registers to match “1”-base addressing, but still no luck

---

<div class="post-metadata">

**Author:** ![Matrix\_Engineering](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/matrix_engineering/32/19781_2.png) [@Matrix\_Engineering](https://forum.inductiveautomation.com/u/Matrix_Engineering)\
**Post date:** [October 5, 2021, 8:00pm UTC](https://forum.inductiveautomation.com/t/holding-register-for-modbus-tcp/51633/5 "2021-10-05T20:00:26Z")

</div>

When in similar situations I use ModPoll etc as a sanity check, then go back to Ignition once verified

---

<div class="post-metadata">

**Author:** ![loc.le](https://avatars.discourse-cdn.com/v4/letter/l/94ad74/32.png) [@loc.le](https://forum.inductiveautomation.com/u/loc.le)\
**Post date:** [October 5, 2021, 8:32pm UTC](https://forum.inductiveautomation.com/t/holding-register-for-modbus-tcp/51633/6 "2021-10-05T20:32:37Z")

</div>

I wish I could do it. Because I am using company laptop, IT does not let me install any third party app

---

<div class="post-metadata">

**Author:** ![josborn](https://avatars.discourse-cdn.com/v4/letter/j/4bbf92/32.png) [@josborn](https://forum.inductiveautomation.com/u/josborn)\
**Post date:** [October 5, 2021, 8:46pm UTC](https://forum.inductiveautomation.com/t/holding-register-for-modbus-tcp/51633/7 "2021-10-05T20:46:57Z")

</div>

Try changing your data type to byte?

---

<div class="post-metadata">

**Author:** ![loc.le](https://avatars.discourse-cdn.com/v4/letter/l/94ad74/32.png) [@loc.le](https://forum.inductiveautomation.com/u/loc.le)\
**Post date:** [October 5, 2021, 8:49pm UTC](https://forum.inductiveautomation.com/t/holding-register-for-modbus-tcp/51633/8 "2021-10-05T20:49:32Z")

</div>

I did but still the same, feel like the they are not matching with modbus guide of the device

---

<div class="post-metadata">

**Author:** ![josborn](https://avatars.discourse-cdn.com/v4/letter/j/4bbf92/32.png) [@josborn](https://forum.inductiveautomation.com/u/josborn)\
**Post date:** [October 5, 2021, 8:56pm UTC](https://forum.inductiveautomation.com/t/holding-register-for-modbus-tcp/51633/9 "2021-10-05T20:56:43Z")

</div>

What value are you expecting? Does the register change when you preset different tags?

---

<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:** [October 5, 2021, 8:59pm UTC](https://forum.inductiveautomation.com/t/holding-register-for-modbus-tcp/51633/10 "2021-10-05T20:59:00Z")

</div>

Your OPC Item Path is not correct for a string:  
[https://docs.inductiveautomation.com/display/DOC81/Modbus+Addressing](https://docs.inductiveautomation.com/display/DOC81/Modbus+Addressing)

Your example should be something like `[RFIDReader01]1.HRS220:12`

---

<div class="post-metadata">

**Author:** ![loc.le](https://avatars.discourse-cdn.com/v4/letter/l/94ad74/32.png) [@loc.le](https://forum.inductiveautomation.com/u/loc.le)\
**Post date:** [October 5, 2021, 9:13pm UTC](https://forum.inductiveautomation.com/t/holding-register-for-modbus-tcp/51633/11 "2021-10-05T21:13:10Z")

</div>

Thank you for your advice, I tried it before and the result is partial of the device’s MAC address

 ![result1](https://us1.discourse-cdn.com/inductiveautomation/original/3X/3/d/3da3281f7231b5d77aac67c9ceeb9f0a4e5c52f6.png)

not the EPC Id which I should get, example of EPC Id is like the picture below:

 ![MicrosoftTeams-image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/c/e/cee8ca5992f2106d260400562708dfedfa5b3c90.jpeg)

---

<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:** [October 5, 2021, 9:18pm UTC](https://forum.inductiveautomation.com/t/holding-register-for-modbus-tcp/51633/12 "2021-10-05T21:18:10Z")

</div>

Then it isn’t really a string, but an array of bytes. You’ll need to convert the characters in that string to hex bytes. There’s no built-in tool for that.

---

<div class="post-metadata">

**Author:** ![loc.le](https://avatars.discourse-cdn.com/v4/letter/l/94ad74/32.png) [@loc.le](https://forum.inductiveautomation.com/u/loc.le)\
**Post date:** [October 5, 2021, 9:30pm UTC](https://forum.inductiveautomation.com/t/holding-register-for-modbus-tcp/51633/13 "2021-10-05T21:30:08Z")

</div>

Sorry I don’t get it, do you mean that I should convert string to hex like this website? [Hex to String Converter | Convert Your Hexadecimal To Text](https://string-functions.com/hex-string.aspx)

---

<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:** [October 5, 2021, 9:31pm UTC](https://forum.inductiveautomation.com/t/holding-register-for-modbus-tcp/51633/14 "2021-10-05T21:31:40Z")

</div>

Yes, but text to hex.

---

<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:** [October 5, 2021, 9:40pm UTC](https://forum.inductiveautomation.com/t/holding-register-for-modbus-tcp/51633/15 "2021-10-05T21:40:10Z")

</div>

I just noticed that the offsets in your structure screenshot are bytes. Modbus registers are 16-bit. So the address should be `1.HRS210:12`. But you’ll still need to convert to hex.

---

<div class="post-metadata">

**Author:** ![loc.le](https://avatars.discourse-cdn.com/v4/letter/l/94ad74/32.png) [@loc.le](https://forum.inductiveautomation.com/u/loc.le)\
**Post date:** [October 5, 2021, 9:46pm UTC](https://forum.inductiveautomation.com/t/holding-register-for-modbus-tcp/51633/16 "2021-10-05T21:46:41Z")

</div>

![test1](https://us1.discourse-cdn.com/inductiveautomation/original/3X/b/3/b3f536b4372ea709706ff0fb8ff7211dbe461620.png)  
I tried but it looks weird. When I converted it to hex (by both ways you said) the result is not what I expected

---

<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:** [October 5, 2021, 9:54pm UTC](https://forum.inductiveautomation.com/t/holding-register-for-modbus-tcp/51633/17 "2021-10-05T21:54:08Z")

</div>

I don’t see where you are converting to hex. The raw bytes might also have been interpreted as UTF8 by Ignition, in which case the hex conversion won’t work. You may need to bring in each of the six words as unsigned integers and print them with a `%04x` format.

---

<div class="post-metadata">

**Author:** ![loc.le](https://avatars.discourse-cdn.com/v4/letter/l/94ad74/32.png) [@loc.le](https://forum.inductiveautomation.com/u/loc.le)\
**Post date:** [October 6, 2021, 3:54pm UTC](https://forum.inductiveautomation.com/t/holding-register-for-modbus-tcp/51633/18 "2021-10-06T15:54:44Z")

</div>

![test2](https://us1.discourse-cdn.com/inductiveautomation/original/3X/8/2/82adad531213cd8b727129f3d00310ee05bc61e4.png)  
Thank you so much, it seems working now. I think I need more time to figure out how the device works

---

<div class="post-metadata">

**Author:** ![Abraham\_Guerra](https://avatars.discourse-cdn.com/v4/letter/a/f04885/32.png) [@Abraham\_Guerra](https://forum.inductiveautomation.com/u/Abraham_Guerra)\
**Post date:** [December 27, 2021, 6:18pm UTC](https://forum.inductiveautomation.com/t/holding-register-for-modbus-tcp/51633/19 "2021-12-27T18:18:56Z")

</div>

I read in the user manual that i need a license to be able to use modbus protocol. You did those steps?

---

<div class="post-metadata">

**Author:** ![josborn](https://avatars.discourse-cdn.com/v4/letter/j/4bbf92/32.png) [@josborn](https://forum.inductiveautomation.com/u/josborn)\
**Post date:** [December 27, 2021, 6:24pm UTC](https://forum.inductiveautomation.com/t/holding-register-for-modbus-tcp/51633/20 "2021-12-27T18:24:23Z")

</div>

It used to be that you had to purchase the modbus driver separately, but its now included in the base platform. That change was somewhat recent-ish.

[Next page](https://forum.inductiveautomation.com/t/holding-register-for-modbus-tcp/51633.md?page=2)
