DUNE: Uniform Navigational Environment  2017.01.0
Sensors::DMS::DriverDMS Class Reference

Detailed Description

Message Parser for DMS.

Author
Pedro Gonçalves

Classes

struct  DMSState
 

Public Types

enum  DMSParserStates { PS_PREAMBLE, PS_DATA, PS_CS }
 

Public Member Functions

 DriverDMS (void)
 
 ~DriverDMS (void)
 
bool parse (uint8_t byte)
 
bool translate (void)
 
std::string translate_feadback (void)
 
char * enable_output (void)
 
char * disable_output (void)
 
char * set_sample_ps (int value)
 

Public Attributes

DMSState m_dms
 

Member Enumeration Documentation

State machine.

Enumerator
PS_PREAMBLE 

Read preamble.

PS_DATA 

Data received.

PS_CS 

Read checksum.

Constructor & Destructor Documentation

Sensors::DMS::DriverDMS::DriverDMS ( void  )
inline
Sensors::DMS::DriverDMS::~DriverDMS ( void  )
inline

Member Function Documentation

char* Sensors::DMS::DriverDMS::disable_output ( void  )
inline
char* Sensors::DMS::DriverDMS::enable_output ( void  )
inline

Enable Output data of DMS.

Referenced by Sensors::DMS::Task::configDMS().

bool Sensors::DMS::DriverDMS::parse ( uint8_t  byte)
inline

Parse message received.

References PS_CS, PS_DATA, and PS_PREAMBLE.

Referenced by Sensors::DMS::Task::checkSerialPort().

char* Sensors::DMS::DriverDMS::set_sample_ps ( int  value)
inline

Set number of channels/second.

Referenced by Sensors::DMS::Task::configDMS().

bool Sensors::DMS::DriverDMS::translate ( void  )
inline
std::string Sensors::DMS::DriverDMS::translate_feadback ( void  )
inline

Member Data Documentation

DMSState Sensors::DMS::DriverDMS::m_dms
Collaboration diagram for Sensors::DMS::DriverDMS:
Collaboration graph