#include <SocketCan.h>
Definition at line 29 of file SocketCan.h.
 
      
        
          | SocketCan::SocketCan | ( | const char * | device, | 
        
          |  |  | int | baudrate | 
        
          |  | ) |  |  | 
      
 
 
      
        
          | SocketCan::SocketCan | ( | const char * | device | ) |  | 
      
 
 
      
        
          | SocketCan::~SocketCan | ( |  | ) |  | 
      
 
 
  
  | 
        
          | bool SocketCan::init_ret | ( |  | ) |  |  | virtual | 
 
Initializes the CAN bus and returns success. 
Implements CanItf.
Definition at line 54 of file SocketCan.cpp.
 
 
  
  | 
        
          | bool SocketCan::isObjectMode | ( |  | ) |  |  | inlinevirtual | 
 
Check if the current CAN interface was opened on OBJECT mode. 
- Returns
- true if opened in OBJECT mode, false if not. 
Implements CanItf.
Definition at line 42 of file SocketCan.h.
 
 
  
  | 
        
          | void SocketCan::print_error | ( | const can::State & | state | ) |  |  | private | 
 
 
  
  | 
        
          | bool SocketCan::receiveMsg | ( | CanMsg * | pCMsg | ) |  |  | virtual | 
 
Reads a CAN message. 
- Returns
- true if a message is available 
Implements CanItf.
Definition at line 96 of file SocketCan.cpp.
 
 
  
  | 
        
          | bool SocketCan::receiveMsgRetry | ( | CanMsg * | pCMsg, |  
          |  |  | int | iNrOfRetry |  
          |  | ) |  |  |  | virtual | 
 
Reads a CAN message. The function blocks between the attempts. 
- Parameters
- 
  
    | pCMsg | CAN message |  | iNrOfRetry | number of retries |  
 
- Returns
- true if a message is available 
Implements CanItf.
Definition at line 118 of file SocketCan.cpp.
 
 
  
  | 
        
          | bool SocketCan::receiveMsgTimeout | ( | CanMsg * | pCMsg, |  
          |  |  | int | nMicroSecTimeout |  
          |  | ) |  |  |  | virtual | 
 
Reads a CAN message with timeout. 
- Parameters
- 
  
    | pCMsg | CAN message |  | nMicroSecTimeout | timeout in us |  
 
- Returns
- true if a message is available 
Implements CanItf.
Definition at line 147 of file SocketCan.cpp.
 
 
  
  | 
        
          | bool SocketCan::transmitMsg | ( | CanMsg | CMsg, |  
          |  |  | bool | bBlocking = true |  
          |  | ) |  |  |  | virtual | 
 
Sends a CAN message. 
- Parameters
- 
  
    | pCMsg | CAN message |  | bBlocking | specifies whether send should be blocking or non-blocking |  
 
Implements CanItf.
Definition at line 84 of file SocketCan.cpp.
 
 
  
  | 
        
          | bool SocketCan::m_bInitialized |  | private | 
 
 
  
  | 
        
          | const char* SocketCan::p_cDevice |  | private | 
 
 
The documentation for this class was generated from the following files: