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

#include <AP_RangeFinder_MAVLink.h>

Inheritance diagram for AP_RangeFinder_MAVLink:
[legend]
Collaboration diagram for AP_RangeFinder_MAVLink:
[legend]

Public Member Functions

 AP_RangeFinder_MAVLink (RangeFinder::RangeFinder_State &_state)
 
void update (void)
 
void handle_msg (mavlink_message_t *msg)
 
- Public Member Functions inherited from AP_RangeFinder_Backend
 AP_RangeFinder_Backend (RangeFinder::RangeFinder_State &_state)
 
virtual ~AP_RangeFinder_Backend (void)
 
void update_pre_arm_check ()
 
enum Rotation orientation () const
 
uint16_t distance_cm () const
 
uint16_t voltage_mv () const
 
int16_t max_distance_cm () const
 
int16_t min_distance_cm () const
 
int16_t ground_clearance_cm () const
 
MAV_DISTANCE_SENSOR get_mav_distance_sensor_type () const
 
RangeFinder::RangeFinder_Status status () const
 
RangeFinder::RangeFinder_Type type () const
 
bool has_data () const
 
uint8_t range_valid_count () const
 
const Vector3fget_pos_offset () const
 

Static Public Member Functions

static bool detect ()
 

Protected Member Functions

MAV_DISTANCE_SENSOR _get_mav_distance_sensor_type () const override
 
- Protected Member Functions inherited from AP_RangeFinder_Backend
void update_status ()
 
void set_status (RangeFinder::RangeFinder_Status status)
 

Static Private Member Functions

static bool start_reading (void)
 
static bool get_reading (uint16_t &reading_cm)
 

Private Attributes

uint16_t distance_cm
 
uint32_t last_update_ms
 
MAV_DISTANCE_SENSOR sensor_type = MAV_DISTANCE_SENSOR_UNKNOWN
 

Additional Inherited Members

- Protected Attributes inherited from AP_RangeFinder_Backend
RangeFinder::RangeFinder_Statestate
 
AP_HAL::Semaphore_sem
 

Detailed Description

Definition at line 9 of file AP_RangeFinder_MAVLink.h.

Constructor & Destructor Documentation

◆ AP_RangeFinder_MAVLink()

AP_RangeFinder_MAVLink::AP_RangeFinder_MAVLink ( RangeFinder::RangeFinder_State _state)

Definition at line 28 of file AP_RangeFinder_MAVLink.cpp.

Here is the call graph for this function:

Member Function Documentation

◆ _get_mav_distance_sensor_type()

MAV_DISTANCE_SENSOR AP_RangeFinder_MAVLink::_get_mav_distance_sensor_type ( ) const
inlineoverrideprotectedvirtual

Implements AP_RangeFinder_Backend.

Definition at line 27 of file AP_RangeFinder_MAVLink.h.

◆ detect()

bool AP_RangeFinder_MAVLink::detect ( )
static

Definition at line 39 of file AP_RangeFinder_MAVLink.cpp.

Referenced by RangeFinder::detect_instance().

Here is the caller graph for this function:

◆ get_reading()

static bool AP_RangeFinder_MAVLink::get_reading ( uint16_t &  reading_cm)
staticprivate

◆ handle_msg()

void AP_RangeFinder_MAVLink::handle_msg ( mavlink_message_t *  msg)
virtual

Reimplemented from AP_RangeFinder_Backend.

Definition at line 49 of file AP_RangeFinder_MAVLink.cpp.

Here is the call graph for this function:

◆ start_reading()

static bool AP_RangeFinder_MAVLink::start_reading ( void  )
staticprivate

◆ update()

void AP_RangeFinder_MAVLink::update ( void  )
virtual

Implements AP_RangeFinder_Backend.

Definition at line 65 of file AP_RangeFinder_MAVLink.cpp.

Here is the call graph for this function:

Member Data Documentation

◆ distance_cm

uint16_t AP_RangeFinder_MAVLink::distance_cm
private

Definition at line 32 of file AP_RangeFinder_MAVLink.h.

◆ last_update_ms

uint32_t AP_RangeFinder_MAVLink::last_update_ms
private

Definition at line 33 of file AP_RangeFinder_MAVLink.h.

Referenced by AP_RangeFinder_MAVLink(), handle_msg(), and update().

◆ sensor_type

MAV_DISTANCE_SENSOR AP_RangeFinder_MAVLink::sensor_type = MAV_DISTANCE_SENSOR_UNKNOWN
private

Definition at line 39 of file AP_RangeFinder_MAVLink.h.

Referenced by _get_mav_distance_sensor_type(), and handle_msg().


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