wait for vizproximity and waitKeyDown in task
Hi,
my name is Jeroen and I'm having troubles with waiting inside a viztask. I would like to have to wait for an vizproximity.waitEnter and for an waitKeyDown. If one of them occurs go on, otherwise wait. Code:
d = yield viztask.waitAny(vizproximity.waitEnter([c2Sensor]), viztask.waitKeyDown( ["t"] )) TypeError: 'waitEnter' object is not iterable I thought adding viztask. in front of vizproximity would work but that results in: AttributeError: 'module' object has no attribute 'vizproximity' Does anyone have any tips \ pointers \ advise on how I can do this? Thank you! |
If you place the conditions to wait for in a list it should work:
Code:
yield viztask.waitAny([vizproximity.waitEnter(c2Sensor),viztask.waitKeyDown("t")]) |
Ah Jeff, thanks for the reply! Monday I'm able to try, but I.m positive this works.
|
All times are GMT -7. The time now is 10:44 PM. |
Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Copyright 2002-2023 WorldViz LLC