跳至内容

距离传感器(UORB 信息)

DISTANCE_SENSOR 报文数据

源文件

c
# DISTANCE_SENSOR 报文数据

uint64 timestamp # 系统运行以来的时间 启动 (微秒)

uint32 device_id # 唯一设备 ID 对于 在电源周期之间不发生变化的传感器

float32 min_distance # 传感器可以测得的最小距离 衡量 (在 m)
float32 max_distance # 传感器可测得的最大距离 衡量 (在 m)
float32 current_distance # 当前距离 阅读 (在 m)
float32 variance # 测量 差异 (单位:米^2), 0 对于 未知 / 无效读数
int8 signal_quality # 信号质量单位 百分比 (0...100%),其中 0 = 信号无效、 100 = 完美信号,以及 -1 = 信号质量未知。

uint8 type # 来自 MAV_DISTANCE_SENSOR 的类型 枚举
uint8 MAV_DISTANCE_SENSOR_LASER = 0
uint8 MAV_DISTANCE_SENSOR_ULTRASOUND = 1
uint8 MAV_DISTANCE_SENSOR_INFRARED = 2
uint8 MAV_DISTANCE_SENSOR_RADAR = 3

float32 h_fov # 传感器的水平视场角 观点 (雷达)
float32 v_fov # 传感器的垂直视场 观点 (雷达)
float32[4] q # 相对于车身框架的四元传感器方向,以指定方向 ROTATION_CUSTOM

uint8 方向 # 传感器朝向 MAV_SENSOR_ORIENTATION 的方向 枚举

uint8 ROTATION_YAW_0		= 0 # mav_sensor_rotation_none
uint8 ROTATION_YAW_45		= 1 # mav_sensor_rotation_yaw_45
uint8 ROTATION_YAW_90		= 2 # mav_sensor_rotation_yaw_90
uint8 ROTATION_YAW_135		= 3 # mav_sensor_rotation_yaw_135
uint8 ROTATION_YAW_180		= 4 # mav_sensor_rotation_yaw_180
uint8 ROTATION_YAW_225		= 5 # mav_sensor_rotation_yaw_225
uint8 ROTATION_YAW_270		= 6 # mav_sensor_rotation_yaw_270
uint8 ROTATION_YAW_315		= 7 # mav_sensor_rotation_yaw_315

uint8 ROTATION_FORWARD_FACING	= 0 # mav_sensor_rotation_none
uint8 ROTATION_RIGHT_FACING	= 2 # mav_sensor_rotation_yaw_90
uint8 ROTATION_BACKWARD_FACING	= 4 # mav_sensor_rotation_yaw_180
uint8 ROTATION_LEFT_FACING	= 6 # mav_sensor_rotation_yaw_270

uint8 ROTATION_UPWARD_FACING   = 24 # mav_sensor_rotation_pitch_90
uint8 ROTATION_DOWNWARD_FACING = 25 # mav_sensor_rotation_pitch_270

uint8 ROTATION_CUSTOM          = 100 # mav_sensor_rotation_custom