# swingToolbarService and editing modbus variable

**URL:** <https://forum.universal-robots.com/t/swingtoolbarservice-and-editing-modbus-variable/25674>\
**Category:** General Application Help: How do I?\
**Created:** [December 14, 2022, 12:55pm UTC](https://forum.universal-robots.com/t/swingtoolbarservice-and-editing-modbus-variable/25674 "2022-12-14T12:55:44Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![eric.feldmann](https://avatars.discourse-cdn.com/v4/letter/e/94ad74/32.png) [@eric.feldmann](https://forum.universal-robots.com/u/eric.feldmann)\
**Post date:** [December 14, 2022, 1:20pm UTC](https://forum.universal-robots.com/t/swingtoolbarservice-and-editing-modbus-variable/25674/2 "2022-12-14T13:20:19Z")

</div>

Unfortunately we aren’t given access to any of the GPIO registers/booleans through the API. This has been a pain point for me for a long time. The closest thing you can get is to be able to SEE the value of NAMED registers, but there’s no methods to actually write to their value. This is not the case for the physical IO, which you CAN write to from the API. Seems completely backwards to me, but that’s the way it is.

That said, I’ve used these classes before to send URScript via Java to get the job done:

> [@URCap Sample: URCap-ScriptCommunicator](https://forum.universal-robots.com/t/urcap-sample-urcap-scriptcommunicator/8460):
>
> Dear community, I have forked Jacobs URCap-ScriptCommunicator and added the framework to proxy URScript functions from Java. So far it is only a subset of the functions that are implemented yet. I hope you will add the functions when you need is there and then share it with the rest of the community! Description of functionality: This sample implements a Java class to: Send URScript commands for immediate execution by URControl Extract a variable from URScript to Java Proxy URScript functio…

So you can just send the URScript that can write to a MODBUS register (assuming it exists). The downside here is that this method of communication is noticeably laggy, and gets REALLY bad if you spam click to send a log of scripts rapidly.

---

_[View the full topic](https://forum.universal-robots.com/t/swingtoolbarservice-and-editing-modbus-variable/25674)._
