Hazard Avoidance
For clients to use the hazard_avoidance service
- exception bosdyn.client.hazard_avoidance.AddHazardsResponseError(response, error_message=None)[source]
Bases:
ResponseErrorGeneral class of errors for hazard avoidance service.
- class bosdyn.client.hazard_avoidance.HazardAvoidanceClient[source]
Bases:
BaseClientClient for Hazard avoidance service.
- default_service_name = 'hazard-avoidance-service'
- service_type = 'bosdyn.api.HazardAvoidanceService'
- property timesync_endpoint
Accessor for timesync-endpoint that is grabbed via ‘update_from()’.
- Raises:
bosdyn.client.robot_command.NoTimeSyncError – Could not find the timesync endpoint for the robot.
- add_hazards(add_hazards_req, **kwargs)[source]
Add hazards to the hazard map.
- Parameters:
add_hazards_req (hazard_avoidance_pb2.AddHazardsRequest) – The request including the hazard observations to add.
- Returns:
Contains the status of adding each observation,
- Return type:
response (hazard_avoidance_pb2.AddHazardsResponse)
- Raises:
RpcError – Problem communicating with the robot.
bosdyn.client.robot_command.NoTimeSyncError – Couldn’t convert the timestamp into robot time.
UnsetStatusError – An internal HazardAvoidanceService issue has happened.
AddHazardsResponseError – General problem with the request.
bosdyn.client.exceptions.InvalidRequestError – One or more hazard observations contained errors.