From 3ca602becc001928aeceaef01d917aad600d9863 Mon Sep 17 00:00:00 2001 From: Shane Smiskol Date: Tue, 30 Jan 2024 00:12:06 -0800 Subject: [PATCH] Revert "preview: what multiple DIDs per ECU would look like in the future" This reverts commit 88f0d8611e638de644adc5feabade848c03d59e4. --- selfdrive/car/fw_query_definitions.py | 1 - selfdrive/car/gm/fingerprints.py | 14 ++------------ selfdrive/car/gm/values.py | 17 ++++------------- 3 files changed, 6 insertions(+), 26 deletions(-) diff --git a/selfdrive/car/fw_query_definitions.py b/selfdrive/car/fw_query_definitions.py index 0c4c3f21f9..fcd0845e14 100755 --- a/selfdrive/car/fw_query_definitions.py +++ b/selfdrive/car/fw_query_definitions.py @@ -65,7 +65,6 @@ class StdQueries: @dataclass class Request: - label: str request: List[bytes] response: List[bytes] whitelist_ecus: List[int] = field(default_factory=list) diff --git a/selfdrive/car/gm/fingerprints.py b/selfdrive/car/gm/fingerprints.py index d390932fba..e4c6f659e5 100644 --- a/selfdrive/car/gm/fingerprints.py +++ b/selfdrive/car/gm/fingerprints.py @@ -58,16 +58,6 @@ FINGERPRINTS = { }], } -FW_VERSIONS = { - CAR.BOLT_EUV: { - # Require all to exact or fuzzy function match - (Ecu.fwdCamera, 0x24b, None): { - 'SoftwareModule1': [ - b'\x02\x8c\xf0)' # 42790953 - ], - 'EndModelPartNumber': [ - b"\x02\x8c\xf0'", # 42790951 - ], - } - }, +FW_VERSIONS: dict[str, dict[tuple, list[bytes]]] = { + CAR.BOLT_EUV: {}, } diff --git a/selfdrive/car/gm/values.py b/selfdrive/car/gm/values.py index fbbaab176e..8188ad4e6e 100644 --- a/selfdrive/car/gm/values.py +++ b/selfdrive/car/gm/values.py @@ -169,24 +169,15 @@ GM_FW_REQUESTS = [ GM_RX_OFFSET = 0x400 FW_QUERY_CONFIG = FwQueryConfig( - requests=[ + requests=[request for req in GM_FW_REQUESTS for request in [ Request( - "EndModelPartNumber", - [StdQueries.SHORT_TESTER_PRESENT_REQUEST, GM_END_MODEL_PART_NUMBER_REQUEST], - [StdQueries.SHORT_TESTER_PRESENT_RESPONSE, GM_FW_RESPONSE + bytes([GM_END_MODEL_PART_NUMBER_REQUEST[-1]])], + [StdQueries.SHORT_TESTER_PRESENT_REQUEST, req], + [StdQueries.SHORT_TESTER_PRESENT_RESPONSE, GM_FW_RESPONSE + bytes([req[-1]])], rx_offset=GM_RX_OFFSET, bus=0, logging=True, ), - Request( - "SoftwareModule1", - [StdQueries.SHORT_TESTER_PRESENT_REQUEST, GM_SOFTWARE_MODULE_1_REQUEST], - [StdQueries.SHORT_TESTER_PRESENT_RESPONSE, GM_FW_RESPONSE + bytes([GM_SOFTWARE_MODULE_1_REQUEST[-1]])], - rx_offset=GM_RX_OFFSET, - bus=0, - logging=True, - ), - ], + ]], extra_ecus=[(Ecu.fwdCamera, 0x24b, None)], )