mirror of
https://github.com/dalathegreat/Battery-Emulator.git
synced 2025-10-05 10:49:42 +02:00
Prevent logging FD twice
This commit is contained in:
parent
9479697597
commit
aa3128fa29
1 changed files with 3 additions and 1 deletions
|
@ -297,7 +297,9 @@ void print_can_frame(CAN_frame frame, frameDirection msgDir) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void map_can_frame_to_variable(CAN_frame* rx_frame, int interface) {
|
void map_can_frame_to_variable(CAN_frame* rx_frame, int interface) {
|
||||||
|
if (interface != CANFD_NATIVE) { //Avoid printing twice in receive_frame_canfd_addon
|
||||||
print_can_frame(*rx_frame, frameDirection(MSG_RX));
|
print_can_frame(*rx_frame, frameDirection(MSG_RX));
|
||||||
|
}
|
||||||
|
|
||||||
#ifdef LOG_CAN_TO_SD
|
#ifdef LOG_CAN_TO_SD
|
||||||
add_can_frame_to_buffer(*rx_frame, frameDirection(MSG_RX));
|
add_can_frame_to_buffer(*rx_frame, frameDirection(MSG_RX));
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue