Lely core libraries  1.9.2
can.h
Go to the documentation of this file.
1 
21 #ifndef LELY_CAN_CAN_H_
22 #define LELY_CAN_CAN_H_
23 
24 #include <lely/features.h>
25 
27 enum can_state {
34 };
35 
37 enum can_error {
39  CAN_ERROR_BIT = 1u << 0,
41  CAN_ERROR_STUFF = 1u << 1,
43  CAN_ERROR_CRC = 1u << 2,
45  CAN_ERROR_FORM = 1u << 3,
47  CAN_ERROR_ACK = 1u << 4,
49  CAN_ERROR_OTHER = 1 << 5
50 };
51 
52 #endif // !LELY_CAN_CAN_H_
A bit stuffing error.
Definition: can.h:41
A form error.
Definition: can.h:45
can_state
The states of a CAN node, depending on the TX/RX error count.
Definition: can.h:27
The error passive state (TX/RX error count < 256).
Definition: can.h:31
The bus off state (TX/RX error count >= 256).
Definition: can.h:33
The error active state (TX/RX error count < 128).
Definition: can.h:29
An acknowledgment error.
Definition: can.h:47
One or more other errors.
Definition: can.h:49
A CRC sequence error.
Definition: can.h:43
This header file is part of the Lely libraries; it contains the compiler feature definitions.
A single bit error.
Definition: can.h:39
can_error
The error flags of a CAN bus, which are not mutually exclusive.
Definition: can.h:37