Public Member Functions | Private Member Functions | Private Attributes | List of all members
canopen::CANLayer Class Reference

#include <can_layer.h>

Inheritance diagram for canopen::CANLayer:
Inheritance graph
[legend]

Public Member Functions

 CANLayer (const can::DriverInterfaceSharedPtr &driver, const std::string &device, bool loopback, can::SettingsConstSharedPtr settings)
 
 CANLayer (const can::DriverInterfaceSharedPtr &driver, const std::string &device, bool loopback)
 
virtual void handleDiag (LayerReport &report)
 
virtual void handleHalt (LayerStatus &status)
 
virtual void handleInit (LayerStatus &status)
 
virtual void handleRead (LayerStatus &status, const LayerState &current_state)
 
virtual void handleRecover (LayerStatus &status)
 
virtual void handleShutdown (LayerStatus &status)
 
virtual void handleWrite (LayerStatus &status, const LayerState &current_state)
 
- Public Member Functions inherited from canopen::Layer
void diag (LayerReport &report)
 
LayerState getLayerState ()
 
void halt (LayerStatus &status)
 
void init (LayerStatus &status)
 
 Layer (const std::string &n)
 
void read (LayerStatus &status)
 
void recover (LayerStatus &status)
 
void shutdown (LayerStatus &status)
 
void write (LayerStatus &status)
 
virtual ~Layer ()
 

Private Member Functions

void handleFrame (const can::Frame &msg)
 

Private Attributes

const std::string device_
 
can::DriverInterfaceSharedPtr driver_
 
can::FrameListenerConstSharedPtr error_listener_
 
can::Frame last_error_
 
const bool loopback_
 
boost::mutex mutex_
 
can::SettingsConstSharedPtr settings_
 
std::shared_ptr< boost::thread > thread_
 

Additional Inherited Members

- Public Types inherited from canopen::Layer
enum  LayerState {
  Off, Init, Shutdown, Error,
  Halt, Recover, Ready
}
 
- Public Attributes inherited from canopen::Layer
const std::string name
 

Detailed Description

Definition at line 10 of file can_layer.h.

Constructor & Destructor Documentation

◆ CANLayer() [1/2]

canopen::CANLayer::CANLayer ( const can::DriverInterfaceSharedPtr driver,
const std::string &  device,
bool  loopback,
can::SettingsConstSharedPtr  settings 
)
inline

Definition at line 26 of file can_layer.h.

◆ CANLayer() [2/2]

canopen::CANLayer::CANLayer ( const can::DriverInterfaceSharedPtr driver,
const std::string &  device,
bool  loopback 
)
inline

Definition at line 29 of file can_layer.h.

Member Function Documentation

◆ handleDiag()

virtual void canopen::CANLayer::handleDiag ( LayerReport report)
inlinevirtual

Implements canopen::Layer.

Definition at line 43 of file can_layer.h.

◆ handleFrame()

void canopen::CANLayer::handleFrame ( const can::Frame msg)
inlineprivate

Definition at line 18 of file can_layer.h.

◆ handleHalt()

virtual void canopen::CANLayer::handleHalt ( LayerStatus status)
inlinevirtual

Implements canopen::Layer.

Definition at line 103 of file can_layer.h.

◆ handleInit()

virtual void canopen::CANLayer::handleInit ( LayerStatus status)
inlinevirtual

Implements canopen::Layer.

Definition at line 70 of file can_layer.h.

◆ handleRead()

virtual void canopen::CANLayer::handleRead ( LayerStatus status,
const LayerState current_state 
)
inlinevirtual

Implements canopen::Layer.

Definition at line 32 of file can_layer.h.

◆ handleRecover()

virtual void canopen::CANLayer::handleRecover ( LayerStatus status)
inlinevirtual

Implements canopen::Layer.

Definition at line 105 of file can_layer.h.

◆ handleShutdown()

virtual void canopen::CANLayer::handleShutdown ( LayerStatus status)
inlinevirtual

Implements canopen::Layer.

Definition at line 89 of file can_layer.h.

◆ handleWrite()

virtual void canopen::CANLayer::handleWrite ( LayerStatus status,
const LayerState current_state 
)
inlinevirtual

Implements canopen::Layer.

Definition at line 37 of file can_layer.h.

Member Data Documentation

◆ device_

const std::string canopen::CANLayer::device_
private

Definition at line 13 of file can_layer.h.

◆ driver_

can::DriverInterfaceSharedPtr canopen::CANLayer::driver_
private

Definition at line 12 of file can_layer.h.

◆ error_listener_

can::FrameListenerConstSharedPtr canopen::CANLayer::error_listener_
private

Definition at line 17 of file can_layer.h.

◆ last_error_

can::Frame canopen::CANLayer::last_error_
private

Definition at line 16 of file can_layer.h.

◆ loopback_

const bool canopen::CANLayer::loopback_
private

Definition at line 14 of file can_layer.h.

◆ mutex_

boost::mutex canopen::CANLayer::mutex_
private

Definition at line 11 of file can_layer.h.

◆ settings_

can::SettingsConstSharedPtr canopen::CANLayer::settings_
private

Definition at line 15 of file can_layer.h.

◆ thread_

std::shared_ptr<boost::thread> canopen::CANLayer::thread_
private

Definition at line 23 of file can_layer.h.


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


canopen_master
Author(s): Mathias L├╝dtke
autogenerated on Tue May 4 2021 02:50:21