# Write in "UCHAR4" format by Modbus with function 16

**URL:** <https://forum.inductiveautomation.com/t/write-in-uchar4-format-by-modbus-with-function-16/79783>\
**Category:** Ignition\
**Tags:** ignition80\
**Created:** [September 28, 2023, 12:58pm UTC](https://forum.inductiveautomation.com/t/write-in-uchar4-format-by-modbus-with-function-16/79783 "2023-09-28T12:58:39Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Alberto\_AG](https://avatars.discourse-cdn.com/v4/letter/a/c4cdca/32.png) [@Alberto\_AG](https://forum.inductiveautomation.com/u/Alberto_AG)\
**Post date:** [September 28, 2023, 12:58pm UTC](https://forum.inductiveautomation.com/t/write-in-uchar4-format-by-modbus-with-function-16/79783/1 "2023-09-28T12:58:39Z")

</div>

Hello.  
I need to write a password on a device in " **UCHAR4**" format by **Modbus** with **function 16**.  
This is the memory map of the variable:  
 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/3/5/35c24f5fcddcd6c5090784d62231fe6ae8332a9b.png)  
 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/d/9/d95c29817242e2c45b1914a8174874ea683fff4a.png)

I have configured a tag with this **OPC item path** to write to that address. It's right?

_**[device]1.HRS168:4**_ (The password is made up of 4 characters)

Best Regards.

---

<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:** [September 28, 2023, 1:00pm UTC](https://forum.inductiveautomation.com/t/write-in-uchar4-format-by-modbus-with-function-16/79783/2 "2023-09-28T13:00:08Z")

</div>

Meh, maybe. Don't know what `UCHAR4` means or if it matches the String behavior of the Modbus driver, which I think tries to write empty spaces at the end if you don't provide a String of the full length.

You'll have to try it and see.
