Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hyundai: longitudinal support for all CAN-FD EV and Hybrids #26345

Merged
merged 24 commits into from
Nov 16, 2022

Conversation

hoomoose
Copy link
Contributor

@hoomoose hoomoose commented Nov 3, 2022

Description
OP long (and e2e) is currently enabled for HDA2 Can-fd HKG cars but not HDA1. I have picked the modifications from #25434 (thank you Sunnyhaibin!) that only relate to enabling OP Long. This code should not affect HDA2 variants of cars that have both HDA1 and HDA2 variants because the flag for labelling a car as "CANFD_CAMERA_SCC" is placed after an "Else" statement following cars flagged as HDA2. Therefore, an HDA2 car can never receive the "CANFD_CAMERA_SCC" flag. I have added EV6 and Ioniq 5 to the CAMERA_SCC_CAR car list because I can verify this with my HDA1 EV6, but the referenced PR shows that other Can-fd cars have this tested as well.

11/8/22 update:
Based on latest code, all that is changed is 1) set OP long to true for can-fd cars and 2) and "if hda2" in front of sending adrv messages, 3) two commits excluding cars flagged as CANFD_CAMERA_SCC from having radar disabled.

Prerequisite
This requires a Panda update that does the following:

  1. add in ecu detection for HDA1 cars with SCC info on bus 0
  2. add an hda2 requirement for checking for ADAS ecu
  3. add 0x1a0 through the fwd hook if not hda2
  4. remove hda2 requirement for OP long

see: commaai/panda#1128

Verification
HDA1 EV6
Route: 68d6a96e703c00c9|2022-11-03--13-35-26

@hoomoose
Copy link
Contributor Author

hoomoose commented Nov 8, 2022

With the HKG GV70 PR now committed, I have added two commits excluding cars flagged as CANFD_CAMERA_SCC from having radar disabled. I will upload updated route shortly.

@hoomoose
Copy link
Contributor Author

hoomoose commented Nov 9, 2022

With latest change.
Route: 68d6a96e703c00c9|2022-11-08--16-46-18

@adeebshihadeh
Copy link
Contributor

Thanks, but this is blocked on refactoring the panda safety address checks. Once that's done, it'll be easy to support HDA1 long.

@adeebshihadeh adeebshihadeh reopened this Nov 15, 2022
@adeebshihadeh
Copy link
Contributor

adeebshihadeh commented Nov 15, 2022

Looks like only ICE CAN-FD will be blocked on that refactor. We can merge this in the meantime.

@adeebshihadeh adeebshihadeh changed the title Hyundai: OP Longitudinal support for HDA1 CAN-FD Hyundai: longitudinal support for all CAN-FD EV and Hybrids Nov 16, 2022
@adeebshihadeh adeebshihadeh merged commit 9c5df76 into commaai:master Nov 16, 2022
@ebg1223
Copy link

ebg1223 commented Nov 19, 2022

@adeebshihadeh just curious, is ICE CAN-FD blocking on these PRs: #26090 commaai/panda#1107 ? or is this a separate issue? Just trying to see if I can contribute, but want to make sure i'm looking in the right direction. For ICE CAN-FD cars using radar cruise, it would be the same as the hybrid / evs correct?

@adeebshihadeh
Copy link
Contributor

@adeebshihadeh just curious, is ICE CAN-FD blocking on these PRs: #26090 commaai/panda#1107 ? or is this a separate issue? Just trying to see if I can contribute, but want to make sure i'm looking in the right direction. For ICE CAN-FD cars using radar cruise, it would be the same as the hybrid / evs correct?

No, we don't support long for any CAN-FD models yet. Unfortunately, there's not much to contribute in this case. We just need to do the refactor ourselves.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants