Commit Graph

832 Commits

Author SHA1 Message Date
Shane Smiskol
ab44c9a4ff Torque controller: refactor calculations to be in accel space (#35790)
* clean up

* little confusing but works

* clean up

* fix

* pid outputs torque again, fix windup above max torque

* clean up

* fix

* fix

* typo

* fix conflicts

* fix PID

* cleanups

* seems correct

* updte

* inverse

* whitespace

* move

* small cleanup

* more cleanup

* update ref

---------

Co-authored-by: Bruce Wayne <harald.the.engineer@gmail.com>
2025-08-15 11:39:56 -07:00
Adeeb Shihadeh
5417efaa1d bump opendbc (#36001) 2025-08-15 11:12:18 -07:00
Harald Schäfer
455a6a586a Misc PID refactors (#35844)
* Misc PID refactors

* dead

* finish rename

* unused import

* whitespace

* typo

* fix fan controller

* pid_log

* whitespace

* integral clipping in pid

* update ref

* cleaner

* rm print

* update ref

* revert fan changes

* forgot this
2025-08-11 14:25:29 -07:00
Mitchell Goff
7413982f0d Lower ALLOW_THROTTLE_THRESHOLD (#35928)
* Lower ALLOW_THROTTLE_THRESHOLD

* Bumped process_replay refs
2025-08-05 17:35:54 -07:00
DevTekVE
9dc98b36be refactor: cleanup gravity constant handling (#35866)
* refactor: move lateral methods from init to lateral.py (#2594)

* Extracting lateral methods to lateral.py

* cleaning

* more cleaning

* more cleaning

* Making sure it remains where it should

* Leave rate_limit where it belongs

* Moving things to `car/controls/`

* Moving rate limit to get a taste of the changes

* clean

* copy verbatim

* clean up

* more

* now we can format

---------

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

* No need to change order of import

* refactor: consolidate ACCELERATION_DUE_TO_GRAVITY import path

* bump opendbc

* update refs

* don't import from opendbc

---------

Co-authored-by: Shane Smiskol <shane@smiskol.com>
Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
2025-08-02 11:20:18 -07:00
Adeeb Shihadeh
4d01b7bec8 Fix up radarFault handling (#35880)
* fixup radarFault handling

* catch all

---------

Co-authored-by: Comma Device <device@comma.ai>
2025-08-01 16:27:26 -07:00
commaci-public
3e2325a632 [bot] Update Python packages (#35845)
* Update Python packages

* bump

* update refs

---------

Co-authored-by: Vehicle Researcher <user@comma.ai>
Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
2025-07-29 19:45:17 -07:00
Adeeb Shihadeh
b99c73e1fa bump opendbc (#35813)
* bump opendbc

* update tests
2025-07-25 12:50:15 -07:00
Shane Smiskol
09d8327a14 bump opendbc (#35811)
* bump

* bump

* bump

* update refs
2025-07-24 23:56:04 -07:00
Adeeb Shihadeh
347cee4b09 big opendbc bump (#35799)
* bump

* bump

* bump

* bump

* bump

* update refs

* that doesn't work anymore

* bump

* update refs

* bump
2025-07-23 23:23:59 -07:00
Adeeb Shihadeh
dc1219d13f bump opendbc (#35795)
* bump opendbc

* update refs
2025-07-22 20:19:09 -07:00
commaci-public
a931ed5c15 bump opendbc (#35789)
* Update Python packages

* bump

* update refs:

---------

Co-authored-by: Vehicle Researcher <user@comma.ai>
Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
2025-07-22 11:35:18 -07:00
Shane Smiskol
4b73f3b169 bump opendbc (#35782)
* bump

* bump

* bump

* bump

* update refs
2025-07-21 20:16:36 -07:00
commaci-public
3a2c4a855a [bot] Update Python packages (#35726)
* Update Python packages

* dep

* ref

* hint

---------

Co-authored-by: Vehicle Researcher <user@comma.ai>
Co-authored-by: Maxime Desroches <desroches.maxime@gmail.com>
2025-07-14 13:48:55 -07:00
commaci-public
9deac8c800 [bot] Update Python packages (#35669)
* Update Python packages

* update refs

---------

Co-authored-by: Vehicle Researcher <user@comma.ai>
Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
2025-07-11 19:59:03 -07:00
Armand du Parc Locmaria
9bd7e3e36d bump opendbc (#35685)
* bump opendbc

* bump less

* bump more

* update refs
2025-07-10 19:40:54 -07:00
Bruce Wayne
9aed28a216 bump opendbc 2025-07-08 14:07:16 -07:00
Harald Schäfer
5b70c78902 bump opendbc (#35649)
* bump opendbc

* update ref
2025-07-07 18:40:06 -07:00
Harald Schäfer
a5630eb7b7 Bump opendbc
* bronco special

* ignore low speed

* fixes

* update ref

* bump

* update ref
2025-07-02 21:25:08 -07:00
Harald Schäfer
713c02cc3f Torque control: more integrator (#35610)
* Torque control: more integrator

* bump opendbc

* update ref
2025-06-27 22:28:59 -07:00
Maxime Desroches
5772683432 ci: faster process replay (#35578)
* waste

* update

* again

* we love tesla

* again again
2025-06-19 11:00:41 -07:00
Shane Smiskol
bfa3f3cccb Add calPerc progress tracking for torque calibration (#35512)
* Add calPerc field and torque progress

* Fix torqued test style and CarParams usage

* test: remove unused numpy import

* move here

* trying all combinations to see what's most linear

* clean up with best method

* no no

* epic

* clean up

* last min not needed

* doesn't hurt

* list comp
2025-06-10 00:22:13 -07:00
Shane Smiskol
c24f349807 GM: low steer speed alert in CarState (#35332)
* simple

* rm

* bump to master

* update refs

* update refs
2025-05-23 19:43:17 -07:00
Kacper Rączy
97ad175243 Reapply "Enable online lag learning (#34968)" (#35327)
* Revert "Revert "Enable online lag learning (#34968)" (#35322)"

This reverts commit 9c40c48729.

* Update ref commit

* Update ref

* Update ref commit
2025-05-24 02:31:17 +00:00
Shane Smiskol
9622427044 car interfaces: improve steering pressed signal (#35333)
* bump

* update refs
2025-05-23 16:32:19 -07:00
Shane Smiskol
9b642ed016 bump opendbc (#35323)
* bump

* update refs
2025-05-22 17:49:27 -07:00
Kacper Rączy
9c40c48729 Revert "Enable online lag learning (#34968)" (#35322)
* Revert "Enable online lag learning (#34968)"

* Update ref commit
2025-05-22 01:55:19 +00:00
Shane Smiskol
e8fd8e6018 bump opendbc 2025-05-18 01:20:28 -07:00
Shane Smiskol
a6a09276e9 Hyundai: fix recent enable button press regression (#35265)
* move back to port

* much better

* use the CS field now

* bump

* fix

* need to switch so it works on ports that don't use it, and makes more sense

* bump

* bump

* update refs

* make sense

* master
2025-05-18 00:52:02 -07:00
Shane Smiskol
33721cf5fa Lower Tesla steer limit timer (#35268)
* bump

* update refs
2025-05-18 00:38:57 -07:00
Shane Smiskol
66c0971a0f migration: remove disengage on gas alternative experience (#35267)
* fix

* done

* test

* update refs
2025-05-17 23:56:21 -07:00
Shane Smiskol
5d8c8ae911 Tesla: raised lateral limits (#35231)
* bump

* bump

* update refs
2025-05-14 19:51:12 -07:00
Adeeb Shihadeh
313ede3d1e Update NDOG live (#35205)
* no alt exp

* live

* fix

* update res
2025-05-13 14:48:40 -07:00
Shane Smiskol
8473774b65 process replay: add Tesla route (#35199)
* add tesla

* update refs

* run tesla on more procs

* update refs
2025-05-12 21:18:51 -07:00
Harald Schäfer
e9cea3ae5c Revert TR again (#35179)
Revert "Tomb Raider 7 (#35114)"

This reverts commit 0fb4aafa35.
2025-05-11 08:24:46 -07:00
Harald Schäfer
0fb4aafa35 Tomb Raider 7 (#35114)
* Revert "Revert TR (#35110)"

This reverts commit df4f2955dc.

* eb5f884a-10ad-49fd-ae5c-e2818c26e568/400

* 1cc828ab-95e5-4620-aa07-b98918b4268d/400

* 5790a2c1-b487-4bef-a3c3-db1fcd5a756d/400

* raw plan
2025-05-07 18:06:41 -07:00
Harald Schäfer
df4f2955dc Revert TR (#35110)
* Revert "Tomb raider 2 (#35029)"

This reverts commit 2c162d9b75.

* bugfix

* fix policy

* min control speed
2025-05-02 20:54:42 -07:00
Kacper Rączy
45b273328d Enable online lag learning (#34968)
* Use in modeld

* Use in torqued

* Do not use default value in torqued

* Add liveDelay in process replay

* update ref

---------

Co-authored-by: Bruce Wayne <harald.the.engineer@gmail.com>
2025-05-01 11:42:49 -07:00
Jason Young
37839ea0c5 controls: publish current curvature in CarControl (#34679)
* controls: publish current curvature in CarControl

* clean up

* update refs

---------

Co-authored-by: Shane Smiskol <shane@smiskol.com>
2025-04-25 13:57:18 -07:00
Harald Schäfer
34514ef176 Long planner: make work with training (#35043)
* revert useless

* update ref
2025-04-21 14:11:57 -07:00
Harald Schäfer
2c162d9b75 Tomb raider 2 (#35029)
* db56b8fb-9135-4ab6-af18-99b7df7b2245/400

* fixes

* linter unhappy

* 6dbe0991-baa1-49ad-836a-ab370d1f0d92/400

* This one is good: 19387087-1005-475e-9015-9458dd8e7c5f/400

* Better every day: 39ed911c-0937-417f-97d2-58a8bb3caa53/400

* Actually end-to-end

* typo

* smooooooth: 94e23541-eb84-4fef-9f51-6a2d82aff314/360

* Revert "smooooooth: 94e23541-eb84-4fef-9f51-6a2d82aff314/360"

This reverts commit edd4f02386d83d82dd8a188985cde80ed1646b7f.

* 11632ef7-f555-489c-8480-e3bf97d9285e/400

* 08712d27-f6bd-4536-a30e-c729e5f62356/400

* 0a92a35e-1f72-476a-8cb6-c9f103f36822/400

* ee6d2394-2072-420c-a664-b4c0d4ed0b61/400

* no prev curv

* No double work

* fix bug

* smooth

* update prev action

* whitespace

* add little accel

* new ref

* Update plant.py
2025-04-17 23:21:25 -07:00
commaci-public
b0915db50a [bot] Update Python packages (#35012)
* Update Python packages

* update refs

---------

Co-authored-by: Vehicle Researcher <user@comma.ai>
Co-authored-by: Shane Smiskol <shane@smiskol.com>
2025-04-11 14:55:12 -07:00
Kacper Rączy
f237649a7a Reapply "Online lateral lag learning" (#34975)
* Online lateral lag learning (#34974)

This reverts commit b4cc9e68d1.

* pad to the best size for fft

* Fix static analysis

* Add typing

* Fix typing

* MAX_LAG

* Calculate cross correlation regardless if the points are valid

* Back to lagd

* Add lagd to process_config

* Lagd in test onroad

* Move lag estimator for lagd

* Remove duplicate entry from test_onroad

* Update process replay

* pre-fill the data

* Update cpu usage

* 25sec window

* Change the meaning of lateralDelayEstimate

* No newline

* Fix typing

* Prefill

* Update ref commit

* Add a unit test

* Fix static issues

* Time limit

* Or timeout

* Use mocker

* Update estimate every time

* empty test

* DT const

* enable RIVIAN again

* Update ref commit

* Update that again

* Improve the tests

* Fix static

* Add masking test

* Increase timeout

* Add liveDelay to selfdrived

* Add liveDelay to selfdrived in process_replay

* Fix block_avg restore after num_blocks

* regen most

* Update bolt

* Update ref commit

* Change the key name

* Add assert

* True weighted average
2025-04-09 22:31:07 +00:00
Kacper Rączy
0b72ae3bc2 process_replay: fix GM and replace TOYOTA3 (#34996)
* Add volt and bolt param migration

* Remove mazda due to invalid sensor timings

* Fix the import

* Add mazda to excluded

* Bring back mazda, but add todo

* New segment for TOYOTA3

* Fix

* Update ref commit
2025-04-09 03:12:52 +00:00
Kacper Rączy
b4cc9e68d1 Revert "Online lateral lag learning" (#34974)
Revert "Online lateral lag learning (#34531)"

This reverts commit 1034dbd37c.
2025-04-01 21:44:30 +00:00
Kacper Rączy
1034dbd37c Online lateral lag learning (#34531)
* Add struct and services

* Proof of concept

* Use vego

* Process replay support

* Fix issues

* Max not min

* Remove print

* Make lag positive

* Points and updates

* Sliding cross corr

* Stuff

* Remove redundant param

* Move to lagd

* Update alert

* Something that works

* Report isEstimated

* Corr field

* Use skimage masked corr

* Fixes

* Move to lat_accel_loc

* Use the delay it in the model

* Mark as executable

* Add 0.2 to initial

* add install line

* Back to 5m window

* Move the import up

* corr window 120

* Show is estimated

* Sort messages

* New impl

* Fix

* Params

* Set initial_lag elsewhere

* Add param

* Rename Param

* Fix type isues

* More blocks

* Masked fft NCC implementation

* Remove package installation

* Use 20hz data and interp the correlation peak

* Move ncc code to separate function

* steering_saturated support

* Constants

* Add recovery buffer

* Fix static

* min_valid_block_count nad liveDelay

* lateralDelayEstimate

* Fix comm issues. Do estimations at 4hz

* Fix

* Display the estimate

* Increase the block size

* Cache every minute

* DEBUG flag

* Add progress to the alert

* Fix crash

* points only in debug

* Fix BlockAverage restoration

* Comment

* Move estimators into estimator directory

* Remove lagd

* Feed only relevant messages

* Rewrite as a set literal

* np.diag with P_initial

* Fix static

* Struct renames

* Update ref commit

* Make it nicer

* Some renames
2025-04-01 04:02:02 +00:00
Kacper Rączy
75cc300480 paramsd: refactor VehicleParamsLearner (#34955)
* Refactor ParamsLearner

* Make it VehicleParamsLearner

* Fix

* Use capnp serialization instead of json

* Fix speed

* Remove redundant comments

* Monitor observed_roll

* Just use init_state

* Comment

* Improve reset

* Set globals api

* Typing for return value

* Redo reset messaging

* Remove usages of math

* Fix process_replay custom_params

* Type ignores for rednose fields

* Remove import

* Reset previous values too

* Update ref_commit

* Revert it

* Bring it back

* Remove more

* Add migration for cached params
2025-03-31 20:07:39 +00:00
Shane Smiskol
a2859090d8 controls: reset desired curvature while disabled (#34943)
* reset curvature while disabled

* comment

* duplicate line

* fix possible iso violation because it was unlimited while disengaged

* rename so you can't accidentally use

* update refs
2025-03-26 22:41:26 -07:00
Adeeb Shihadeh
ea4554526e Keep steering active at standstill (#34918)
* Keep steering active at standstill

* bump opendbc

* bump opendbc

* update refs
2025-03-25 14:00:24 -07:00
Shane Smiskol
5c6c438bcb Rivian: adjust lateral actuator delay (#34913)
* bump

* update refs
2025-03-20 18:22:12 -07:00