Commit Graph

49 Commits

Author SHA1 Message Date
Shane Smiskol d82173e685 Toyota: resolve controls mismatch due to interceptor thresholds (#23710)
* remove gas interceptor exception

* panda

* bump submodules

* bump panda

* forgot carstate change

* revert

* add test route

* bump

* update refs for CS.gas

* bump submodules to master
old-commit-hash: 17cb65c4b75987e4fa6630a02f384e27f1472d13
2022-04-20 22:28:56 -07:00
Shane Smiskol 3e201c015d test_models: add Honda segment for standstill controls mismatch (#24275)
old-commit-hash: e515831e5f879c936347ee7422dbdd6f6d327d68
2022-04-20 12:54:52 -07:00
Shane Smiskol 955ca69cc4 Honda: do same standstill check as panda (#24262)
* check standstill against panda

* use XMISSION_SPEED for all, and compare to 0

* fix

* only check for Honda for now

* update comment

* update refs

* update refs and update check

* phantom commit
old-commit-hash: 6de434f2ecee89e86c011bece57cb205c4c047e3
2022-04-19 23:18:01 -07:00
HaraldSchafer 2174005f05 Lateral torque-based control with roll on TSS2 corolla and TSSP rav4 (#24260)
* Initial commit

* Fix bugs

* Need more torque rate

* Cleanup cray cray control

* Write nicely

* Chiiil

* Not relevant for cray cray control

* Do some logging

* Seems like it has more torque than I thought

* Bit more feedforward

* Tune change

* Retune

* Retune

* Little more chill

* Add coroll

* Add corolla

* Give craycray a good name

* Update to proper logging

* D to the PI

* Should be in radians

* Add d

* Start oscillations

* Add D term

* Only change torque rate limits for new tune

* Add d logging

* Should be enough

* Wrong sign in D

* Downtune a little

* Needed to prevent faults

* Add lqr rav4 to tune

* Try derivative again

* Data based retune

* Data based retune

* add friction compensation

* Doesnt need too much P with friction comp

* remove lqr

* Remove kd

* Fix tests

* fix tests

* Too much error

* Get roll induced error under 1cm/deg

* Too much jitter

* Do roll comp

* Add ki

* Final update

* Update refs

* Cleanup latcontrol_torque a little more
old-commit-hash: fe0bcdaef6b1fd3fc9d855aefeba755b35dfc222
2022-04-19 19:34:31 -07:00
Jason Wen fc6d8b7d7b Hyundai: Car Port for Ioniq Plug-in Hybrid 2019 (#24089)
* Add car port: Hyundai Ioniq Plug-In Hybrid 2019

* Add additiona FW version

* Add test route

* Add test route - fix typo

* Update CARS.md and RELEASES.md

* remove from legacy safety mode

* Update carcontroller.py

* Update to INDI lateral tune

* update spacing and capitalization

* generate docs

* Update selfdrive/car/hyundai/carcontroller.py

Co-authored-by: Shane Smiskol <shane@smiskol.com>
old-commit-hash: f6034ecece7cad2d3b33833235800bfe89a0769c
2022-04-18 15:15:38 -07:00
Cameron Clough 0830dc0277 Ford: Support for LCA vehicles (#23331)
* Ford: add Focus Mk4

Also removes support for the Ford Fusion.

* Ford: LKAS/LCA steering and UI CAN commands

* Ford: implement CarController w/ steering and lanes ui

* Ford: FPv2 firmware request

* Ford: Add FW for 2018 Ford Focus

* Ford: add Escape Mk4

* bump panda

* cleanup

* add that back

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
old-commit-hash: acd455ed3ae0ffbb82fe36dd6d9a1f4d16279823
2022-04-14 14:32:03 -07:00
Shane Smiskol 9f4c123a14 car docs test: check car name (#24193)
old-commit-hash: f3bcbb1b505ec61737a950baa2b2f4779f463c2a
2022-04-12 12:45:31 -07:00
Shane Smiskol 052b799262 Honda: resolve controls mismatch due to interceptor thresholds (#24173)
* make panda and openpilot thresholds match

* Revert "make panda and openpilot thresholds match"

This reverts commit dfcbd2058784de809564ada41e4cfbbfca7afe77.

* make panda and openpilot thresholds match

* remove interceptor scaling, compare int value

* remove honda exception

* bump panda

* bump opendbc

* add segment to check controls mismatch

* bump submodules
old-commit-hash: e8faf9f9853b445c6ddfd9ee1f1e44fbcfe3a96f
2022-04-12 11:20:55 -07:00
Shane Smiskol 453be8af86 test_models: support for specifying segment (#24185)
* support for specifying segment

* revert

* formatting

* revert

* Fix mypy

* raise exception if specified segment isn't available

oh, ndog param wasn't being set

* easier to read

* add to exception
old-commit-hash: 85c714e350b2445a78299fe6df8c06a36d80bcea
2022-04-11 22:03:23 -07:00
Jason Wen c1771aba84 Hyundai: Car Port for Tucson Diesel 2019 (#24082)
* Add car port: Hyundai Tucson Diesel 2019

* SCC + LKAS trims only

* Add test route

* Update CARS.md

* remove from legacy safety mode

Co-authored-by: Shane Smiskol <shane@smiskol.com>
old-commit-hash: 6214991d9861fd3bb425fa1133a847c3a24342d4
2022-04-08 11:32:18 -07:00
Shane Smiskol bacfb41d63 car docs: enforce naming conventions (#24116)
* assert car docs naming conventions

* fix static analysis

* It's actually Plug-in according to Hyundai (Google capitalizes it)

* fix docs
old-commit-hash: 433f649faaeb9b605827a2e898079fb6cf0b1279
2022-04-04 15:50:27 -07:00
Igor Biletskyy df806cdbeb car port: comma body (#24019)
* body FPv2

* ..

* ..

* ..

* Temp, REVERT!

* more cleanup

* typo

* ..

* del eyes

* should work?

* fix

* new dbc

* ..

* fixes

* static analysis

* cln balancing code

* no test route

* excluded_interfaces

* THE DOCS!

* comments on steer/speed mixin

* switch to bus 0

* less UDS

* FAKE bus 0 vin and fingerprint

* FAKE locationd

* Keep steady and remove handcoded offset

* Improve startup sequence, get closer to stock openpilot

* Forgot to define angle

* lowercase

* revert that

* little cleanup

* change safety model

* update refs

* body is gold

* handle no llk

* oops

* litte more

Co-authored-by: Comma Device <device@comma.ai>
Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
old-commit-hash: 031f79ba88c58f9fbc087df0a1e2ba5ddc3f80db
2022-03-31 17:16:15 -07:00
Adeeb Shihadeh bd71c594a2 pylint: enforce indentation (W0311) (#24039)
* pylint: enforce indentation (W0311)

* few more
old-commit-hash: 8af20af66ddaa6bc06d7f72f9134aa9afeed3ed8
2022-03-24 23:23:29 -07:00
Adeeb Shihadeh 3679d88b80 test models: skip with flag
old-commit-hash: a55e25d9d2ab7f6f42b8c2c61aa73c841deaac09
2022-03-23 16:42:04 -07:00
Shane Smiskol 426a300c21 docs: support for automatically generating website vehicles page (#24020)
* add vehicles.vue template

* add original vue file

* stash

* stash

* clean up a bit

* add template for now

* implement footnotes and tier copy

* no more generator

* convert to 2 spaces

* should work, now onto vue

* does GH handle this html well?

* fix

* auto-generate descriptions and make tiers' maps non-str

* remove old files

* move template specific variable into templates, should be a bit simpler

* js template is simplier too now

js template is simplier too now

js template is simplier too now

* add video links from the nice car_info

* make rows attributes

* clean up

* fix

* remove template

* experiment with video links in GH

add image

how does this look?

fix

* Revert "experiment with video links in GH"

This reverts commit 8375e717b563f7b4ecf009ffae00174de1a0b8e9.

* sort tier_car_info in place

* unused Tuple

* no type check

* fix script
old-commit-hash: 85d8997a8a66ef7652b1b186a72d9551292a24ad
2022-03-23 13:42:53 -07:00
Adeeb Shihadeh a3b70f8891 skip test models in unittest discovery
old-commit-hash: c76434ca9fae432c2da307e6e51b78f56c5fe43c
2022-03-21 13:42:07 -07:00
Shane Smiskol 8a88db322e Support Toyota Alphard Hybrid 2021 (#24003)
* add 2021 Alphard Hybrid

revert

* fix fp name

* run docs generator

* Add to releases

* test route

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
old-commit-hash: 15368ec3d1cb41a71856fb8e3f2b89320b087053
2022-03-20 16:40:25 -07:00
Shane Smiskol ce4fd26e58 Toyota: Support Avalon Hybrid 2022 (TSS2.5) (#23892)
* Add Avalon Hybrid 2022

* update docs

* set a tune

* add test route

* uploaded route
old-commit-hash: 247b66f4a801d3621575edf5a247c54e275d2826
2022-03-19 13:14:04 -07:00
Shane Smiskol bf8262394f Docs: auto-generate supported cars documentation (#23762)
* make CAR class enum, and values.py formatting

* Revert "make CAR class enum, and values.py formatting"

This reverts commit 04d9817e9d5d6ab5c027754018fc445f2cd3067a.

* stash

* add supported packages and model years

* don't change model years in fps

* move Lexus to info dict and make int enum

* remove sometimes wrong model years from name string

* use enum names

* convert Honda's values

* nice names

* use name

* GM

* Mazda, Ford

* Hyundai: WIP

* finish Hyundai

* fix

* Nissan

* Subaru

* Tesla

* formatting is for another PR

* Chrysler: todo: unify the Pacificas?

* do volkswagen

* this isn't a zoo

* skip enums for now

* Update selfdrive/car/volkswagen/values.py

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

* set All

* temp cars

* auto-generate CARS.md

* update type hinting

* add generated file

* add longitudinal star to cars that support disabling radar

* add TODO

* add notes

* add min_steer_speed exception for hatchback

* add minimum steering speeds

* Add exceptions and run generator

* Missing Telluride

* fix Prius v

* missing Prius Prime

generate

* start to convert years to strings

* Fixup Hyundai

* convert year sets to strings

* handle this

* missing S3

* Fix and add all missing cars (verified with script

* Supported Package fixes

* add get_tiered_cars

* Check radarOffCan for removing most Honda from op long

* Update for Avalon stop and go update on master

* Fix missing car params

* add my temporary script i'm using to verify new generated DBC

add my temporary script i'm using to verify new generated DBC

* generate with jinja template

* add header and footer

* clean up

* rename

rename

* add exceptions. jinja is nice, but why are its loop indexes starting at 1?

* add list of known car videos

* See how these look

* Add nice table formatting for column description

Add nice table formatting for column description

* generate

* consisten br tag

* small clean up

* temp

* Move car videos into CarInfo

* add new copy and rename to footnotes

* Revert "temp"

This reverts commit 93c3fce1d3ab406f80cbfb9c00c2237d109c7846.

clean up

* generate

* replace with svg

* simplify a bit

* add footnotes to CarInfo

* move some variables to docs.py

* Add video link for Acadia

* Make Footnote an enum so we don't use random ints

* static analysis fixes

* move to CARS.md

* fix last missing footnote

* add to release files

* rm test file

* use svg

generate

* fix sorting

* not needed

* not sure how this got here

* remove Sedan/Couple and add Diesel footnote

* finish todos

* move make specific footnotes to selfdrive/car/*/values.py

rename

* change to zeros

* align bottom to center

* Apply some suggestions

* Update selfdrive/car/mock/values.py

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>

* Update copy

* Try headers + bullet points

* somehow better

somehow better

* finish updating copy

* move template and add links to sups

* stars shouldn't be clickable

that didn't work

try this

try this

this is better

* add type hints to CarInfo

add more type hinting

* optional needs a type and any covers all (?)

* move good steering torque to */values.py

* dataclasses are much nicer than attr

* use tuple

* Update docs/cars.py

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>

* suggestions

* suggestions

* suggestions

remove

* clean up a bit

* add more type hints

* center stars and remove hardcoding from template

* update copy

* Add test

* Fix types

Fix types

* add supported cars documentation test

* clean up

* replace with docs_definitions

* Add back Footnote enums

* Ah so these are like fstrings!

* Update selfdrive/car/CARS_template.md

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>

* Update selfdrive/car/docs.py

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>

* Update year from master merge

* Fix longitudinal star from merge

* sort properly stars by Column enum

* clean up

* HKG: Sorry guys

* Prius V gets FSR star, like others

* Update selfdrive/car/docs.py

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>

* update comment

* No Prius docs change for now

Co-authored-by: Jason Young <46612682+jyoung8607@users.noreply.github.com>
Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
old-commit-hash: 31a6b141d6c37d7241146a9dc7b3a10313abdc40
2022-03-16 21:27:05 -07:00
Adeeb Shihadeh 3327348aeb don't read params in car interfaces (#23978)
old-commit-hash: bae78dd46b817bea26c6de05322eed5cab0bfba8
2022-03-16 15:17:47 -07:00
Adeeb Shihadeh d0b419796f Fix controls mismatch on button enable cars + test against panda safety (#23975)
* test models: check button enable cars against panda safety

* gm too

* cleanup
old-commit-hash: 20db4525a21de0d29adb8938f2a26fc38971451b
2022-03-16 14:54:22 -07:00
Adeeb Shihadeh 6ac01e59cf Honda: fix possible controls mismatch on Nidecs (#23973)
* Honda: fix possible controls mismatch on Nidecs

* bump panda
old-commit-hash: 7deba690e253dbe1191f3227e8240e6842dd9580
2022-03-15 17:55:15 -07:00
Adeeb Shihadeh 94e02bcb3f add parkingBrake to carState (#23968)
* add parkingBrake to carState

* fix gm
old-commit-hash: ae19308e83991c4809a785bb698d300cf7afe7e1
2022-03-14 16:32:20 -07:00
Adeeb Shihadeh 805a00b5f3 cleanup selfdrive/test (#23967)
* move test routes and test_models

* move fingerprints

* little more

* remove that
old-commit-hash: 8718a5933049d5934cc53ef31af9b5ded3223a7c
2022-03-14 15:46:16 -07:00
Ewout ter Hoeven a962365292 Convert format strings strings to f-strings (#23241)
* Convert all text strings to f-strings

Reformats all the text from the old "%-formatted" and .format(...) format to the newer f-string format, as defined in PEP 498. This requires Python 3.6+.

Flynt 0.69 was used to reformat the strings. 120 f-strings were created in 51 files.

F-strings are in general more readable, concise and performant. See also: https://www.python.org/dev/peps/pep-0498/#rationale

* revert pyextra changes

* revert ublox.py

Co-authored-by: Willem Melching <willem.melching@gmail.com>
old-commit-hash: 55390d273f36f49da3896e687ac5530f40c1d150
2021-12-16 14:58:17 +01:00
grekiki 9e4cc1f7ff Python: Replace more lists with generators (#23116)
* Replace lists with generators v2

* Replace set with {}

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>

* Replace more set() with {}

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
old-commit-hash: 6951b3271d1770297cb6bd53878463035ec0bf43
2021-12-03 22:57:19 -08:00
Jason Young 24a9b9248c Update CI tests for CAN fingerprinting deprecation (#21043)
* Start refactor of CI tests for FPv1 deprecation

* Fix test_car_interfaces

* Touch up comment

* Smaller diff
old-commit-hash: 182b00896c7c49dc18ee100fdb3cb7128f1dd5ea
2021-05-26 14:02:42 -07:00
Adeeb Shihadeh 7546f7d084 enforce message checks in can parser (#20742)
* enforce message checks in can parser

* nissan

* vw

* hkg

* subaru

* toyota

* honda bosch

* gm

* honda nidec

* bump opendbc

* not all tss2 have bsm

* toyota fixes

* honda fixes

* vw fix

* fix subaru

* fix long tests

* update refs

* crv bsm
old-commit-hash: 6c7ed8f2e4a3769c12e61be57e802920b84dcc29
2021-04-25 12:52:16 -07:00
Willem Melching ee0e80a6d4 Fuzzy match on ECU FW versions (#20687)
* Fuzzy match on 3+ ECUs

* reuse dict

* exclude some shared ecus to be sure

* show alert for fuzzy match

* use title case

* require community toggle

* refactor

* do both exact and fuzzy in test script

* update test script

* add fuzz test and lower matches to >= 2

* strip alert length

* sort mismatches

* add fw tests to test_startup

* bump cereal
old-commit-hash: e4f73fbda5c2dd07cbb15816ac1bf30b010408fe
2021-04-20 12:00:36 +02:00
Willem Melching 4bd1929d2b LateralPlanner should only compute curvature (#20289)
* get curvature from planner

* no need to check active

* remove that

* remove self

* liveParams not needed

* cast

* fix test bug

* fixes

* fix ui.py

* fix radians

* update refs

* update refs

* bump cereal

* bump cereal

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
old-commit-hash: c23ec9f75389c9ad86400e9a9d23ee6bc5b648a2
2021-03-11 21:08:51 -08:00
Igor b1c6f804e5 Add indi breakpoints (#19664)
* Added BP, V to latcontrol_indi

* hyundai

* toyota

* Tests for INDI outerLoopGain
old-commit-hash: 0a65e87394f071a18cd377ab81391a48729d1fa0
2021-01-07 15:55:46 +01:00
Adeeb Shihadeh 412fb8c2f2 more robust fingerprint test
old-commit-hash: dc371f951ac5e3cbff7d2cec74c56efbe4b3a0c7
2020-12-12 01:19:38 -08:00
Adeeb Shihadeh d84ede9f00 better debug msg for fw fingerprinting test
old-commit-hash: 1e78469fba11b493d021214d086353e9f63a7037
2020-12-12 00:29:14 -08:00
Adeeb Shihadeh f25cec394e grey panda is unsupported (#2458)
old-commit-hash: 47c21f10f598639307994392e96f4d9293b295c7
2020-11-03 19:56:25 -08:00
Adeeb Shihadeh 39d98d3d2d Car cleanup (#1924)
* cleanup car code

* more pruning

* little more

* less pylint disables

* radar stuff

* fix

* udpate refs

* fix honda bosch

* fix test
old-commit-hash: 892e1162c0bfa0970cbe262452a70745eccb8ba6
2020-07-25 15:07:27 -07:00
Adeeb Shihadeh 59b626ba8c test each model fingerprints with FW fingerprinting (#1769)
* test each model fingerprints with FW fingerprinting

* lock

* test for all
old-commit-hash: b44569284a70b07b15daa580922d895a70956c20
2020-06-23 15:33:04 -07:00
Adeeb Shihadeh 521e57e262 test for duplicate ECU firmware versions
old-commit-hash: b5efaef98afb812846a5f1c8df07970a9c73e7be
2020-06-22 22:47:16 -07:00
Adeeb daea932130 Release cleanup (#1649)
* start cleanup

* whitelist submodule release files

* don't need to ship tests

* revert changes to build script

* add those tests back

* fix typo

* whitelist dbcs

* test

* run the right test

* whitelist opendbc/can

* revert that

* add missing dotfiles

* clean up

* ford DBCs

Co-authored-by: Comma Device <device@comma.ai>
old-commit-hash: c24a7e248a295641f58d39e0db25dde1b742fc16
2020-06-08 14:24:14 -07:00
Willem Melching 2ee34128d0 add some sanity checks on returned params
old-commit-hash: 4fcf47812bee79a82919799d9a9b9cac115dea99
2020-05-30 17:15:41 -07:00
Willem Melching 8d4c5fcc7d run carcontrollers multiple times
old-commit-hash: 60431802ba8ff197ae9f92d7b38be7c0d178ed2d
2020-03-24 16:04:42 -07:00
rbiasini 27c9381aa5 Test interfaces also in enabled state and fix a bug (#1213)
old-commit-hash: 6582d632ec58336158147afdcba1172d7455f11e
2020-03-06 23:48:47 -08:00
Willem Melching ac9ecb3e3b also call interface.apply in test
old-commit-hash: e31ebda7a304f9783928edf6b5f4697b86e695f9
2020-03-06 17:02:37 -08:00
Willem Melching 3206cb8ca2 Unneeded tuple
old-commit-hash: ca5185864460c83fd03a8077adf89bf3e9ea729c
2020-03-06 14:06:54 -08:00
Willem Melching 2ab4d10d20 Fix typo in test comment
old-commit-hash: df16d08efbc2a7950b0ec2ea90906534957ce0fc
2020-03-06 14:06:02 -08:00
Willem Melching d7810667e8 Also test radar interface
old-commit-hash: 54ef38d7f614eda7383a4a4059d8f3addf0995ef
2020-03-06 14:02:40 -08:00
Willem Melching 60677729eb Also create a radar interface
old-commit-hash: 86e0202549b3d6eb9965d9149a9cee4517c26159
2020-03-06 13:56:27 -08:00
Willem Melching de8dcf3614 Add test that gets all the car params
old-commit-hash: 16b6c70884f870461cd3fa7d18daf61faa5c25d0
2020-03-06 13:54:32 -08:00
Willem Melching 1dee8638d6 Cache FW query (#1025)
* split fw query and matching

* Read cached firmware versions

* add tests

* this works

old-commit-hash: b7aeb5d64d
2020-01-30 17:57:20 -08:00
George Hotz 9ef085076b selfdrive/car
old-commit-hash: 71ead9adea
2020-01-17 10:58:43 -08:00