|
|
@ -30,18 +30,18 @@ class CarInterface(CarInterfaceBase): |
|
|
|
if True: # pylint: disable=using-constant-test |
|
|
|
if True: # pylint: disable=using-constant-test |
|
|
|
# Set global MQB parameters |
|
|
|
# Set global MQB parameters |
|
|
|
ret.safetyModel = car.CarParams.SafetyModel.volkswagen |
|
|
|
ret.safetyModel = car.CarParams.SafetyModel.volkswagen |
|
|
|
ret.enableBsm = 0x30F in fingerprint[0] |
|
|
|
ret.enableBsm = 0x30F in fingerprint[0] # SWA_01 |
|
|
|
|
|
|
|
|
|
|
|
if 0xAD in fingerprint[0]: # Getriebe_11 |
|
|
|
if 0xAD in fingerprint[0]: # Getriebe_11 |
|
|
|
ret.transmissionType = TransmissionType.automatic |
|
|
|
ret.transmissionType = TransmissionType.automatic |
|
|
|
elif 0x187 in fingerprint[0]: # EV_Gearshift |
|
|
|
elif 0x187 in fingerprint[0]: # EV_Gearshift |
|
|
|
ret.transmissionType = TransmissionType.direct |
|
|
|
ret.transmissionType = TransmissionType.direct |
|
|
|
else: # No trans message at all, must be a true stick-shift manual |
|
|
|
else: |
|
|
|
ret.transmissionType = TransmissionType.manual |
|
|
|
ret.transmissionType = TransmissionType.manual |
|
|
|
|
|
|
|
|
|
|
|
if 0x86 in fingerprint[1]: # LWI_01 seen on bus 1, we're wired to the CAN gateway |
|
|
|
if any(msg in fingerprint[1] for msg in [0x40, 0x86, 0xB2]): # Airbag_01, LWI_01, ESP_19 |
|
|
|
ret.networkLocation = NetworkLocation.gateway |
|
|
|
ret.networkLocation = NetworkLocation.gateway |
|
|
|
else: # We're wired to the LKAS camera |
|
|
|
else: |
|
|
|
ret.networkLocation = NetworkLocation.fwdCamera |
|
|
|
ret.networkLocation = NetworkLocation.fwdCamera |
|
|
|
|
|
|
|
|
|
|
|
# Global tuning defaults, can be overridden per-vehicle |
|
|
|
# Global tuning defaults, can be overridden per-vehicle |
|
|
|