Skip to content

Commit

Permalink
Use HAL macro
Browse files Browse the repository at this point in the history
  • Loading branch information
LandryNorris committed Sep 19, 2024
1 parent 273bc50 commit 8d0f4f6
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
2 changes: 0 additions & 2 deletions src/main/native/include/rev/CANMessage.h
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,6 @@
#include <iostream>
#include <chrono>

#define EXTENDED_ID_MASK 0x40000000
#define REMOTE_FRAME_MASK 0x80000000
#define NON_RESERVED_ARB_ID_MASK 0x1FFFFFFF

namespace rev {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ class CandleWinUSBDeviceThread :public DriverDeviceThread {
uint32_t messageId = el.m_msg.GetMessageId() & NON_RESERVED_ARB_ID_MASK;

bool isExtended = true; // FRC CAN is always extended
bool isRtr = messageId & REMOTE_FRAME_MASK;
bool isRtr = messageId & HAL_CAN_IS_FRAME_REMOTE;

frame.can_id = messageId;
if(isExtended) {
Expand Down

0 comments on commit 8d0f4f6

Please sign in to comment.