Modified mcp2518fd canbus checkreceive() return +2

This commit is contained in:
wangcoolc
2020-12-10 17:10:14 +08:00
committed by Baozhu Zuo
parent 7eda1c5315
commit 1e5d371fe2
+1 -1
View File
@@ -2776,7 +2776,7 @@ byte mcp2518fd::checkReceive(void)
// return ((res & MCP_STAT_RXIF_MASK) ? CAN_MSGAVAIL : CAN_NOMSG);
mcp2518fd_ReceiveChannelStatusGet(APP_RX_FIFO, &status);
byte res = (byte)(status & CAN_RX_FIFO_NOT_EMPTY_EVENT);
byte res = (byte)(status & CAN_RX_FIFO_NOT_EMPTY_EVENT) + 2;
return res;
}