Skip to content

Commit

Permalink
better
Browse files Browse the repository at this point in the history
  • Loading branch information
royjr committed Dec 6, 2024
1 parent 14af4e9 commit 5e5d08e
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions board/safety/safety_hyundai_canfd.h
Original file line number Diff line number Diff line change
Expand Up @@ -215,9 +215,9 @@ static int hyundai_canfd_fwd_hook(int bus_num, int addr) {
// CRUISE_INFO for non-HDA2, we send our own longitudinal commands
bool is_scc_msg = ((addr == 0x1a0) && hyundai_longitudinal && !hyundai_canfd_hda2);

bool is_block_fault = (addr == 0x162);
bool is_ccnc_msg = (addr == 0x161) || (addr == 0x162);

bool block_msg = is_lkas_msg || is_lfa_msg || is_lfahda_msg || is_scc_msg || is_block_fault;
bool block_msg = is_lkas_msg || is_lfa_msg || is_lfahda_msg || is_scc_msg || is_ccnc_msg;
if (!block_msg) {
bus_fwd = 0;
}
Expand Down Expand Up @@ -263,7 +263,8 @@ static safety_config hyundai_canfd_init(uint16_t param) {
{0x1A0, 0, 32}, // CRUISE_INFO
{0x1CF, 2, 8}, // CRUISE_BUTTON
{0x1E0, 0, 16}, // LFAHDA_CLUSTER
{0x162, 0, 32}, // BLOCK_FAULTS
{0x161, 0, 32}, // MSG_161
{0x162, 0, 32}, // MSG_162
};


Expand Down

0 comments on commit 5e5d08e

Please sign in to comment.