Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 76b0b0e

Browse files
committedMar 15, 2025
no struct
1 parent c61900c commit 76b0b0e

File tree

4 files changed

+7
-10
lines changed

4 files changed

+7
-10
lines changed
 

‎opendbc/car/car.capnp

+3-6
Original file line numberDiff line numberDiff line change
@@ -300,14 +300,11 @@ struct CarState {
300300
# ******* radar state @ 20hz *******
301301

302302
struct RadarData @0x888ad6581cf0aacb {
303-
errors @3 :Error;
304303
points @1 :List(RadarPoint);
305304

306-
struct Error {
307-
canError @0 :Bool;
308-
fault @1 :Bool;
309-
wrongConfig @2 :Bool;
310-
}
305+
canError @3 :Bool;
306+
radarFault @4 :Bool;
307+
wrongConfig @5 :Bool;
311308

312309
# similar to LiveTracks
313310
# is one timestamp valid for all? I think so

‎opendbc/car/ford/radar_interface.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ def update(self, can_strings):
125125

126126
ret = structs.RadarData()
127127
if not self.rcp.can_valid:
128-
ret.errors.canError = True
128+
ret.canError = True
129129

130130
if self.radar == RADAR.DELPHI_ESR:
131131
self._update_delphi_esr()
@@ -180,7 +180,7 @@ def _update_delphi_mrr(self, ret: structs.RadarData):
180180

181181
# Rarely MRR_Header_InformationDetections can fail to send a message. The scan index is skipped in this case
182182
if self.invalid_cnt >= 5:
183-
ret.errors.wrongConfig = True
183+
ret.wrongConfig = True
184184

185185
for ii in range(1, DELPHI_MRR_RADAR_MSG_COUNT + 1):
186186
msg = self.rcp.vl[f"MRR_Detection_{ii:03d}"]

‎opendbc/car/gm/radar_interface.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ def update(self, can_strings):
5959
if not self.rcp.can_valid:
6060
ret.errors.canError = True
6161
if fault:
62-
ret.errors.fault = True
62+
ret.errors.radarFault = True
6363

6464
currentTargets = set()
6565
num_targets = header['FLRRNumValidTargets']

‎opendbc/car/honda/radar_interface.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ def _update(self, updated_messages):
7070
if not self.rcp.can_valid:
7171
ret.errors.canError = True
7272
if self.radar_fault:
73-
ret.errors.fault = True
73+
ret.errors.radarFault = True
7474
if self.radar_wrong_config:
7575
ret.errors.wrongConfig = True
7676

0 commit comments

Comments
 (0)
Please sign in to comment.