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

Conversation

@sunnyhaibin
Copy link
Contributor

@sunnyhaibin sunnyhaibin commented Mar 2, 2025

Some newer MY of ICE CAN FD vehicles have 0x105 on E-CAN, therefore we can no longer rely on using this message to set the int flag for hybrid powertrain vehicles. 0x130 does not exist on all ICE vehicles even in the newer MY, so we can use this as an additional check. Found 0xFA only exists on HEV/PHEV, checked some EV and ICE routes and did not see 0xFA.

Affected Platforms

@github-actions github-actions bot added car related to opendbc/car/ hyundai labels Mar 2, 2025
@sunnyhaibin sunnyhaibin force-pushed the hyundai-canfd-engine-detection branch from b821742 to 8772b0c Compare March 3, 2025 06:19
@sunnyhaibin sunnyhaibin marked this pull request as draft March 4, 2025 07:10
@sunnyhaibin sunnyhaibin marked this pull request as ready for review March 4, 2025 07:50
@sunnyhaibin
Copy link
Contributor Author

sunnyhaibin commented Mar 4, 2025

test_models revealed that KIA_NIRO_HEV_2ND_GEN does not have 0x130, therefore we cannot assume that all HEV/PHEV have 0x130.

Found 0xFA only exists on a few CAN FD HEV:

  • 2022 Hyundai Tucson Hybrid: 5a681a11ff756d93/000007f8--c1381a3194
  • 2024 Kia Carnival Hybrid: 22a05b58157a0d7f/00000000--57c6170020
  • 2024 Hyundai Sonata Hybrid: e6fd6ef0e9cc1171/00000197--5d9d371e2c

Checked some EV and ICE routes and did not see 0xFA.

Validation: https://github.com/commaai/openpilot/actions/runs/13648043542/job/38150425614?pr=34769

@sshane any other validation we need for the time being?

@jyoung8607
Copy link
Collaborator

@sunnyhaibin You might find commaai/openpilot#34771 helpful in validating. For those cars that aren't in the dataset, like the new car ports you're working on, you can just append any segments you have access to, LogReader will pick them up.

@sunnyhaibin
Copy link
Contributor Author

@sunnyhaibin You might find commaai/openpilot#34771 helpful in validating. For those cars that aren't in the dataset, like the new car ports you're working on, you can just append any segments you have access to, LogReader will pick them up.

Excellent. Just ran the notebook with some minor tweaks, working great! ❤️
image

@jyoung8607
Copy link
Collaborator

Excellent. Just ran the notebook with some minor tweaks, working great! ❤️

Want to re-check with the updates in commaai/openpilot#34782? You can add routes for all the new HKG cars that aren't in the commaCarSegments dataset to EXTRA_SEGMENTS, whether they've been merged upstream or not.

@sunnyhaibin
Copy link
Contributor Author

Excellent. Just ran the notebook with some minor tweaks, working great! ❤️

Want to re-check with the updates in commaai/openpilot#34782? You can add routes for all the new HKG cars that aren't in the commaCarSegments dataset to EXTRA_SEGMENTS, whether they've been merged upstream or not.

Works great!

image

@jyoung8607 jyoung8607 merged commit db8f4cf into commaai:master Mar 11, 2025
8 checks passed
@jyoung8607 jyoung8607 deleted the hyundai-canfd-engine-detection branch March 11, 2025 19:19
chrispypatt pushed a commit to chrispypatt/opendbc that referenced this pull request Mar 12, 2025
* Hyundai CAN FD: Accurate hybrid  powertrain detection

* label message names

* use 0xFA
Edison-CBS pushed a commit to Edison-CBS/opendbc that referenced this pull request Apr 5, 2025
* Hyundai CAN FD: Accurate hybrid  powertrain detection

* label message names

* use 0xFA
eli-davis pushed a commit to eli-davis/opendbc_reference that referenced this pull request Jul 15, 2025
* Hyundai CAN FD: Accurate hybrid  powertrain detection

* label message names

* use 0xFA
jyoung8607 added a commit that referenced this pull request Sep 29, 2025
* Add secoc ACC command

