Skip to content

HKG: Car Port for Genesis GV80 2025-26 (HDA2, LFA2)#1646

Open
sunnyhaibin wants to merge 88 commits intocommaai:masterfrom
sunnypilot:gv80-2025
Open

HKG: Car Port for Genesis GV80 2025-26 (HDA2, LFA2)#1646
sunnyhaibin wants to merge 88 commits intocommaai:masterfrom
sunnypilot:gv80-2025

Conversation

@sunnyhaibin
Copy link
Copy Markdown
Contributor

@sunnyhaibin sunnyhaibin commented Jan 18, 2025

Checklist

  • added entry to CarInfo in selfdrive/car/*/values.py and ran selfdrive/car/docs.py to generate new docs
  • test route added to routes.py
  • route with openpilot:
  • harness Type:
    • Hyundai Q - 3.5T
    • Hyundai R - 2.5T
  • architecture: CAN-FD

Thanks to the community 2025 Genesis GV80 (HDA2) owner jkxs.

@sunnyhaibin sunnyhaibin changed the title Gv80 2025 KKG: Car Port for Genesis GV80 2025 (HDA2) Jan 18, 2025
@github-actions github-actions bot added car related to opendbc/car/ hyundai DBC signals labels Jan 18, 2025
@github-actions github-actions bot added the car safety vehicle-specific safety code label Feb 27, 2025
@sunnyhaibin sunnyhaibin force-pushed the gv80-2025 branch 2 times, most recently from ee5f572 to 0de45d9 Compare March 1, 2025 06:44
@sshane
Copy link
Copy Markdown
Contributor

sshane commented Mar 1, 2025

#1674 (comment)

@sunnyhaibin sunnyhaibin changed the title KKG: Car Port for Genesis GV80 2025 (HDA2) HKG: Car Port for Genesis GV80 2025 (HDA2) Mar 2, 2025
@sunnyhaibin sunnyhaibin changed the title HKG: Car Port for Genesis GV80 2025 (HDA2) HKG: Car Port for Genesis GV80 2025-26 (HDA II, LFA2) Mar 26, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Mar 26, 2026

Car behavior report

Replays driving segments through this PR and compares the behavior to master.
Please review any changes carefully to ensure they are expected.

Testing 260 segments for: HYUNDAI_AZERA_HEV_6TH_GEN, HYUNDAI_ELANTRA_GT_I30, HYUNDAI_ELANTRA_2021, HYUNDAI_ELANTRA_HEV_2021, HYUNDAI_GENESIS, HYUNDAI_IONIQ, HYUNDAI_IONIQ_HEV_2022, HYUNDAI_IONIQ_EV_2020, HYUNDAI_IONIQ_PHEV_2019, HYUNDAI_IONIQ_PHEV, HYUNDAI_KONA_2022, HYUNDAI_KONA_EV, HYUNDAI_KONA_EV_2022, HYUNDAI_KONA_EV_2ND_GEN, HYUNDAI_SANTA_FE, HYUNDAI_SANTA_FE_2022, HYUNDAI_SANTA_FE_HEV_2022, HYUNDAI_SANTA_FE_PHEV_2022, HYUNDAI_SONATA, HYUNDAI_SONATA_LF, HYUNDAI_STARIA_4TH_GEN, HYUNDAI_PALISADE, HYUNDAI_SONATA_HYBRID, HYUNDAI_IONIQ_5, HYUNDAI_IONIQ_6, HYUNDAI_TUCSON_4TH_GEN, HYUNDAI_SANTA_CRUZ_1ST_GEN, HYUNDAI_CUSTIN_1ST_GEN

✅ 0 changed, 260 passed, 0 errors

@sunnyhaibin sunnyhaibin changed the title HKG: Car Port for Genesis GV80 2025-26 (HDA II, LFA2) HKG: Car Port for Genesis GV80 2025-26 (HDA2, LFA2) Mar 29, 2026
MAX_ANGLE_CONSECUTIVE_FRAMES)

if not CC.latActive:
if not self.CP.flags & HyundaiFlags.CANFD_ANGLE_STEERING:
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

As a stylistic/readability preference, it would be nice to avoid the not here, when scanning quickly it looks like this block contains angle code rather than torque code.

Comment on lines 110 to 119
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Move this stuff inside the torque control block above

ret.steeringAngleDeg = cp.vl["MDPS"]["MDPS_EstStrAnglVal"]
ret.steerFaultTemporary = ret.steerFaultTemporary or cp.vl["MDPS"]["MDPS_ADAS_AciFltSig_Lv2"] != 0
self.hands_on_steering_grip = cp.vl["HOD_FD_01_100ms"]["HOD_Dir_Status"]
self.imu_lateral_acceleration = cp.vl["IMU_01_10ms"]["IMU_LatAccelVal"] * 9.81 # m/s^2
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

This does not appear legit. Also there are no consumers I can find. Can this go away entirely?

Comment on lines +21 to +23
RAMP_RATE = 0.008
RECOVERY_RATE = 0.02
OVERRIDE_DROP_RATE = 0.05
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Suggested change
RAMP_RATE = 0.008
RECOVERY_RATE = 0.02
OVERRIDE_DROP_RATE = 0.05
RAMP_RATE = 0.008
RECOVERY_RATE = 0.02
OVERRIDE_DROP_RATE = 0.05

store in reduction per seconds, or just divide by steer step

@sshane
Copy link
Copy Markdown
Contributor

sshane commented Mar 30, 2026

last commit is messy, but we found that we need to closely match the stock torque reduction gain + add some sort of smoothing to the angle request to stop the noisy angle control at lower speeds.

image

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 hyundai

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants