46 #define NormAngleRad(x) { \
47 int dont_loop_forever = 0; \
48 while ((x < (-M_PI)) && ++dont_loop_forever) x += (2 * M_PI); \
49 while ((x >= (M_PI)) && ++dont_loop_forever) x -= (2 * M_PI); \
80 diff = DegOfRad(diff);
86 float range = viewangle / 2.0f;
91 if (fabs(diff) > range) {
void run_avoid_navigation_onvision(void)
void stereo_avoid_run(void)
static struct FloatEulers * stateGetNedToBodyEulers_f(void)
Get vehicle body attitude euler angles (float).
struct AvoidNavigationStruct avoid_navigation_data
global VIDEO state
void stereo_avoid_init(void)
void stereo_avoid_stop(void)
static struct EnuCoor_f * stateGetPositionEnu_f(void)
Get position in local ENU coordinates (float).
void stereo_avoid_start(void)
API to get/set the generic vehicle states.
#define NormAngleRad(x)
Normalize a degree angle between 0 and 359.
void init_avoid_navigation()