# Read Digital Input from URCap

**URL:** <https://forum.universal-robots.com/t/read-digital-input-from-urcap/17785>\
**Category:** URCap Development\
**Created:** [November 23, 2021, 5:08pm UTC](https://forum.universal-robots.com/t/read-digital-input-from-urcap/17785 "2021-11-23T17:08:52Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![jan.cremer](https://avatars.discourse-cdn.com/v4/letter/j/43a26b/32.png) [@jan.cremer](https://forum.universal-robots.com/u/jan.cremer)\
**Post date:** [November 23, 2021, 5:08pm UTC](https://forum.universal-robots.com/t/read-digital-input-from-urcap/17785/1 "2021-11-23T17:08:52Z")

</div>

Hi,

I would like to read the state of a digital input inside my urcap. I connected to the Secondary Client interface and tried to read the digital input bits, but somehow these (always zero) don’t seem to reflect the state if the digital inputs as shown inside the tablets I/O tab. What am I doing wrong?

Best regards!

---

<div class="post-metadata">

**Author:** ![anon75712119](https://avatars.discourse-cdn.com/v4/letter/a/8e8cbc/32.png) [@anon75712119](https://forum.universal-robots.com/u/anon75712119)\
**Post date:** [November 24, 2021, 5:30am UTC](https://forum.universal-robots.com/t/read-digital-input-from-urcap/17785/2 "2021-11-24T05:30:14Z")

</div>

You can use RTDE Port to get DIO State in 125HZ.

---

<div class="post-metadata">

**Author:** ![jan.cremer](https://avatars.discourse-cdn.com/v4/letter/j/43a26b/32.png) [@jan.cremer](https://forum.universal-robots.com/u/jan.cremer)\
**Post date:** [November 24, 2021, 7:53am UTC](https://forum.universal-robots.com/t/read-digital-input-from-urcap/17785/3 "2021-11-24T07:53:10Z")

</div>

mh, yeah, thats what i feared 😉 yet another communication/synchronization overhead

---

<div class="post-metadata">

**Author:** ![jan.cremer](https://avatars.discourse-cdn.com/v4/letter/j/43a26b/32.png) [@jan.cremer](https://forum.universal-robots.com/u/jan.cremer)\
**Post date:** [November 24, 2021, 9:49am UTC](https://forum.universal-robots.com/t/read-digital-input-from-urcap/17785/4 "2021-11-24T09:49:32Z")

</div>

Any idea why the data in the secondary interface Motherboarddata does not reflect the digital input states?

---

<div class="post-metadata">

**Author:** ![anon75712119](https://avatars.discourse-cdn.com/v4/letter/a/8e8cbc/32.png) [@anon75712119](https://forum.universal-robots.com/u/anon75712119)\
**Post date:** [November 24, 2021, 10:15am UTC](https://forum.universal-robots.com/t/read-digital-input-from-urcap/17785/5 "2021-11-24T10:15:23Z")

</div>

RTDE is way to read almost all data from robot in 125HZ , UR also prefer RTDE to use in that case. Sorry I don’t about secondary interface.

---

<div class="post-metadata">

**Author:** ![krmi](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.universal-robots.com/krmi/32/1945_2.png) [@krmi](https://forum.universal-robots.com/u/krmi)\
**Post date:** [November 24, 2021, 1:55pm UTC](https://forum.universal-robots.com/t/read-digital-input-from-urcap/17785/6 "2021-11-24T13:55:49Z")

</div>

There are also URScript functions to get the state of digital/analog I/O if you look in the Script manual (Module 16: interfaces).
