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

#include <AP_RangeFinder_uLanding.h>

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

Public Member Functions

 AP_RangeFinder_uLanding (RangeFinder::RangeFinder_State &_state, AP_SerialManager &serial_manager, uint8_t serial_instance)
 
void update (void)
 
- Public Member Functions inherited from AP_RangeFinder_Backend
 AP_RangeFinder_Backend (RangeFinder::RangeFinder_State &_state)
 
virtual ~AP_RangeFinder_Backend (void)
 
virtual void handle_msg (mavlink_message_t *msg)
 
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 (AP_SerialManager &serial_manager, uint8_t serial_instance)
 

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)
 

Private Member Functions

bool detect_version (void)
 
bool get_reading (uint16_t &reading_cm)
 

Private Attributes

AP_HAL::UARTDriveruart
 
uint8_t _linebuf [6]
 
uint8_t _linebuf_len
 
uint32_t _last_reading_ms
 
bool _version_known
 
uint8_t _header
 
uint8_t _version
 

Additional Inherited Members

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

Detailed Description

Definition at line 6 of file AP_RangeFinder_uLanding.h.

Constructor & Destructor Documentation

◆ AP_RangeFinder_uLanding()

AP_RangeFinder_uLanding::AP_RangeFinder_uLanding ( RangeFinder::RangeFinder_State _state,
AP_SerialManager serial_manager,
uint8_t  serial_instance 
)

Definition at line 35 of file AP_RangeFinder_uLanding.cpp.

Here is the call graph for this function:

Member Function Documentation

◆ _get_mav_distance_sensor_type()

MAV_DISTANCE_SENSOR AP_RangeFinder_uLanding::_get_mav_distance_sensor_type ( ) const
inlineoverrideprotectedvirtual

Implements AP_RangeFinder_Backend.

Definition at line 23 of file AP_RangeFinder_uLanding.h.

Here is the call graph for this function:

◆ detect()

bool AP_RangeFinder_uLanding::detect ( AP_SerialManager serial_manager,
uint8_t  serial_instance 
)
static

Definition at line 51 of file AP_RangeFinder_uLanding.cpp.

Referenced by RangeFinder::detect_instance().

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

◆ detect_version()

bool AP_RangeFinder_uLanding::detect_version ( void  )
private

Definition at line 59 of file AP_RangeFinder_uLanding.cpp.

Referenced by _get_mav_distance_sensor_type(), and get_reading().

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

◆ get_reading()

bool AP_RangeFinder_uLanding::get_reading ( uint16_t &  reading_cm)
private

Definition at line 138 of file AP_RangeFinder_uLanding.cpp.

Referenced by _get_mav_distance_sensor_type(), and update().

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

◆ update()

void AP_RangeFinder_uLanding::update ( void  )
virtual

Implements AP_RangeFinder_Backend.

Definition at line 211 of file AP_RangeFinder_uLanding.cpp.

Here is the call graph for this function:

Member Data Documentation

◆ _header

uint8_t AP_RangeFinder_uLanding::_header
private

Definition at line 39 of file AP_RangeFinder_uLanding.h.

Referenced by detect_version(), and get_reading().

◆ _last_reading_ms

uint32_t AP_RangeFinder_uLanding::_last_reading_ms
private

Definition at line 37 of file AP_RangeFinder_uLanding.h.

Referenced by update().

◆ _linebuf

uint8_t AP_RangeFinder_uLanding::_linebuf[6]
private

Definition at line 35 of file AP_RangeFinder_uLanding.h.

Referenced by get_reading().

◆ _linebuf_len

uint8_t AP_RangeFinder_uLanding::_linebuf_len
private

Definition at line 36 of file AP_RangeFinder_uLanding.h.

Referenced by get_reading().

◆ _version

uint8_t AP_RangeFinder_uLanding::_version
private

Definition at line 40 of file AP_RangeFinder_uLanding.h.

Referenced by detect_version(), and get_reading().

◆ _version_known

bool AP_RangeFinder_uLanding::_version_known
private

Definition at line 38 of file AP_RangeFinder_uLanding.h.

Referenced by detect_version().

◆ uart

AP_HAL::UARTDriver* AP_RangeFinder_uLanding::uart
private

Definition at line 34 of file AP_RangeFinder_uLanding.h.

Referenced by AP_RangeFinder_uLanding(), detect_version(), and get_reading().


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