[PEAK] Trellis: tasks and discrete sensors
Phillip J. Eby
pje at telecommunity.com
Thu Oct 9 13:21:06 EDT 2008
At 08:03 PM 10/9/2008 +0300, Sergey Schetinin wrote:
>This test shows that @task rules never get to see discrete values. It
>prints 'waiting' twice, so they are triggered, but sensor value is
>None both times.
This is a documented limitation, or at least it should be documented. :)
Tasks can't read discrete values because a task step cannot be
"undone". This is why they are only run from the system event
loop. If you need to communicate discrete events to a task, you will
need to write them to a list or something of that sort, and then have
the task read and remove them.
More information about the PEAK
mailing list