# MODBUS Addressing High and Low Bytes

**URL:** <https://forum.inductiveautomation.com/t/modbus-addressing-high-and-low-bytes/52070>\
**Category:** Ignition\
**Tags:** ignition81\
**Created:** [October 18, 2021, 6:33pm UTC](https://forum.inductiveautomation.com/t/modbus-addressing-high-and-low-bytes/52070 "2021-10-18T18:33:45Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![pridesleap](https://avatars.discourse-cdn.com/v4/letter/p/f4b2a3/32.png) [@pridesleap](https://forum.inductiveautomation.com/u/pridesleap)\
**Post date:** [October 18, 2021, 6:33pm UTC](https://forum.inductiveautomation.com/t/modbus-addressing-high-and-low-bytes/52070/1 "2021-10-18T18:33:45Z")

</div>

Hello all.

I have connected to a device using OPC MODBUS RTU over TCP. I’m receiving good data for most of the points I need to bring into the SCADA but I have a question about splitting up a 16bit packed register. I need to read the high and low bytes. I believe what I need to do is first bring in the full 16bit register as a tag and then use an expression tag to perform the read function with an expression. My questions are:

1. Is this a correct workflow?
2. If so, does anyone know what the correct expression would be?

---

<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:** [October 18, 2021, 6:39pm UTC](https://forum.inductiveautomation.com/t/modbus-addressing-high-and-low-bytes/52070/2 "2021-10-18T18:39:25Z")

</div>

You’ve got the right idea.

The expressions would look something this:  
High Byte: `({PathToRegisterTag} >> 8) & 0xFF`  
Low Byte: `{PathToRegisterTag} & 0xFF`

---

<div class="post-metadata">

**Author:** ![pridesleap](https://avatars.discourse-cdn.com/v4/letter/p/f4b2a3/32.png) [@pridesleap](https://forum.inductiveautomation.com/u/pridesleap)\
**Post date:** [October 18, 2021, 6:52pm UTC](https://forum.inductiveautomation.com/t/modbus-addressing-high-and-low-bytes/52070/3 "2021-10-18T18:52:31Z")

</div>

Perfect! That worked a treat. Thanks for the quick resposne.
