这是indexloc提供的服务,不要输入任何密码
Skip to content

Conversation

@Dennis-NL
Copy link
Contributor

@Dennis-NL Dennis-NL commented Nov 17, 2025

Validation

  • Route: 5432d2499e17e646/00000434--f9f0af36f6
  • Adding support for Audi B8:
    Audi Q5 8R 2013 - 2017 (Only one thats fingerprinted for now)
    Audi A4 B8.5 2012 - 2015
    Audi A5 8K 2013 - 2016

  • Fingerprint check for Macan due to signal difference

  • Change seatbelt signal for compatibility between B8 and Macan

Related to: #2846

@Dennis-NL Dennis-NL changed the title Mlb MLB: Audi B8 support Nov 17, 2025
@github-actions github-actions bot added DBC signals car related to opendbc/car/ volkswagen car safety vehicle-specific safety code labels Nov 17, 2025
Comment on lines +254 to +256
ret.cruiseState.available = pt_cp.vl["TSK_02"]["TSK_Status"] in (0, 1, 2)
ret.cruiseState.enabled = pt_cp.vl["TSK_02"]["TSK_Status"] in (1, 2)
ret.accFaulted = pt_cp.vl["TSK_02"]["TSK_Status"] in (3,)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These are present on Macan and probably work the same way. I chose not to switch, at this time, because we don't actually get state of the mainswitch (cruiseState.available). There's another TSK message that does have it, but it's only present on the car's powertrain bus (bus 1 on our harness) which I prefer not to grow dependencies on. LS_01 is a possibility but then we may have to understand and track momentary-press buttons and keep state.

I would remove this for now, pending a more complete solution, at which time we'd switch all MLB.

Copy link
Contributor Author

@Dennis-NL Dennis-NL Nov 17, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't see TSK_02 on the Macan route i have, only 03, 04 and 05. Q5 only has TSK_02
Edit: Used wrong DBC. Q5 also has 03 and 04 on bus 1

Comment on lines +269 to +274
if self.CP.carFingerprint == CAR.PORSCHE_MACAN_MK1:
ret.leftBlinker = bool(pt_cp.vl["Gateway_11"]["BH_Blinker_li"])
ret.rightBlinker = bool(pt_cp.vl["Gateway_11"]["BH_Blinker_re"])
else:
ret.leftBlinker = bool(pt_cp.vl["Blinkmodi_01"]["BM_links"])
ret.rightBlinker = bool(pt_cp.vl["Blinkmodi_01"]["BM_rechts"])
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Blinkmodi_01 is present on Macan, so if we have to switch, we'd just switch all cars. I didn't want to use it because it's on-demand only: frequency zero when there's no activity. I didn't really like that.

It'll also need to be wrapped with update_blinker_from_lamp so that one-touch lane changes work right:

def update_blinker_from_lamp(self, blinker_time: int, left_blinker_lamp: bool, right_blinker_lamp: bool):
.

Copy link
Contributor Author

@Dennis-NL Dennis-NL Nov 17, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comfort blinkers (1 tap thing) works perfectly fine with OP on mine. Gateway_11 doesn't seem available on mine, but it is on another Facelifted Q5 on bus 1

Edit: It is on mine aswell, small problem with the harness thats now fixed

]
if CP.flags & VolkswagenFlags.MLB:
pt_messages += [
("Blinkmodi_01", math.nan) # From J519 BCM (is inactive when no lights active, 50Hz when active)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Did zero not work for the frequency? math.nan is weird.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

0 gives me a can error. This is how @oscarmcnulty did it and it works


BU_: Airbag_D4 EPB_D4 ESP_D4 Gateway_D4C7 Getriebe_AL551_951_D4_C7 Getriebe_DL501_C7 Getriebe_VL381_C7 LWS_D4 Motor_EDC17_D4 Motor_ME17_BY Motor_MED17_SIMOS8_D4 Motor_Slave_D4 QSP_D4 SAK_C7 SCR_C7 SCU_D4

BO_ 265 ACC_01: 8 Gateway_B8
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Send the DBC update in a separate PR, so we can merge that while reviewing the rest.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done: #2906

def create_acc_accel_control(packer, bus, acc_type, acc_enabled, accel, acc_control, stopping, starting, esp_hold):
values = {}
return packer.make_can_msg("ACC_05", bus, values)
return 0
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why this change?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think i forgot to take that one out while troubleshooting

Comment on lines 361 to 366
AUDI_A4_MK4 = VolkswagenMLBPlatformConfig(
[VWCarDocs("Audi A4 B8.5 2012-15")],
VolkswagenCarSpecs(mass=1650, wheelbase=2.81),
chassis_codes={"8K"},
wmis={WMI.AUDI_GERMANY_CAR},
)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I understand this is probably part of your testing process with the various MLB users, but to set expectations, we'll want to cut down to just one car for merge validation and then merge additional cars separately.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed it for now
154795a

@jyoung8607
Copy link
Collaborator

@Dennis-NL can you share some uploaded public test routes from the vehicles you're working with? I can help with aligning working signals.

@Dennis-NL
Copy link
Contributor Author

@Dennis-NL can you share some uploaded public test routes from the vehicles you're working with? I can help with aligning working signals.

5432d2499e17e646/00000434--f9f0af36f6

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

car safety vehicle-specific safety code car related to opendbc/car/ DBC signals volkswagen

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants