Firmware
Functions
geofence_params.c File Reference

Parameters for geofence. More...

Functions

 PARAM_DEFINE_INT32 (GF_ACTION, 1)
 Geofence violation action. More...
 
 PARAM_DEFINE_INT32 (GF_ALTMODE, 0)
 Geofence altitude mode. More...
 
 PARAM_DEFINE_INT32 (GF_SOURCE, 0)
 Geofence source. More...
 
 PARAM_DEFINE_INT32 (GF_COUNT, -1)
 Geofence counter limit. More...
 
 PARAM_DEFINE_FLOAT (GF_MAX_HOR_DIST, 0)
 Max horizontal distance in meters. More...
 
 PARAM_DEFINE_FLOAT (GF_MAX_VER_DIST, 0)
 Max vertical distance in meters. More...
 

Detailed Description

Parameters for geofence.

Author
Thomas Gubler thoma.nosp@m.sgub.nosp@m.ler@g.nosp@m.mail.nosp@m..com

Function Documentation

§ PARAM_DEFINE_FLOAT() [1/2]

PARAM_DEFINE_FLOAT ( GF_MAX_HOR_DIST  ,
 
)

Max horizontal distance in meters.

Maximum horizontal distance in meters the vehicle can be from home before triggering a geofence action. Disabled if 0.

m 0 10000 1 Geofence

§ PARAM_DEFINE_FLOAT() [2/2]

PARAM_DEFINE_FLOAT ( GF_MAX_VER_DIST  ,
 
)

Max vertical distance in meters.

Maximum vertical distance in meters the vehicle can be from home before triggering a geofence action. Disabled if 0.

m 0 10000 1 Geofence

§ PARAM_DEFINE_INT32() [1/4]

PARAM_DEFINE_INT32 ( GF_ACTION  ,
 
)

Geofence violation action.

Note: Setting this value to 4 enables flight termination, which will kill the vehicle on violation of the fence. Due to the inherent danger of this, this function is disabled using a software circuit breaker, which needs to be reset to 0 to really shut down the system.

0 4 0 None 1 Warning 2 Hold mode 3 Return mode 4 Terminate Geofence

§ PARAM_DEFINE_INT32() [2/4]

PARAM_DEFINE_INT32 ( GF_ALTMODE  ,
 
)

Geofence altitude mode.

Select which altitude reference should be used 0 = WGS84, 1 = AMSL

0 1 0 WGS84 1 AMSL Geofence

§ PARAM_DEFINE_INT32() [3/4]

PARAM_DEFINE_INT32 ( GF_SOURCE  ,
 
)

Geofence source.

Select which position source should be used. Selecting GPS instead of global position makes sure that there is no dependence on the position estimator 0 = global position, 1 = GPS

0 1 0 GPOS 1 GPS Geofence

§ PARAM_DEFINE_INT32() [4/4]

PARAM_DEFINE_INT32 ( GF_COUNT  ,
1 
)

Geofence counter limit.

Set how many subsequent position measurements outside of the fence are needed before geofence violation is triggered

-1 10 1 Geofence