Commit Graph

9429 Commits

Author SHA1 Message Date
Shane Smiskol 35a99d7fc6 Common CI._update function (#33289)
* use CP

* no car control, consistent _update function signatures

* eh it's fine to name it whatever

* clean up

* oops

* !!

* now we can delete this!

* nobody does anymore
old-commit-hash: 7248b00086f9b8d5d95c80a2eb7fe89c387f44ea
2024-08-13 22:59:25 -07:00
Shane Smiskol fae517416e card: set mock carState fields (#33294)
* mock carstate inside card

* not used
old-commit-hash: cb61d0045cb38f7fed362a848dcf3646b130d951
2024-08-13 22:48:55 -07:00
Shane Smiskol 9cf575657e Move buttonEvents to CarState (#33292)
* move mazda button events to carstate

* do  more

* remove

* some more

* clean up
old-commit-hash: 9f14c447db234d90a8fafe55d3e7b6439198f19f
2024-08-13 22:30:46 -07:00
Shane Smiskol d26b49a409 Consistent spacing in car interfaces (#33293)
* formatting

* fix these

* not these
old-commit-hash: 29882b4519b00dbcd10f950dcf7c2986aae2fc1c
2024-08-13 22:08:48 -07:00
Shane Smiskol 6ab415bc59 fix static analysis
old-commit-hash: d65e1d9500be32f45ebd19ff939ecbc458fcc5ed
2024-08-13 21:28:06 -07:00
Maxime Desroches c551f1d239 fix bash + python3 shebangs (#33287)
fix shebangs
old-commit-hash: 1dcd66081531f4568a8de69637fc7a3f4ef3214f
2024-08-13 21:22:13 -07:00
Shane Smiskol b97ed10ea1 Car interface clean up (#33290)
* remove some defs

* now carstate

* remove carControl from CI update function

* almost merged that

* and that
old-commit-hash: 65fccbf7563ceca5ec84bb75ceb39556371a74de
2024-08-13 21:16:39 -07:00
Kacper Rączy 80bc61dc6c controlsd: use livePose (#33283)
* Pose calibrator

* Fix static analysis

* Fix static

* Fix test_latcontrol

* Fix test_latcontrol

* Update services in process replay

* Fix static

* Matmul not mul

* Add assertion

* Move pose calibration to data_sample

* Update ref commit

* Remove llk from cycle alerts

* Deprecated nogps event

* Switch power_draw to lp

* Bring back noGps alert

* Add handling code back

* get_bool

* Bring inputsok back
old-commit-hash: 9734015bbb6d448bb6b0fb453370ec702fa73106
2024-08-13 21:11:16 -07:00
Shane Smiskol e46d96bb11 Move events out of car interfaces (#33280)
* chrysler down

* honda and ford

* we can pass the class for this

* do the rest

* clean that up

* remove EventName

* fix CI

* move smallest bodies to top

* rm todo

* eps_timer_soft_disable_alert is too ingrained in carcontroller

* re-did everything w/ no diff (except just passing cereal instead of class)
old-commit-hash: cf39cc823ad5aea33af6d51214ffb14bc51ec6c4
2024-08-13 20:40:36 -07:00
Shane Smiskol 6a15aa3f8c interfaces: assume CarState is instantiated (#33284)
test to make sure mock doesn't crash!
old-commit-hash: 3d2fbe9aa3403e635d476fba9c8232b741e54cce
2024-08-13 19:36:21 -07:00
Shane Smiskol 7b4a538eaa fix fingerprint debug scripts (#33277)
* fix fp debugging

* fix these
old-commit-hash: 90ce7781f4caf0d0469d8897259612e4117e3a48
2024-08-12 15:41:08 -07:00
Shane Smiskol 7a4b2b5c44 [bot] Fingerprints: add missing FW versions from new users (#33276)
Export fingerprints
old-commit-hash: 4618e8c12403bd1d716cf6ac224f5a0dc4960722
2024-08-12 12:41:14 -07:00
Shane Smiskol 11c9105a60 carState: add invalid sensors field (#33266)
* add to CS

* add vehicleSensorsInvalid to CarState

* fix ord

* clean up
old-commit-hash: 7ec998634097f062afe8fb584e34e4c8a1d9fb54
2024-08-11 23:12:42 -07:00
Shane Smiskol 988d16a4c8 remove map from ui preview (#33265)
* rm map from ui preview

* fix
old-commit-hash: 4e122ed2d11785010377e023c979b258e622acb1
2024-08-11 21:54:40 -07:00
Shane Smiskol d18a0868c6 move the body events to card (#33262)
* move the body events to card

* rm import
old-commit-hash: 093c09a7373868a77d8f9e56f7f26304601855dc
2024-08-11 20:25:08 -07:00
Shane Smiskol e4cdccb7fd Revert "spinner: fix missing colon in QProgressBar border style" (#33263)
Revert "spinner: fix missing colon in QProgressBar border style (#33258)"

This reverts commit 3ba8a152cc8326306640c7acf307ceb385f7a4e8.
old-commit-hash: d33035872894ec06d0ededafd512132928edf207
2024-08-11 20:24:43 -07:00
Shane Smiskol b014b1cc90 Fix some car typing (#33256)
* ??

* fix these

* more typing and some fixes

* fix

* rm this for now

* fix
old-commit-hash: 2dab8b31f20503b2eaf0d11302da31759d9867e2
2024-08-11 19:12:46 -07:00
Dean Lee 056426a674 spinner: fix missing colon in QProgressBar border style (#33258)
fix border style
old-commit-hash: 85d8d0eddd91baabb6bbef59a9d1f8463b70dc90
2024-08-11 10:22:52 -07:00
Shane Smiskol 162436088f move capnp CarParams decoding out of car_helpers (#33251)
* move capnp byte decoding out of car_helpers

* always wanted to type this

* and process replay

* this does nothing

* might as well
old-commit-hash: ee62b9c88baf4a53f6db88381da2b8052c3fab17
2024-08-10 00:06:56 -07:00
Shane Smiskol 7dd22b9567 Honda: round minEnableSpeed correctly (#33250)
round to even
old-commit-hash: 4300f37cc4b6bd405391815afc5c6b2c740e7e43
2024-08-09 23:42:40 -07:00
Hoang Bui 025395ca43 tools/sim: resolve import error on MacOS running Metadrive (#33244)
fix dynamic lib linking on mac
old-commit-hash: c06d975ec4fbb8912cb5b78c5158738ea57cb271
2024-08-09 23:12:40 -07:00
Dean Lee fcba77b59e pandad: move getenv check to global scope (#33235)
move getenv check to global
old-commit-hash: ad33cae40e03a99c4029f567dc3b67baef340450
2024-08-08 08:45:03 -07:00
Shane Smiskol a7db075f08 selfdrive/car: generic CAN send/receive callbacks (#33215)
* start

* hmm API doesn't seem great

* better

* rm line

* sendcan -> can_send callable for best static type coverage, list -> tuple msg

TODO: logcan

* more sendcan -> can_send references

* remove pandad's capnp from selfdrive/car

* fix and remove cereal from test_can_fingerprint

* test_fw_fingerprint: remove pandad, less cereal

* comment done too

* better comment

* fix test_models test

* niceeee it works

* move to can_definitions

* can't come up with a better name :(

* I think we can remove SimpleNamespace soon

* fix test_can_fingerprint.py

* maintain previous behavior

* Revert "maintain previous behavior"

This reverts commit f848fd32132391692c6191a305bb38f74091ec91.

* can test comment

* no need for get_one_can now!

* big clean up: no SimpleNamespace

* now self explanatory!

* not needed

* use empty can again since this is now real

* cmt
old-commit-hash: 9880b1393c7bfc2b71aec01b6b91caffb72f9cc0
2024-08-07 23:49:25 -07:00
Shane Smiskol 8131716c9e CAN fingerprinting: count empty CAN packets as frames (#33232)
* content of can packet won't affect can fingerprint time

* remove get_one_can

* fix comment

* actually we still want to be able to send empty can (xx fingerprint func does this if it runs out of msgs)

* fix process replay
old-commit-hash: 87f183f43cccdb07f6fb9d0947f4ada2d806e294
2024-08-07 23:12:47 -07:00
Shane Smiskol c1084b3df3 selfdrive/car: rm make_can_msg (#33231)
* rm make_can_msg

* fix
old-commit-hash: bd4f0cec18d7f22f16d906de5c3b0f97ae1450ae
2024-08-07 21:58:16 -07:00
Shane Smiskol 7f4f1d4c5f make_can_msg: returns tuple (#33222)
* bump

* make_man_msg returns tuple

* fix CI.update typing

* bump

* better name

* Revert "better name"

This reverts commit 4deb38d4ed99e43721960f69da1dd46a1069eb42.

* common
old-commit-hash: 51bd3682148ce7a00ac76281d76c278716a1c24a
2024-08-07 16:12:00 -07:00
Shane Smiskol 54d10c2aa3 remove CAN capnp conversion from car interfaces (#33218)
remove pandad from interfaces
old-commit-hash: ba7a60c5a20c5f252bc89ba3e2559edf5ab65c59
2024-08-07 00:05:32 -07:00
Shane Smiskol d8f56b30b5 selfdrive/car: ban common (#33210)
* ban all of common & copy numpy_fast

* add numpy_fast

* these are okay

* and ban controls

* better name

* Conversions

* do utils, kalman

* clean up

* sorting

* don't forget
old-commit-hash: 8d961a12e5b033855f2abf5d8bd9c51374f74c6e
2024-08-06 20:45:11 -07:00
Dean Lee 04b0871c45 pandad: refactor to consolidate threads, keep only one can_send thread (#32680)
* single thread

improve comment

* Keep can_send() running in a separate thread

* send send_peripheral_state in pandad_run

* new PandaSafety class
old-commit-hash: a4de8739e97b4d5d4b1f2fe2f6739ed90338dead
2024-08-06 20:04:17 -07:00
Dean Lee 7003776265 pandad: assemble capnp message using separate functions (#33189)
Assemble capnp message using separate functions
old-commit-hash: fb560e81ef8c0de16234f96831164d8b987eaf18
2024-08-06 17:27:02 -07:00
Shane Smiskol 2c49f6b20d selfdrive/car: ban selfdrive/controls (#33211)
ban controls (VM isn't used anymore)
old-commit-hash: 6c837332ea9ae854caf4f7747d3ef84101cd93c6
2024-08-06 16:36:38 -07:00
Comma Device 41c9dd38eb tici: update spinner and text
old-commit-hash: 33bf4bbb13ee7fbaebe8a4efe500b75ebdcf86f7
2024-08-06 11:51:17 -07:00
Shane Smiskol c0f721180f get_car: returns just CI (#33204)
just return CI
old-commit-hash: d00a53983089be6bed0e037474abfea823f2fc3e
2024-08-06 00:30:25 -07:00
Shane Smiskol 1a74993ee2 selfdrive/car: ban params (#33198)
* ban params too with a callback

* all sorts of messed up

* use cloudlog

* consistent order

* order

* better type hint

* format

* this is a bit nicer

* hmm

* fix PLR1704

* no carvin

* fix process replay
old-commit-hash: 5a1596a32299d6f78d89c89469ab6893b8d5e083
2024-08-06 00:10:53 -07:00
Shane Smiskol 59b2f1f511 fingerprinted: log platform string
This does get safely converted to a string in the logs, but in the console it's the repr
old-commit-hash: d1140cc6440c9dba795743dd0f0b82915879fbb7
2024-08-06 00:08:39 -07:00
Shane Smiskol a1c2971f13 selfdrive/car: OBD callback (#33200)
* finish

* pass empty cb

* last fix!

* i keep messing this up

* even more coverage!

* not needed
old-commit-hash: 86aeb123bcdac9544db046a2db7e2974b5a687e1
2024-08-05 23:30:52 -07:00
Shane Smiskol 3df0a1ebbf remove CarVin parameter
old-commit-hash: 87c6afccf71788ba58685f43d967290816d4dfbf
2024-08-05 22:31:04 -07:00
Shane Smiskol 9e4a7484be remove unnecessary debugging function from car_helpers.py (#33199)
* format

* better better

* huh
old-commit-hash: 5c1e111d8a8476a2bddaeee29fcaca1c2c38f609
2024-08-05 21:27:43 -07:00
Shane Smiskol c45e72dd2f remove more car import exceptions (#33193)
* remove another exception (remove mention of events from car stack)

* guess this should've been here all along

* reorganize exceptions

* fix
old-commit-hash: 06216d43bbd0926cfd89c91c43cfc0cf9247c324
2024-08-05 17:27:28 -07:00
Adeeb Shihadeh fc469e5f80 Revert "Remove setproctitle (#32716)" (#33195)
* Revert "Remove `setproctitle` (#32716)"

This reverts commit 9020d1931f4cd72f8162e4402278bdf76e3746f2.

* uv lock

* old name
old-commit-hash: 29b58d4f2fcc982d5c06ed8391e368b1b293a96c
2024-08-05 16:42:22 -07:00
Maxime Desroches df13b36638 fix all codespell issues (#33194)
* bring back

* remove 2020 dictionary
old-commit-hash: 44c7144e1c5f5aa66596c8d240b64827148b960d
2024-08-05 15:25:02 -07:00
Shane Smiskol 550178261a [bot] Fingerprints: add missing FW versions from new users (#33191)
Export fingerprints
old-commit-hash: 7a7200cbdadba2c33d9c561a90259e7f458bfc1b
2024-08-05 13:29:14 -07:00
Shane Smiskol cfc2cda37c separate car logger forwarded to cloudlog (#33170)
* car logger

* try this

* fix double printing!

* clean up

* need to import where we actually use it (card won't be in submodule)

* NullHandler does not forward everything properly, need propagate=False to stop root logger from printing

* card is staying

* set up

* forward
old-commit-hash: 12a7b7f7fb1d3a275314b0232795942a7ff3b955
2024-08-05 12:31:31 -07:00
Dean Lee 74a9e64c2c modeld: remove redundant pred_mu assignment (#33152)
remove redundant pred_mu assignment
old-commit-hash: 2cd9975e4fe31bf89cdbf41d3d5db02f519a2718
2024-08-02 13:40:33 -07:00
Shane Smiskol be710ab893 ensure alerts_generated.h is built (#33157)
don't build alerts_generated.h in test, and ensure scons builds it more reliably + clean up support
old-commit-hash: 7de618a5cf38a759d3986d775f7d7f7a35167050
2024-07-31 16:12:37 -07:00
Shane Smiskol 799fabd707 Reapply "update to new opendbc API (#32009)" (#33151)
This reverts commit f2f01e3afaeaa267af61c8d7ab918da04d3411f2.
old-commit-hash: 7c112341c358b57ee9d0209cb2b2c53383adcca9
2024-07-31 15:37:39 -07:00
Shane Smiskol 0ea25665bb get_fw_versions: test the full stack (#33156)
* add the test

fix

* bump

* not sure why mypy didn't catch this
old-commit-hash: ebff7cab1ab897526800e229e30b01ec4cf1114c
2024-07-31 14:53:13 -07:00
Maxime Desroches 80e23d1593 Remove hexdump package (#33155)
* remove hexdump

* uv lock

* cleanup
old-commit-hash: 1dd8bdc7912bef693c112816a5ac5066b036337b
2024-07-31 13:34:14 -07:00
Shane Smiskol 2c11e7b49a Revert "update to new opendbc API (#32009)"
This reverts commit d21755b2e216c3f547db0b55b7088357c4368801.

old-commit-hash: ac130001cc83734118524f59a83a96a2065dd56e
2024-07-31 02:38:44 -07:00
Dean Lee 2f1ee6e832 update to new opendbc API (#32009)
* use new opendbc api

* export pandad_python

* merge master

* merge master

* bump opendbc

* bump opendbc

* improve func

* keep interface unchanged

* fix test_car_interfaces

* bump opendbc

* bump opendbc

* fix test_models

* the interface now has to convert from can capnp to list, so we should include this time

* goes from ~210 to ~240 mean ms real time

* remoe busTime

* lowercase sendcan

* consistent msgtype

* bump

* bump

* not used in lat_mpc

* space

* bump to master

---------

Co-authored-by: Shane Smiskol <shane@smiskol.com>
old-commit-hash: 0dddc97dca8bf4e023b29c35cb92fd3dd0a9a3a2
2024-07-31 00:24:46 -07:00