# URCap Sample: Get Controller Time in URScript

**URL:** https://forum.universal-robots.com/t/urcap-sample-get-controller-time-in-urscript/1256
**Category:** URCap Development
**Tags:** urcap-sample
**Created:** [October 13, 2017, 8:30am UTC](https://forum.universal-robots.com/t/urcap-sample-get-controller-time-in-urscript/1256 "2017-10-13T08:30:06Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![jbm](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.universal-robots.com/jbm/32/614_2.png) [@jbm](https://forum.universal-robots.com/u/jbm)
#### Post date: [October 13, 2017, 8:30am UTC](https://forum.universal-robots.com/t/urcap-sample-get-controller-time-in-urscript/1256/1 "2017-10-13T08:30:06Z")

</div>

**Get Controller Time in URScript**

**Description of functionality:**  
This URCap is in functionality very similar to the [XML-RPC Math sample](http://forum.universal-robots.com/t/sample-xml-rpc-math-urcap/1193/4). However instead of contributing an XML-RPC daemon to expand math functionality, this URCap enables the user through URScript to access the controller time (respectively as year, month, date, hour, etc.) via an XML-RPC call to a Python daemon.  
Script functions to read these values over URScript are added to the Functions list in the Expression Editor.

**What topics are covered:**  
XML-RPC, daemon, Python, controller clock, time, Expression Editor, script functions

[Find it on Github!](https://github.com/BomMadsen/URCap-getControllerTime)

---

<div class="post-metadata">

### Author: ![anon21401016](https://avatars.discourse-cdn.com/v4/letter/a/f08c70/32.png) [@anon21401016](https://forum.universal-robots.com/u/anon21401016)
#### Post date: [May 6, 2021, 7:18am UTC](https://forum.universal-robots.com/t/urcap-sample-get-controller-time-in-urscript/1256/2 "2021-05-06T07:18:37Z")

</div>

Hi @jbm ,

I have a UR10 with 3.15 software and I am trying to install your URCap.  
The installation was successful and the system sees it correctly. Unfortunately, I don’t have any new features added to the function list, neither in the script nor in the assigment.  
After installation, of course, I restarted the robot.

Help me, please.

Thanks,  
Michał

---

<div class="post-metadata">

### Author: ![jbm](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.universal-robots.com/jbm/32/614_2.png) [@jbm](https://forum.universal-robots.com/u/jbm)
#### Post date: [May 6, 2021, 8:20am UTC](https://forum.universal-robots.com/t/urcap-sample-get-controller-time-in-urscript/1256/3 "2021-05-06T08:20:39Z")

</div>

Hi @anon21401016  
There is an Instalation Node added by the URCap.  
You need to select the checkbox in this to add the script functions to the Functions-list.

---

<div class="post-metadata">

### Author: ![anon21401016](https://avatars.discourse-cdn.com/v4/letter/a/f08c70/32.png) [@anon21401016](https://forum.universal-robots.com/u/anon21401016)
#### Post date: [May 6, 2021, 8:57am UTC](https://forum.universal-robots.com/t/urcap-sample-get-controller-time-in-urscript/1256/4 "2021-05-06T08:57:37Z")

</div>

Now I see :).

Thank you very much, everything is fine.

---

<div class="post-metadata">

### Author: ![anon92957640](https://avatars.discourse-cdn.com/v4/letter/a/e9a140/32.png) [@anon92957640](https://forum.universal-robots.com/u/anon92957640)
#### Post date: [August 10, 2022, 5:33pm UTC](https://forum.universal-robots.com/t/urcap-sample-get-controller-time-in-urscript/1256/5 "2022-08-10T17:33:38Z")

</div>

Thanks for this, it is pretty amazing. Is there a channel to learn the intricacies that went to make this URCap?

---

<div class="post-metadata">

### Author: ![brjames](https://avatars.discourse-cdn.com/v4/letter/b/e274bd/32.png) [@brjames](https://forum.universal-robots.com/u/brjames)
#### Post date: [June 30, 2023, 8:48pm UTC](https://forum.universal-robots.com/t/urcap-sample-get-controller-time-in-urscript/1256/6 "2023-06-30T20:48:38Z")

</div>

Hello. Is there an updated UR CAP? I’m currently using 1.0.0… Was just wondering if there us an updated version.
