# devicetree.init() connection refused

**URL:** <https://forum.sierrawireless.com/t/devicetree-init-connection-refused/6741>\
**Category:** ALEOS Application Framework\
**Created:** [September 17, 2013, 6:00am UTC](https://forum.sierrawireless.com/t/devicetree-init-connection-refused/6741 "2013-09-17T06:00:06Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![lauhow](https://sea1.discourse-cdn.com/flex025/user_avatar/forum.sierrawireless.com/lauhow/32/1964_2.png) [@lauhow](https://forum.sierrawireless.com/u/lauhow)\
**Post date:** [September 17, 2013, 6:00am UTC](https://forum.sierrawireless.com/t/devicetree-init-connection-refused/6741/1 "2013-09-17T06:00:06Z")

</div>

Hi,

I’m trying to run the device tree sample script provided with the SDK (\Samples\device-param-access\main.lua) and I’m getting a “connection refused” error when the “init” function is called:

In thread: 0x46300: error: /root/aleos/usr/readyagent/lua/racon/common.lua:30: connection refused  
stack traceback:  
[C]: in function ‘assert’  
/root/aleos/usr/readyagent/lua/racon/common.lua:30: in function ‘init’  
/root/aleos/usr/readyagent/lua/racon/devicetree.lua:152: in function ‘init’  
main.lua:125: in function main.lua:124

Appreciate if someone could shed some light on this.

Many Thanks

william

---

<div class="post-metadata">

**Author:** ![lauhow](https://sea1.discourse-cdn.com/flex025/user_avatar/forum.sierrawireless.com/lauhow/32/1964_2.png) [@lauhow](https://forum.sierrawireless.com/u/lauhow)\
**Post date:** [September 17, 2013, 7:25am UTC](https://forum.sierrawireless.com/t/devicetree-init-connection-refused/6741/2 "2013-09-17T07:25:17Z")

</div>

Looks like the problem went away after repowering the GX400 modem.  
On closer inspection of /root/aleos/usr/readyagent/lua/racon/common.lua:30, it appears that the “devicetree” service (tcp port 9999) wasn’t running.  
It would be good if someone could shed some light on this as we’re intending to run a fairly critical application that requires this service.

The reported ALEOS Software Version is 4.3.2a.010

---

<div class="post-metadata">

**Author:** ![cbugot](https://avatars.discourse-cdn.com/v4/letter/c/c37758/32.png) [@cbugot](https://forum.sierrawireless.com/u/cbugot)\
**Post date:** [September 17, 2013, 8:40am UTC](https://forum.sierrawireless.com/t/devicetree-init-connection-refused/6741/3 "2013-09-17T08:40:53Z")

</div>

The device needs to be restarted once you activate or deactivate AAF in AceManager. If that is not done, you would have exactly the symptoms you described: the service the not launched and you cannot connect to it, even if you can run your application with the IDE.
