Skip to content

Commit

Permalink
clean up
Browse files Browse the repository at this point in the history
  • Loading branch information
sshane committed Oct 25, 2023
1 parent df38717 commit f41c9e9
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 5 deletions.
12 changes: 12 additions & 0 deletions chrysler_ram_hd_generated.dbc
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,18 @@ BO_ 570 CRUISE_BUTTONS: 3 XXX
SG_ COUNTER : 15|4@0+ (1,0) [0|15] "" XXX
SG_ CHECKSUM : 23|8@0+ (1,0) [0|255] "" XXX

BO_ 571 CRUISE_BUTTONS_ALT: 3 XXX
SG_ ACC_Cancel : 0|1@1+ (1,0) [0|0] "" XXX
SG_ ACC_Distance_Dec : 1|1@1+ (1,0) [0|0] "" XXX
SG_ ACC_Accel : 2|1@1+ (1,0) [0|0] "" XXX
SG_ ACC_Decel : 3|1@1+ (1,0) [0|0] "" XXX
SG_ ACC_Resume : 4|1@0+ (1,0) [0|1] "" XXX
SG_ Cruise_OnOff : 6|1@1+ (1,0) [0|0] "" XXX
SG_ ACC_OnOff : 7|1@1+ (1,0) [0|0] "" XXX
SG_ ACC_Distance_Inc : 8|1@1+ (1,0) [0|0] "" XXX
SG_ COUNTER : 15|4@0+ (1,0) [0|15] "" XXX
SG_ CHECKSUM : 23|8@0+ (1,0) [0|255] "" XXX

BO_ 629 DAS_6: 8 XXX
SG_ LKAS_ICON_COLOR : 1|2@0+ (1,0) [0|3] "" XXX
SG_ LKAS_LANE_LINES : 19|4@0+ (1,0) [0|1] "" XXX
Expand Down
7 changes: 2 additions & 5 deletions generator/chrysler/_stellantis_common_ram.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/usr/bin/env python3
import os

chrysler_to_ram: dict[str, dict[int, int | tuple[int] | tuple[int, int]]] = {
chrysler_to_ram: dict[str, dict[int, int | tuple[int, int]]] = {
"_stellantis_common_ram_dt_generated.dbc": {
258: 35,
264: 37,
Expand Down Expand Up @@ -39,9 +39,6 @@
cur_msg = []
for line in in_f.readlines():
cur_msg.append(line)

# if line.startswith(('BO_', 'VAL_')):
# cur_msg.append(line)
if line.strip() == '':
if not len(cur_msg):
continue
Expand All @@ -53,7 +50,7 @@
sl = cur_msg[0].split(' ')
addr = int(sl[1])

new_addrs = addr_lookup.get(addr, addr)
new_addrs = addr_lookup.get(addr, (addr,))
if not isinstance(new_addrs, tuple):
new_addrs = (new_addrs,)

Expand Down

0 comments on commit f41c9e9

Please sign in to comment.