APM:Libraries
Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | Static Private Attributes | List of all members
AP_AccelCal Class Reference

#include <AP_AccelCal.h>

Collaboration diagram for AP_AccelCal:
[legend]

Public Member Functions

 AP_AccelCal ()
 
void start (GCS_MAVLINK *gcs)
 
void cancel ()
 
void update ()
 
accel_cal_status_t get_status ()
 
bool gcs_vehicle_position (float position)
 
void handleMessage (const mavlink_message_t *msg)
 

Static Public Member Functions

static void register_client (AP_AccelCal_Client *client)
 

Private Member Functions

void success ()
 
void fail ()
 
void clear ()
 
void collect_sample ()
 
void update_status ()
 
bool check_for_timeout ()
 
bool client_active (uint8_t client_num)
 
AccelCalibratorget_calibrator (uint8_t i)
 
void _printf (const char *,...)
 

Private Attributes

GCS_MAVLINK_gcs
 
bool _use_gcs_snoop
 
bool _waiting_for_mavlink_ack = false
 
uint32_t _last_position_request_ms
 
uint8_t _step
 
accel_cal_status_t _status
 
accel_cal_status_t _last_result
 
bool _started
 
bool _saving
 
uint8_t _num_active_calibrators
 

Static Private Attributes

static uint8_t _num_clients = 0
 
static AP_AccelCal_Client_clients [AP_ACCELCAL_MAX_NUM_CLIENTS] {}
 

Detailed Description

Definition at line 10 of file AP_AccelCal.h.

Constructor & Destructor Documentation

◆ AP_AccelCal()

AP_AccelCal::AP_AccelCal ( )
inline

Definition at line 12 of file AP_AccelCal.h.

Here is the call graph for this function:

Member Function Documentation

◆ _printf()

void AP_AccelCal::_printf ( const char *  fmt,
  ... 
)
private

Definition at line 379 of file AP_AccelCal.cpp.

Referenced by cancel(), collect_sample(), fail(), success(), and update().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ cancel()

void AP_AccelCal::cancel ( )

Definition at line 217 of file AP_AccelCal.cpp.

Referenced by AP_InertialSensor::acal_update(), and AP_AccelCal().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ check_for_timeout()

bool AP_AccelCal::check_for_timeout ( )
private

◆ clear()

void AP_AccelCal::clear ( )
private

Definition at line 243 of file AP_AccelCal.cpp.

Referenced by cancel(), fail(), and success().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ client_active()

bool AP_AccelCal::client_active ( uint8_t  client_num)
private

Definition at line 351 of file AP_AccelCal.cpp.

Referenced by collect_sample(), and update().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ collect_sample()

void AP_AccelCal::collect_sample ( )
private

Definition at line 261 of file AP_AccelCal.cpp.

Referenced by update().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ fail()

void AP_AccelCal::fail ( )
private

Definition at line 230 of file AP_AccelCal.cpp.

Referenced by update().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ gcs_vehicle_position()

bool AP_AccelCal::gcs_vehicle_position ( float  position)

Definition at line 367 of file AP_AccelCal.cpp.

Referenced by get_status().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_calibrator()

AccelCalibrator * AP_AccelCal::get_calibrator ( uint8_t  i)
private

Definition at line 297 of file AP_AccelCal.cpp.

Referenced by clear(), collect_sample(), start(), update(), and update_status().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_status()

accel_cal_status_t AP_AccelCal::get_status ( )
inline

Definition at line 28 of file AP_AccelCal.h.

Referenced by AP_InertialSensor::acal_update().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ handleMessage()

void AP_AccelCal::handleMessage ( const mavlink_message_t *  msg)

Definition at line 356 of file AP_AccelCal.cpp.

Referenced by get_status(), and GCS_MAVLINK::handle_command_ack().

Here is the caller graph for this function:

◆ register_client()

void AP_AccelCal::register_client ( AP_AccelCal_Client client)
static

Definition at line 282 of file AP_AccelCal.cpp.

Referenced by AP_InertialSensor::AP_InertialSensor(), and get_status().

Here is the caller graph for this function:

◆ start()

void AP_AccelCal::start ( GCS_MAVLINK gcs)

Definition at line 177 of file AP_AccelCal.cpp.

Referenced by GCS_MAVLINK::_handle_command_preflight_calibration(), and AP_AccelCal().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ success()

void AP_AccelCal::success ( )
private

Definition at line 204 of file AP_AccelCal.cpp.

Referenced by update().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ update()

void AP_AccelCal::update ( )

Definition at line 28 of file AP_AccelCal.cpp.

Referenced by AP_InertialSensor::acal_update(), and AP_AccelCal().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ update_status()

void AP_AccelCal::update_status ( )
private

Definition at line 310 of file AP_AccelCal.cpp.

Referenced by AP_AccelCal(), clear(), collect_sample(), start(), and update().

Here is the call graph for this function:
Here is the caller graph for this function:

Member Data Documentation

◆ _clients

AP_AccelCal_Client * AP_AccelCal::_clients {}
staticprivate

◆ _gcs

GCS_MAVLINK* AP_AccelCal::_gcs
private

Definition at line 39 of file AP_AccelCal.h.

Referenced by _printf(), start(), and update().

◆ _last_position_request_ms

uint32_t AP_AccelCal::_last_position_request_ms
private

Definition at line 42 of file AP_AccelCal.h.

Referenced by start(), and update().

◆ _last_result

accel_cal_status_t AP_AccelCal::_last_result
private

Definition at line 45 of file AP_AccelCal.h.

Referenced by cancel(), fail(), start(), success(), and update().

◆ _num_active_calibrators

uint8_t AP_AccelCal::_num_active_calibrators
private

Definition at line 74 of file AP_AccelCal.h.

Referenced by start(), and update().

◆ _num_clients

uint8_t AP_AccelCal::_num_clients = 0
staticprivate

◆ _saving

bool AP_AccelCal::_saving
private

Definition at line 72 of file AP_AccelCal.h.

Referenced by clear(), start(), and update().

◆ _started

bool AP_AccelCal::_started
private

Definition at line 71 of file AP_AccelCal.h.

Referenced by clear(), start(), and update().

◆ _status

accel_cal_status_t AP_AccelCal::_status
private

Definition at line 44 of file AP_AccelCal.h.

Referenced by collect_sample(), gcs_vehicle_position(), get_status(), update(), and update_status().

◆ _step

uint8_t AP_AccelCal::_step
private

Definition at line 43 of file AP_AccelCal.h.

Referenced by clear(), gcs_vehicle_position(), start(), and update().

◆ _use_gcs_snoop

bool AP_AccelCal::_use_gcs_snoop
private

Definition at line 40 of file AP_AccelCal.h.

Referenced by gcs_vehicle_position(), start(), and update().

◆ _waiting_for_mavlink_ack

bool AP_AccelCal::_waiting_for_mavlink_ack = false
private

Definition at line 41 of file AP_AccelCal.h.

Referenced by handleMessage(), and update().


The documentation for this class was generated from the following files: