Encapsulation of the raw CAN bus.
More...
#include <canbus.h>
Encapsulation of the raw CAN bus.
| CANBus::registerCyclicMessageForReceive |
( |
int |
canId, |
|
|
double |
minCycleTime, |
|
|
double |
maxCycleTime |
|
) |
| |
|
pure virtual |
Registers CAN ID of a cyclic message for receiving
- Parameters
-
| canId | CAN ID of the message. |
| minCycleTime | Minimal interval between messages in seconds. Set to 0 if not used. |
| maxCycleTime | Maximum interval between messages for timeout detection in seconds. Set to 0 if no timeout detection is necessary. |
- Returns
- True if registration succeeds.
Implemented in CANBusImpl.
| CANBus::registerMessageForReceive |
( |
int |
canId | ) |
|
|
inlinevirtual |
Registers CAN ID of a message for receiving with no timeout. Perfect for sporadic messages.
- Parameters
-
| canId | CAN ID of the message. |
- Returns
- True if registration succeeds.
| CANBus::sendExtendedFrame |
( |
const can_frame & |
frame | ) |
|
|
pure virtual |
Sends extended(29bit) CAN frame over the bus
- Parameters
-
| frame | CAN frame to be sent |
- Returns
- True if frame was sent
Implemented in CANBusImpl.
| CANBus::sendStandardFrame |
( |
const can_frame & |
frame | ) |
|
|
pure virtual |
Sends standard(11bit) CAN frame over the bus
- Parameters
-
| frame | CAN frame to be sent |
- Returns
- True if frame was sent
Implemented in CANBusImpl.
| CANBus::start |
( |
const char * |
name | ) |
|
|
pure virtual |
Starts the CAN bus instance on the specified interface
- Parameters
-
| name | Name of the CAN bus network interface |
- Returns
- True if no error occurs.
Implemented in CANBusImpl.
Stops the CAN bus instance
Implemented in CANBusImpl.
| CANBus::unregisterMessageForReceive |
( |
int |
canId | ) |
|
|
pure virtual |
Un-registers CAN ID of a message used of receiving. Valid for cyclic and sporadic messages.
- Parameters
-
| canId | CAN ID of the message. |
- Returns
- True if de-registration succeeds.
Implemented in CANBusImpl.
The documentation for this class was generated from the following file:
- /home/abuild/rpmbuild/BUILD/automotive-message-broker-0.15/plugins/common/canbus.h