aboutsummaryrefslogtreecommitdiffstats
path: root/fw/can.h
diff options
context:
space:
mode:
authorSam Anthony <sam@samanthony.xyz>2025-10-24 09:42:49 -0400
committerSam Anthony <sam@samanthony.xyz>2025-10-24 09:42:49 -0400
commit32dafa1088e2f2428e9b67bf848faf2433216011 (patch)
treed1ee08ceb3e16d80784680fbc6ac2a2df3b580ab /fw/can.h
parent94cdc9ec4e75fc5e55deb394eda4820ba672e3e4 (diff)
downloadcan-gauge-interface-32dafa1088e2f2428e9b67bf848faf2433216011.zip
CAN echo systest
Diffstat (limited to 'fw/can.h')
-rw-r--r--fw/can.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/fw/can.h b/fw/can.h
index 8e0cfff..9ac1cfe 100644
--- a/fw/can.h
+++ b/fw/can.h
@@ -52,9 +52,9 @@ typedef struct {
// CAN frame
typedef struct {
CanId id;
+ bool rtr; // remote transmission request
U8 dlc; // data length code
U8 data[8];
- bool rtr; // remote transmission request
} CanFrame;
// Initialize the MCP2515.
@@ -75,11 +75,11 @@ void canIE(bool enable);
// Read RX status with RX STATUS instruction.
U8 canRxStatus(void);
-// Read the DATA field of RXB0.
-void canReadRxb0Data(U8 data[8u]);
+// Read the frame in RXB0.
+void canReadRxb0(CanFrame *frame);
-// Read the DATA field of RXB1.
-void canReadRxb1Data(U8 data[8u]);
+// Read the frame in RXB1.
+void canReadRxb1(CanFrame *frame);
// Transmit a frame to the CAN bus
Status canTx(const CanFrame *frame);