diff --git a/libraries/AP_Scripting/docs/docs.lua b/libraries/AP_Scripting/docs/docs.lua index 336495f8a0..3208c6ac22 100644 --- a/libraries/AP_Scripting/docs/docs.lua +++ b/libraries/AP_Scripting/docs/docs.lua @@ -1495,11 +1495,21 @@ ins = {} ---@return number function ins:get_temperature(instance) end +-- Check if the gyrometers are consistent +---@param threshold integer -- the allowed threshold in degrees per second +---@return boolean +function ins:gyros_consistent(threshold) end + -- Check if a specific gyroscope sensor is healthy ---@param instance integer -- the 0-based index of the gyroscope instance to return. ---@return boolean function ins:get_gyro_health(instance) end +-- Check if the accelerometers are consistent +---@param threshold float -- the threshold allowed before returning false +---@return boolean +function ins:accels_consistent(threshold) end + -- Check if a specific accelerometer sensor is healthy ---@param instance integer -- the 0-based index of the accelerometer instance to return. ---@return boolean diff --git a/libraries/AP_Scripting/generator/description/bindings.desc b/libraries/AP_Scripting/generator/description/bindings.desc index f8860dce6d..7a2d88e470 100644 --- a/libraries/AP_Scripting/generator/description/bindings.desc +++ b/libraries/AP_Scripting/generator/description/bindings.desc @@ -636,10 +636,12 @@ singleton AP_InertialSensor depends AP_INERTIALSENSOR_ENABLED singleton AP_InertialSensor rename ins singleton AP_InertialSensor method get_temperature float uint8_t 0 INS_MAX_INSTANCES singleton AP_InertialSensor method get_gyro_health boolean uint8_t'skip_check +singleton AP_InertialSensor method accels_consistent boolean float'skip_check singleton AP_InertialSensor method get_accel_health boolean uint8_t'skip_check singleton AP_InertialSensor method calibrating boolean singleton AP_InertialSensor method get_gyro Vector3f uint8_t'skip_check singleton AP_InertialSensor method get_accel Vector3f uint8_t'skip_check +singleton AP_InertialSensor method gyros_consistent boolean uint8_t'skip_check singleton CAN manual get_device lua_get_CAN_device 1 singleton CAN manual get_device2 lua_get_CAN_device2 1