2022-07-05 04:28:24 -03:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include <AP_Param/AP_Param.h>
|
|
|
|
#include <AP_Math/AP_Math.h>
|
|
|
|
|
2022-07-05 04:38:28 -03:00
|
|
|
#define PROXIMITY_MAX_IGNORE 4 // up to six areas can be ignored
|
2022-07-05 04:28:24 -03:00
|
|
|
|
|
|
|
class AP_Proximity_Params {
|
|
|
|
|
|
|
|
public:
|
|
|
|
|
|
|
|
static const struct AP_Param::GroupInfo var_info[];
|
|
|
|
|
|
|
|
AP_Proximity_Params(void);
|
|
|
|
|
|
|
|
/* Do not allow copies */
|
2022-09-30 06:50:43 -03:00
|
|
|
CLASS_NO_COPY(AP_Proximity_Params);
|
2022-07-05 04:28:24 -03:00
|
|
|
|
|
|
|
AP_Int8 type; // type of sensor
|
|
|
|
AP_Int8 orientation; // orientation (e.g. right-side-up or upside-down)
|
|
|
|
AP_Int16 yaw_correction; // yaw correction in degrees
|
|
|
|
AP_Int16 ignore_angle_deg[PROXIMITY_MAX_IGNORE]; // angle (in degrees) of area that should be ignored by sensor (i.e. leg shows up)
|
|
|
|
AP_Int8 ignore_width_deg[PROXIMITY_MAX_IGNORE]; // width of beam (in degrees) that should be ignored
|
|
|
|
AP_Float max_m; // maximum range in meters
|
|
|
|
AP_Float min_m; // minimum range in meters
|
2022-09-27 16:44:39 -03:00
|
|
|
AP_Int8 address; // proximity address (for AP_Periph CAN)
|
2022-07-05 04:28:24 -03:00
|
|
|
};
|