This page last changed on Feb 27, 2012 by happybird.

Hi - using the staging designer, you are able to set a refresh time for each sensor - http://www.openremote.org/display/docs/OpenRemote+2.0+How+To+-+1-Wire+Sensors

Has this feature been merged into an alpha release of the controller - I am currently using Controller_2_0_0_Alpha11. As far as I can see it's not in this tagged code.

In addition, from my glance the existing Alpha11 code does not seem to kill/restart sensor threads properly when the config changes. The threads continue. Before I went too much into the detail, I was wonder where I might find the implementation to support min refresh time, and try that. I also would have thought having one thread per sensor, is very heavy on resources. Maybe one thread to iterate through the sensors, another thread to monitor the sensor thread.

Last question, is there a url or way to stop/pause the sensors while controller is running, then resume. I don't think there is - but as my mother said it's best to ask. (Sometimes you don't know what you don't know).

Loving this project - learning more each day

hi, i think you can have a look at the latest snaphot of thevcontroller. Should have tag like 20120103 and available on svn
for the stop/pause feaure, don't think that exist

Posted by yannph at Feb 27, 2012 20:17

Thanks Yann - Ill take a look. I've just changed my local Alpha11 version to only use a single thread and iterate around the sensors - (rather than a thread per sensor). The services I have do not block - I haven't implemented a monitor, or executer thread as I am just playing and learning.

I was having problems as I am trying to run controller under Karaf, and Karaf uses quite a few threads. It was getting too much for my Alix board. What I also did was slow down the sensor refresh if there is an error - right down to one http get per miniute. As soon as a failed service resumes and went good, the sensor loop notices and resumes with the appropriate short delay. I did this because Controller hammers the http services no matter if they are available or are off line.

Thanks for the pointer... everyone's work is sincerely appreciated.

Edit It does look like threads are not being stopped when you stop and restart a WAB - So I changed my local code to terminated the thread when the context closes - this solves the rouge threads from continuing.

Posted by happybird at Feb 27, 2012 21:28

Hi Yann - just having my first coffee of the day and browsing svn - https://openremote.svn.sourceforge.net/svnroot/openremote/tags - I don't appear to see any code tagged as 20120103. Am I looking in the wrong place?

Posted by happybird at Feb 28, 2012 08:24

The version 20120103 is not tagged. That is just the date we put the zip togeteher.
It's based on the controller from this source location: http://openremote.svn.sourceforge.net/viewvc/openremote/workspace/juha/Controller_EP_SNAP_20111129/
Juha is currently doing some more work in that version and will release as final 2.0 soon.

Posted by mredeker at Feb 28, 2012 09:38

Nice Marcus - At first glance it looks like there's a better model for managing sensors. Thank you for the pointer.

Posted by happybird at Feb 28, 2012 10:01

Thank you to correct me Marcus, still have to learn the subtlety of the release process
regards

Posted by yannph at Feb 28, 2012 16:48
Document generated by Confluence on Jun 05, 2016 09:31