@@ -126,7 +126,7 @@ static void volkswagen_mqb_init(int16_t param) {
126
126
UNUSED (param );
127
127
128
128
controls_allowed = false;
129
- relay_malfunction = false ;
129
+ relay_malfunction_reset () ;
130
130
volkswagen_torque_msg = MSG_HCA_01 ;
131
131
volkswagen_lane_msg = MSG_LDW_02 ;
132
132
gen_crc_lookup_table (0x2F , volkswagen_crc8_lut_8h2f );
@@ -136,7 +136,7 @@ static void volkswagen_pq_init(int16_t param) {
136
136
UNUSED (param );
137
137
138
138
controls_allowed = false;
139
- relay_malfunction = false ;
139
+ relay_malfunction_reset () ;
140
140
volkswagen_torque_msg = MSG_HCA_1 ;
141
141
volkswagen_lane_msg = MSG_LDW_1 ;
142
142
}
@@ -201,7 +201,7 @@ static int volkswagen_mqb_rx_hook(CAN_FIFOMailBox_TypeDef *to_push) {
201
201
202
202
// If there are HCA messages on bus 0 not sent by OP, there's a relay problem
203
203
if ((safety_mode_cnt > RELAY_TRNS_TIMEOUT ) && (addr == MSG_HCA_01 )) {
204
- relay_malfunction = true ;
204
+ relay_malfunction_set () ;
205
205
}
206
206
}
207
207
return valid ;
@@ -268,7 +268,7 @@ static int volkswagen_pq_rx_hook(CAN_FIFOMailBox_TypeDef *to_push) {
268
268
269
269
// If there are HCA messages on bus 0 not sent by OP, there's a relay problem
270
270
if ((safety_mode_cnt > RELAY_TRNS_TIMEOUT ) && (bus == 0 ) && (addr == MSG_HCA_1 )) {
271
- relay_malfunction = true ;
271
+ relay_malfunction_set () ;
272
272
}
273
273
}
274
274
return valid ;
0 commit comments