APM:Libraries
Classes | Macros | Enumerations
AP_RangeFinder_LeddarOne.h File Reference
#include "RangeFinder.h"
#include "RangeFinder_Backend.h"
Include dependency graph for AP_RangeFinder_LeddarOne.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  AP_RangeFinder_LeddarOne
 

Macros

#define LEDDARONE_DEFAULT_ADDRESS   0x01
 
#define LEDDARONE_MODOBUS_FUNCTION_CODE   0x04
 
#define LEDDARONE_MODOBUS_FUNCTION_REGISTER_ADDRESS   20
 
#define LEDDARONE_MODOBUS_FUNCTION_READ_NUMBER   10
 
#define LEDDARONE_SERIAL_PORT_MAX   250
 
#define LEDDARONE_READ_BUFFER_SIZE   25
 
#define LEDDARONE_DETECTIONS_MAX   3
 
#define LEDDARONE_DETECTION_DATA_NUMBER_INDEX   10
 
#define LEDDARONE_DETECTION_DATA_INDEX_OFFSET   11
 
#define LEDDARONE_DETECTION_DATA_OFFSET   4
 

Enumerations

enum  LeddarOne_Status {
  LEDDARONE_STATE_OK = 0, LEDDARONE_STATE_READING_BUFFER = 1, LEDDARONE_STATE_ERR_BAD_CRC = -1, LEDDARONE_STATE_ERR_NO_RESPONSES = -2,
  LEDDARONE_STATE_ERR_BAD_RESPONSE = -3, LEDDARONE_STATE_ERR_SHORT_RESPONSE = -4, LEDDARONE_STATE_ERR_SERIAL_PORT = -5, LEDDARONE_STATE_ERR_NUMBER_DETECTIONS = -6
}
 
enum  LeddarOne_ModbusStatus { LEDDARONE_MODBUS_STATE_INIT = 0, LEDDARONE_MODBUS_STATE_PRE_SEND_REQUEST, LEDDARONE_MODBUS_STATE_SENT_REQUEST, LEDDARONE_MODBUS_STATE_AVAILABLE }
 

Macro Definition Documentation

◆ LEDDARONE_DEFAULT_ADDRESS

#define LEDDARONE_DEFAULT_ADDRESS   0x01

Definition at line 7 of file AP_RangeFinder_LeddarOne.h.

◆ LEDDARONE_DETECTION_DATA_INDEX_OFFSET

#define LEDDARONE_DETECTION_DATA_INDEX_OFFSET   11

Definition at line 17 of file AP_RangeFinder_LeddarOne.h.

Referenced by AP_RangeFinder_LeddarOne::parse_response().

◆ LEDDARONE_DETECTION_DATA_NUMBER_INDEX

#define LEDDARONE_DETECTION_DATA_NUMBER_INDEX   10

Definition at line 16 of file AP_RangeFinder_LeddarOne.h.

Referenced by AP_RangeFinder_LeddarOne::parse_response().

◆ LEDDARONE_DETECTION_DATA_OFFSET

#define LEDDARONE_DETECTION_DATA_OFFSET   4

Definition at line 18 of file AP_RangeFinder_LeddarOne.h.

Referenced by AP_RangeFinder_LeddarOne::parse_response().

◆ LEDDARONE_DETECTIONS_MAX

#define LEDDARONE_DETECTIONS_MAX   3

Definition at line 15 of file AP_RangeFinder_LeddarOne.h.

Referenced by AP_RangeFinder_LeddarOne::parse_response().

◆ LEDDARONE_MODOBUS_FUNCTION_CODE

#define LEDDARONE_MODOBUS_FUNCTION_CODE   0x04

Definition at line 8 of file AP_RangeFinder_LeddarOne.h.

Referenced by AP_RangeFinder_LeddarOne::parse_response().

◆ LEDDARONE_MODOBUS_FUNCTION_READ_NUMBER

#define LEDDARONE_MODOBUS_FUNCTION_READ_NUMBER   10

Definition at line 10 of file AP_RangeFinder_LeddarOne.h.

◆ LEDDARONE_MODOBUS_FUNCTION_REGISTER_ADDRESS

#define LEDDARONE_MODOBUS_FUNCTION_REGISTER_ADDRESS   20

Definition at line 9 of file AP_RangeFinder_LeddarOne.h.

◆ LEDDARONE_READ_BUFFER_SIZE

#define LEDDARONE_READ_BUFFER_SIZE   25

Definition at line 13 of file AP_RangeFinder_LeddarOne.h.

Referenced by AP_RangeFinder_LeddarOne::parse_response().

◆ LEDDARONE_SERIAL_PORT_MAX

#define LEDDARONE_SERIAL_PORT_MAX   250

Definition at line 12 of file AP_RangeFinder_LeddarOne.h.

Referenced by AP_RangeFinder_LeddarOne::get_reading().

Enumeration Type Documentation

◆ LeddarOne_ModbusStatus

Enumerator
LEDDARONE_MODBUS_STATE_INIT 
LEDDARONE_MODBUS_STATE_PRE_SEND_REQUEST 
LEDDARONE_MODBUS_STATE_SENT_REQUEST 
LEDDARONE_MODBUS_STATE_AVAILABLE 

Definition at line 33 of file AP_RangeFinder_LeddarOne.h.

◆ LeddarOne_Status

Enumerator
LEDDARONE_STATE_OK 
LEDDARONE_STATE_READING_BUFFER 
LEDDARONE_STATE_ERR_BAD_CRC 
LEDDARONE_STATE_ERR_NO_RESPONSES 
LEDDARONE_STATE_ERR_BAD_RESPONSE 
LEDDARONE_STATE_ERR_SHORT_RESPONSE 
LEDDARONE_STATE_ERR_SERIAL_PORT 
LEDDARONE_STATE_ERR_NUMBER_DETECTIONS 

Definition at line 21 of file AP_RangeFinder_LeddarOne.h.