Async Tasks
Utilities for managing periodic tasks consisting of asynchronous GRPC calls.
- class bosdyn.client.async_tasks.AsyncTasks(tasks=None)[source]
Bases:
object
Manages a set of tasks which work by periodically calling an update() method.
- Parameters:
tasks – List of tasks to manage.
- class bosdyn.client.async_tasks.AsyncGRPCTask[source]
Bases:
object
Task to be accomplished using asynchronous GRPC calls.
When it is time to run the task, an async GRPC call is run resulting in a FutureWrapper object. The FutureWrapper is monitored for completion, and then an action is taken in response.
- class bosdyn.client.async_tasks.AsyncPeriodicGRPCTask(period_sec)[source]
Bases:
AsyncGRPCTask
Periodic task to be accomplished using asynchronous GRPC calls.
When it is time to run the task, an async GRPC call is run resulting in a FutureWrapper object. The FutureWrapper is monitored for completion, and then an action is taken in response.
- Parameters:
periodic_sec – Time to wait in seconds between queries.
- class bosdyn.client.async_tasks.AsyncPeriodicQuery(query_name, client, logger, period_sec)[source]
Bases:
AsyncPeriodicGRPCTask
Query for robot data at some regular interval.
- Parameters:
query_name – Name of the query.
client – SDK client for the query.
logger – Logger to use for logging errors.
periodic_sec – Time in seconds between running the query.
- property proto
Get latest response proto.