* Remove commented out secoc long disable code

* Add Toyota 2021 SecOC route

* Send 0 accel for ACC_CONTROL to match stock

* Update opendbc/car/toyota/carcontroller.py

Co-authored-by: Jason Young <46612682+jyoung8607@users.noreply.github.com>

* Add new ACC steering wheel message for SecOC cars. Update distance_button with the new message.

* Add new DBC file for Toyota SecOC cars.

* Update Toyota Rav4 Prime and 4th Gen Sienna to use SecOC DBC file.

* Update carstate.py l

* dont save button state on secoc

Co-authored-by: Jason Wen <haibin.wen3@gmail.com>

* Update opendbc/car/toyota/carstate.py

Co-authored-by: Jason Wen <haibin.wen3@gmail.com>

* Remove unreachable code

* Move secoc safety to opendbc

* Update R4P SecOC route

* Build safety with -Wextra

* safety: relay malfunction config (#1959)

* Do Toyota relay malfunction config

* clean up

* not needed

* rm this

* rm

* fix

* great name (rename after #1954)

* do gm

* need this since we will dynamically block it

* subie

* some more brands

* Ford

* Chrysler

* Hyundai

* huge oof hyundai

* toyota & vw

* fix

* tesla

* 0x194 isn't on Honda Bosch

* Honda: we can check bus 1 for 0xe4

* misra

* static

* ugh need this

* correct

* nl

* like

* space

* Hyundai: dashcam FCEV (#1973)

* Disable FCEV

* coverage

* fixme

* misra

misra

* Hyundai CAN FD: Accurate hybrid powertrain detection (#1891)

* Hyundai CAN FD: Accurate hybrid  powertrain detection

* label message names

* use 0xFA

* Tesla: Autopilot enabled signal (#1978)

* new Tesla signals

* consistent

---------

Co-authored-by: Shane Smiskol <shane@smiskol.com>

* Tesla: fix incorrect DBC msg length (#1980)

actually DBC is wrong

* Subaru Pre-Global: fix missing rx checks (#1982)

passes tm

* Honda Nidec: missing brake command rx check (#1981)

* missing honda rx nidec brake command

* misra

* move up

* Honda safety: only test alt brake for alt brake param

split from #1903

* safety tests: remove redundant test skips (#1983)

remove useless skiptests

* GM safety: add missing regen rx check (#1984)

* from pr

* forgot

* fix test

* cleaner

* misra

* Fingerprint: 2022 Civic Si (#1952)

* 2022 Civic Si

* fix

* Hyundai CAN FD safety: more clear what is common (#1986)

* more clear what is common

* here too

* Hyundai CANFD safety tests: common safety param combinations (#1987)

clean this up

* Hyundai CAN FD safety: replace alt buttons live detection with param (#1985)

* alt buttons needs to be checked with the param

* flip

* do tests

* Hyundai safety: add missing rx checks (#1989)

* add torque driver addr check and always check buttons (for interaction)

* fix

* safety: rename allowed

less confusing next to `safety_allowed`

* safety: only run rx hooks on whitelisted msgs (#1903)

* don't run rx hook on non-allowed messages

* better name

* fix toyota (bug w/ secoc)

* looks like honda is broken

* rivian is also bad! (missing EPAS_SystemStatus)

* misra so far

rivian is also bad!

* nissan is fine

* tesla is also borked

* mazda's good

* subaru's fine

* gm broke

* ford's good

* chrysler's good

* vw is good

* hyundai is broky, canfd is good

* Fix Rivian

* revert these

* do relay malfunction check on all addresses

* Found a Tesla bug

* fix subaru pg

* body

* rm

* Fix Honda

* stash

* fix Hyundai

* fix

* Hyundai: buttons are used always (for interaction)

* revert tesla

* body: we don't rx _torque_cmd_msg

* Revert "body: we don't rx _torque_cmd_msg"

This reverts commit 2f973f6.

* simpler

* GM EV param for correct rxchecks

* no need

* might read better

* rm extras

* fix hyundai

* we weren't testing lfa (non-hda2), alt buttons, long

* fix

* tested

* rm

* not needed

* clean up

* that too

* .

* Hyundai: Fix FCEV RX check and move out of dashcam (#1974)

* Revert "Hyundai: dashcam FCEV (#1973)"

This reverts commit 6254215.

* Hyundai: Fix FCEV RX check and move out of dashcam

* less duplication

* line

* same

* add missing test

---------

Co-authored-by: Shane Smiskol <shane@smiskol.com>

* HKG: spas remove unused frame param (#1966)

spas remove unused frame param

* Added FW for Mazda CX5 2025 (#1911)

Add other CX-5 2025 FP fw

* Hyundai CAN FD: Fix steering messages in safety replay (#1975)

* Hyundai: split car controller by CAN FD (#1990)

* split main can sends part

* use_clu11 was confusing

* better

* bet

* clean up

* Toyota: add static rx check for alt brake (#1991)

rx check for alt brake

* whoops bad pull

* PR suggestions

* Remove unnecessary parens

* PR suggestions

* Fix some logical errors

* Fix tester present test

* Update safety for non-op long secoc

* Update tests

* Update safety

* Update tests

* whitespace adjustment for clarity

* PR suggestions

---------

Co-authored-by: Jason Young <46612682+jyoung8607@users.noreply.github.com>
Co-authored-by: PenitentTangent2401 <klabuschagne@kd9atp.com>
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
Co-authored-by: Shane Smiskol <shane@smiskol.com>
Co-authored-by: Lukas <61192133+lukasloetkolben@users.noreply.github.com>
Co-authored-by: vanillagorillaa <31773928+vanillagorillaa@users.noreply.github.com>
Co-authored-by: royjr <royjr96@gmail.com>
Co-authored-by: kenhuang14 <97474725+kenhuang14@users.noreply.github.com>
Co-authored-by: Warren Togami <wtogami@gmail.com>
Co-authored-by: Jason Young <jyoung8607@gmail.com>
gadhadar pushed a commit to qzwf/opendbc that referenced this pull request Oct 14, 2025
* Add secoc ACC command

* Remove commented out secoc long disable code

* Add Toyota 2021 SecOC route

* Send 0 accel for ACC_CONTROL to match stock

* Update opendbc/car/toyota/carcontroller.py

Co-authored-by: Jason Young <46612682+jyoung8607@users.noreply.github.com>

* Add new ACC steering wheel message for SecOC cars. Update distance_button with the new message.

* Add new DBC file for Toyota SecOC cars.

* Update Toyota Rav4 Prime and 4th Gen Sienna to use SecOC DBC file.

* Update carstate.py l

* dont save button state on secoc

Co-authored-by: Jason Wen <haibin.wen3@gmail.com>

* Update opendbc/car/toyota/carstate.py

Co-authored-by: Jason Wen <haibin.wen3@gmail.com>

* Remove unreachable code

* Move secoc safety to opendbc

* Update R4P SecOC route

* Build safety with -Wextra

* safety: relay malfunction config (commaai#1959)

* Do Toyota relay malfunction config

* clean up

* not needed

* rm this

* rm

* fix

* great name (rename after commaai#1954)

* do gm

* need this since we will dynamically block it

* subie

* some more brands

* Ford

* Chrysler

* Hyundai

* huge oof hyundai

* toyota & vw

* fix

* tesla

* 0x194 isn't on Honda Bosch

* Honda: we can check bus 1 for 0xe4

* misra

* static

* ugh need this

* correct

* nl

* like

* space

* Hyundai: dashcam FCEV (commaai#1973)

* Disable FCEV

* coverage

* fixme

* misra

misra

* Hyundai CAN FD: Accurate hybrid powertrain detection (commaai#1891)

* Hyundai CAN FD: Accurate hybrid  powertrain detection

* label message names

* use 0xFA

* Tesla: Autopilot enabled signal (commaai#1978)

* new Tesla signals

* consistent

---------

Co-authored-by: Shane Smiskol <shane@smiskol.com>

* Tesla: fix incorrect DBC msg length (commaai#1980)

actually DBC is wrong

* Subaru Pre-Global: fix missing rx checks (commaai#1982)

passes tm

* Honda Nidec: missing brake command rx check (commaai#1981)

* missing honda rx nidec brake command

* misra

* move up

* Honda safety: only test alt brake for alt brake param

split from commaai#1903

* safety tests: remove redundant test skips (commaai#1983)

remove useless skiptests

* GM safety: add missing regen rx check (commaai#1984)

* from pr

* forgot

* fix test

* cleaner

* misra

* Fingerprint: 2022 Civic Si (commaai#1952)

* 2022 Civic Si

* fix

* Hyundai CAN FD safety: more clear what is common (commaai#1986)

* more clear what is common

* here too

* Hyundai CANFD safety tests: common safety param combinations (commaai#1987)

clean this up

* Hyundai CAN FD safety: replace alt buttons live detection with param (commaai#1985)

* alt buttons needs to be checked with the param

* flip

* do tests

* Hyundai safety: add missing rx checks (commaai#1989)

* add torque driver addr check and always check buttons (for interaction)

* fix

* safety: rename allowed

less confusing next to `safety_allowed`

* safety: only run rx hooks on whitelisted msgs (commaai#1903)

* don't run rx hook on non-allowed messages

* better name

* fix toyota (bug w/ secoc)

* looks like honda is broken

* rivian is also bad! (missing EPAS_SystemStatus)

* misra so far

rivian is also bad!

* nissan is fine

* tesla is also borked

* mazda's good

* subaru's fine

* gm broke

* ford's good

* chrysler's good

* vw is good

* hyundai is broky, canfd is good

* Fix Rivian

* revert these

* do relay malfunction check on all addresses

* Found a Tesla bug

* fix subaru pg

* body

* rm

* Fix Honda

* stash

* fix Hyundai

* fix

* Hyundai: buttons are used always (for interaction)

* revert tesla

* body: we don't rx _torque_cmd_msg

* Revert "body: we don't rx _torque_cmd_msg"

This reverts commit 2f973f6.

* simpler

* GM EV param for correct rxchecks

* no need

* might read better

* rm extras

* fix hyundai

* we weren't testing lfa (non-hda2), alt buttons, long

* fix

* tested

* rm

* not needed

* clean up

* that too

* .

* Hyundai: Fix FCEV RX check and move out of dashcam (commaai#1974)

* Revert "Hyundai: dashcam FCEV (commaai#1973)"

This reverts commit 6254215.

* Hyundai: Fix FCEV RX check and move out of dashcam

* less duplication

* line

* same

* add missing test

---------

Co-authored-by: Shane Smiskol <shane@smiskol.com>

* HKG: spas remove unused frame param (commaai#1966)

spas remove unused frame param

* Added FW for Mazda CX5 2025 (commaai#1911)

Add other CX-5 2025 FP fw

* Hyundai CAN FD: Fix steering messages in safety replay (commaai#1975)

* Hyundai: split car controller by CAN FD (commaai#1990)

* split main can sends part

* use_clu11 was confusing

* better

* bet

* clean up

* Toyota: add static rx check for alt brake (commaai#1991)

rx check for alt brake

* whoops bad pull

* PR suggestions

* Remove unnecessary parens

* PR suggestions

* Fix some logical errors

* Fix tester present test

* Update safety for non-op long secoc

* Update tests

* Update safety

* Update tests

* whitespace adjustment for clarity

* PR suggestions

---------

Co-authored-by: Jason Young <46612682+jyoung8607@users.noreply.github.com>
Co-authored-by: PenitentTangent2401 <klabuschagne@kd9atp.com>
Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
Co-authored-by: Shane Smiskol <shane@smiskol.com>
Co-authored-by: Lukas <61192133+lukasloetkolben@users.noreply.github.com>
Co-authored-by: vanillagorillaa <31773928+vanillagorillaa@users.noreply.github.com>
Co-authored-by: royjr <royjr96@gmail.com>
Co-authored-by: kenhuang14 <97474725+kenhuang14@users.noreply.github.com>
Co-authored-by: Warren Togami <wtogami@gmail.com>
Co-authored-by: Jason Young <jyoung8607@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

car related to opendbc/car/ hyundai

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants