Rev 24 | Only display areas with differences | Regard whitespace | Details | Blame | Last modification | View Log | SVN | RSS feed
| Rev 24 | Rev 25 | ||
|---|---|---|---|
| - | 1 | /********************************************************************* |
|
| - | 2 | * |
|
| - | 3 | * CAN.c header file |
|
| - | 4 | * |
|
| - | 5 | ********************************************************************* |
|
| - | 6 | * FileName: CAN.h |
|
| - | 7 | * |
|
| - | 8 | * Author Date Comment |
|
| - | 9 | *~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|
| - | 10 | * Johan Böhlin 21-10-06 Original (Rev 1.0) |
|
| - | 11 | ********************************************************************/ |
|
| - | 12 | ||
| 1 | #ifndef CAN_H |
13 | #ifndef CAN_H |
| 2 | #define CAN_H |
14 | #define CAN_H |
| 3 | 15 | ||
| 4 | #include "../Include/CANdefs.h" |
16 | #include "../Include/CANdefs.h" |
| 5 | #include "../Include/compiler.h" |
17 | #include "../Include/compiler.h" |
| 6 | #include "../Include/typedefs.h" |
18 | #include "../Include/typedefs.h" |
| 7 | 19 | ||
| 8 | 20 | ||
| 9 | typedef struct _CAN_MESSAGE |
21 | typedef struct _CAN_MESSAGE |
| 10 | { |
22 | { |
| 11 | 23 | ||
| 12 | DWORD ident; |
24 | DWORD ident; |
| 13 | BOOL extended; |
25 | BOOL extended; |
| 14 | BYTE data_length; |
26 | BYTE data_length; |
| 15 | BYTE data[8]; |
27 | BYTE data[8]; |
| 16 | } CAN_MESSAGE; |
28 | } CAN_MESSAGE; |
| 17 | 29 | ||
| 18 | 30 | ||
| 19 | 31 | ||
| 20 | 32 | ||
| 21 | void canInit(void); |
33 | void canInit(void); |
| 22 | void canISR(void); |
34 | void canISR(void); |
| 23 | void canParse(CAN_MESSAGE cm); |
35 | void canParse(CAN_MESSAGE cm); |
| 24 | BOOL canSendMessage(CAN_MESSAGE cm); |
36 | BOOL canSendMessage(CAN_MESSAGE cm); |
| 25 | 37 | ||
| 26 | #endif //CAN.h |
38 | #endif //CAN.h |
| 27 | 39 | ||