-
Notifications
You must be signed in to change notification settings - Fork 2
Project Status
Jules van der Toorn edited this page Jan 2, 2021
·
4 revisions
The project status interface makes it possible to query project related internal parameters. Specifically, it can be queried to check if the project is in a Listen
node and if a certain queue tag has been completed.
To setup a connection with the project status interface:
async with techmanpy.connect_sta(robot_ip, [conn_timeout]) as conn:
# connection established
...
-
robot_ip: str
| mandatory kwarg
The IP address of the robot -
conn_timeout: int (s)
| optional kwarg, default = 3
The duration before a connection attempt times out
Given the connection object conn
, various actions can be performed. These will now be discussed.
in_listen_node = await conn.is_listen_node_active()
Returns True
if the project is currently in a Listen
node, otherwise it will return False
.
To query the status of a queue tag:
tag_status = await conn.get_queue_tag_status(tag_id)
-
tag_id: int
| mandatory arg
The queue tag identifier, any value between 1 and 15
Returns True
if the queue up until the tag completed, otherwise it will return False
.