Commit Graph

322 Commits

Author SHA1 Message Date
Adeeb Shihadeh 3c48bc47b7 Move a bunch of stuff to system/ part 3 (#24829)
* move swaglog.py

* timezoned

* logmessaged

* version.py

* fix linter
old-commit-hash: 0fce5d90459b77bf2cfa70f55f322f0e1fb8d01c
2022-06-11 23:19:27 -07:00
Gijs Koning 735a7770dc LaikaD: Fix offline handling (#24781)
* Test handling no internet correctly.

* Clean

* Comment

* remove del
old-commit-hash: a9bdc792a184d191824d2ec089658eb3a96f1e45
2022-06-08 07:33:05 -07:00
Gijs Koning 8bbdb79626 Laikad: kill process correctly. Fixes CI (#24780)
Kill process correctly
old-commit-hash: 45c43f9c8719efc300a0cb373f1dc57e0abe3ece
2022-06-08 03:32:22 -07:00
Gijs Koning 2fabc9d509 Laikad: Use process for parsing orbits (#24769)
* Use Process instead of Thread to fetch orbits

* small refactor

* Cleanup
old-commit-hash: e7234e22b4d11cc8f349d02855df9b3414096c0d
2022-06-07 20:55:39 +02:00
Gijs Koning 7bf243b61e Laikad: cleanup fetching orbits (#24759)
* Seperate prediction orbits from regular observation orbits and download them efficient

* Cleanup

* clean and update laika

* Fix test

* Fix test

* Fix checking pos fix

* space
old-commit-hash: 8d8055f00f11fcdf0a8a235de5218d9c2fd2f5ad
2022-06-07 03:25:58 -07:00
Gijs Koning 9771eebb62 Laikad: Fetch orbit data in thread (#24654)
* Add fetching orbits thread

* Use ephemeris type enum. Send list of std floats.
Speed up parsing orbit data by skipping redundant old data

* Remove Glonass from supported constellation for now

* Fix latest time msg

* Add small laika update

* Fix
old-commit-hash: 7df54792d8c04d842d44536723edb7b8370c47a1
2022-06-04 09:25:20 +02:00
Gijs Koning 22e1157a5a Fix test_laikad in master (#24734)
* Use Livelocationkalman measurement struct

* Revert laika repo and fix time gap
old-commit-hash: ad04585c35afdc885ca3c24c066e5801c25d2bc7
2022-06-03 03:12:31 -07:00
Gijs Koning 6a53db981b Simulator: Speed up process by removing second camera (#24679)
* simulator: support running wide camera only

* proper frame id

* use param name that makes more sense

* do some cleanup

* Update tools/sim/bridge.py

Co-authored-by: Willem Melching <willem.melching@gmail.com>
old-commit-hash: b5aed2bf6781cd4d74d28f6f44d24737ec08f0db
2022-05-30 15:25:07 +02:00
Gijs Koning 807803afbe Remove scipy usage from laikad (#24652)
Remove scipy
old-commit-hash: 65056b77c22334b4be727151732bf2a76f9b780d
2022-05-25 17:15:22 +02:00
Gijs Koning 8976820211 Add ephemeris parsing to laikad (#24642)
* Always send valid messages

* Use ephemeris and move astrodog in laikad

* improve test

* Always correct measurements

* Cleanup

* Fix test

* Update laika
old-commit-hash: a51aaaf1970fa864a8a2de7c59abd1db277c123a
2022-05-25 06:26:58 -07:00
Shane Smiskol cb11e4b43b SubMaster: support for polling in C++ (#24602)
* poll when sm.update isn't 0

* bump cereal

* poll modelV2 in UI

* fix driverview

* need to update here

* empty list means poll all

revert

* Revert "poll modelV2 in UI"

This reverts commit 82aac96a1ffc64eb79b07817451b76e6924a9812.

* Revert "fix driverview"

This reverts commit 074ee10f177cf7c99f8201a85904e01d40adbe6d.

* poll all
old-commit-hash: e6da217813ecc58bedd3f92d1c905e13409ea79a
2022-05-20 15:00:28 -07:00
Gijs Koning e72a8d9330 Add gnss kalman filter to laikad (#24578)
* Add gnss kalman filter to laikad

* Fix analysis

* Fix analysis

* Update laika

* Refactor a bit

* cleanup, improve unit test

* Also commit test

* fix

* Always return messages. Use Measurement struct that contains std and valid keys

* Push cereal

* Change prints to cloudlog

* Always send valid messages

* Only send gnssMeasurement msg when measurementReport type
old-commit-hash: ef97329c0e825d477577bf27cbaf772753f077ca
2022-05-20 03:21:17 -07:00
Adeeb Shihadeh f4675fc260 Merge common/ and selfdrive/common (#24556)
* Merge common/ and selfdrive/common

* fix that

* fix version

* fix unit tests
old-commit-hash: cb8885cffb313bea258c012c3026461a22bf8135
2022-05-18 14:11:57 -07:00
Dylan Herman 2dfba97175 add mypy check for return-any (#24379)
* add mypy check for return-any

* remove unused import

* typing

* remove unnecessary variable typing

* cleanup

* cleanup

* bump submodules

* small fixes

* only a problem on mac

Co-authored-by: Willem Melching <willem.melching@gmail.com>
old-commit-hash: d2eef1955c777ef6110c7a74d2a9ca9e4e1d958c
2022-05-12 14:59:00 +02:00
grekiki 7cd23af9b1 Mypy fixes for --check-untyped-defs (#24372)
more type fixes
old-commit-hash: 17e33978cdd9322918e9d5d388f7fa47aa30e9b7
2022-05-12 14:08:11 +02:00
Gijs Koning d849330ca1 Bump laika (#24454)
* Fix after laika repo changes

* Update laika
old-commit-hash: f7c2eefad9897830bf7bce290dec1dfc7d97e1d2
2022-05-09 04:05:08 -07:00
Gijs Koning 0010b565f5 Test gnssUblox message processing (#24404)
* Add simple test for processing ublox messages

* Add simple test for processing ublox messages

* Update selfdrive/locationd/test/test_ublox_processing.py

Co-authored-by: Willem Melching <willem.melching@gmail.com>

* Update

* Push laika ref

Co-authored-by: Willem Melching <willem.melching@gmail.com>
old-commit-hash: e6f9f12d1c9faae8f718306bcd2862278a083351
2022-05-06 06:44:38 -07:00
Gijs Koning c082f26d63 Laikad: the basics for ublox msg processing (#24359)
* Add laikad that receives ublox messages and publishes corrected measurements and position fix

* types

* cleanup

* laikad version 1 with uncorrected measurements

* push

* Fix glonass frequency and delete redundant test

* Update after cereal and cleanup

* Add test, fix laikad and remove process replay for now

* update laika

* add hatanaka to packages. Used to decompress orbit data

* Fix pip
old-commit-hash: b64fe6e339c8b8b3f5016a9c58b553c91abc5bdf
2022-05-06 04:41:14 -07:00
Adeeb Shihadeh 9b9d332a54 paramsd: fix variable cpu usage (#24281)
* paramsd: fix variable cpu usage

* fix that

* increase that a bit
old-commit-hash: f7c2b8b46e87f9f32eaeb5a11d20d3df24fe96e4
2022-04-20 14:08:52 -07:00
Adeeb Shihadeh b57808e650 paramsd: use real logMonoTime (#24279)
old-commit-hash: 4c9020863f156e98702adf073a018b3ca71f4dbe
2022-04-20 13:57:15 -07:00
HaraldSchafer 6bd1706b52 Offline localizer: accept addition camera (#24266)
* Offline localizer: add option for additional camera

* add names

* fix some bugs

* Wide ORB features are less accurate

* add comment
old-commit-hash: a762567de9de52aa6e98818b44a140de6123e6fc
2022-04-19 22:45:35 -07:00
HaraldSchafer b0444b39d2 Body cleanup + 100Hz locationd (#24168)
* use PID

* 100hz on the branch

* Better defaults

* fix int clip

* More cleanup

* Fix pid comments

* only notcar gets 100hz

* cleanup

* fix tests

* ignore

* update refs

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
old-commit-hash: f54e724b5dd8b95e03dd4f46676c5e854bafaea6
2022-04-09 15:22:29 -07:00
Willem Melching 871ecc451b commIssueAvgFreq: separate alert for avg freq check (#24150)
* commIssueAvgFreq: separate alert for avg freq check

* bump cereal

* bump cereal

* bump cereal

* freq_ok separate from alive

* bump cereal to master

* update_ref

* fix profiler
old-commit-hash: eaa581921161b2643b10ad72da0708dff14367aa
2022-04-06 16:43:32 -07:00
Adeeb Shihadeh 56bfed0c15 calibrationd: support for not cars (#24115)
* calibrationd: support for not cars

* update refs
old-commit-hash: 7dffd0ac0bd05379edd56dcdde1ac976ffa17137
2022-04-04 17:04: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
Dylan Herman c6f626d116 calibrationd: add function typing (#24018)
old-commit-hash: 9f1c663ae222a8e2f9e0c7c83d04a59ae4b46918
2022-03-23 00:28:36 -07:00
Dylan Herman f8b18e134d calibrationd: remove unused arg in function (#24004)
old-commit-hash: 604fefa9b1c0f473d73a2608217c302df8c088d6
2022-03-21 20:03:32 -07:00
Vivek Aithal 069fe1a749 locationd: Commissue fix (#23951)
* check allAliveAndValid only at filter init

* revert cereal and bugfix test

* rename filterValid to filterInitialized

* bump cereal

* correct err

* update refs
old-commit-hash: dfc12926144df063fb6bd20a97bb4390a4f5a4ef
2022-03-15 14:40:29 -07:00
Adeeb Shihadeh ec47e0fef0 break up selfdrive.config (#23959)
* break up selfdrive.config

* add to release files

* fix import order
old-commit-hash: 5c3f3e44bc7b25c9ce502419bcd0261c12ec2b0d
2022-03-13 21:42:39 -07:00
Willem Melching 3c3db89b68 locationd: fix writing LastGPSPosition interval (#23895)
old-commit-hash: f4c822e8c658df69589601bdd3e2095cd9e54e66
2022-03-02 15:16:19 +01:00
Vivek Aithal 5bad0f4400 locationd, paramsd: Check conditions before updating kalman filters (#23789)
* update filters only when all messages are alivbe and valid

* update message valid and fix unit test

* update refs

* move check outside loop

* modify fake message fn in test

* deprecate inputsOK and resolve PR comments

* avoid double looped list comprehension

* follow import conventions

* modify paramsd valid to only be invalid in case of commIssue

* update refs
old-commit-hash: 7e6903b58f141b94d645f25c5e0ce15825b60075
2022-03-02 01:01:29 -08:00
Vivek Aithal 1eb13fdc65 paramsd: fix VehicleModelInvalid errors (#23726)
* bound steerratio, stiffness std

* remove start steer_ratio limits after looking at data

* reduce sf obs noise

* update refs

* update refs

* add comment explaining change
old-commit-hash: 8a2cbfe00bffa82c7bd70a2b13c1ccf66f7271e0
2022-02-09 17:37:28 -08:00
Adeeb Shihadeh c8dc3909f4 give calibrationd rt priority (#23725)
old-commit-hash: 8a0fc850b43f851d2ac7d8d87e54d557b537de91
2022-02-07 21:05:55 -08:00
Vivek Aithal e4c2c2cf2e use roll std from locationd (#23449)
* use roll std from locationd

* cleaner

* add todo

* new ref

Co-authored-by: Harald Schafer <harald.the.engineer@gmail.com>
old-commit-hash: f808b174afbcc1fc6924d49fb0c32da5c02aad33
2022-01-12 21:37:09 -08:00
Dean Lee f112aef5a7 calibrationd: Don't repeatedly call get_valid_idxs() (#23473)
* optimize

* rpy_init should be np.array

* rename to rpys
old-commit-hash: e5f9af4a6ecc33e7e2d7774d40fe1614293dc319
2022-01-12 15:34:17 -08:00
Dean Lee 2bb2545d57 calibrationd: fix indentation (#23502)
old-commit-hash: de572c3755729ee61d257f794d2854845a796872
2022-01-12 14:40:02 -08:00
Willem Melching 2543a0bc62 boardd: remove ublox timestamp logging (#23498)
* boardd: remove ublox timestamp logging

* more cleanup

* add cmath
old-commit-hash: 79577e4dcaed6a4a2d4b55aabb5208ebdb2c191f
2022-01-12 15:00:46 +01:00
Willem Melching fec321a178 calibrationd: convert existing calibration to numpy (#23494)
* calibrationd: convert existing calibration to numpy

* use numpy functions
old-commit-hash: 8444f8267da10aaf52789d03f6d46d6b90be13ab
2022-01-11 15:25:01 +01:00
Dean Lee 55233b753b use ndarray.tolist to convert numpy array to float (#23485)
old-commit-hash: 35ec6ac1cb98f7d671edcb928a2b97d749a1edde
2022-01-11 14:34:47 +01:00
Dean Lee 38144fa83b calibrationd: remove extra comma (#23472)
old-commit-hash: f6c6e34ea34f61b2e8d32523a6414dc58b6419e4
2022-01-09 14:32:33 -08:00
Adeeb Shihadeh 1d324e09c4 skip falling device test
old-commit-hash: 1a6881edc6318bf30d2ba451d75eeb7d1b53389d
2022-01-06 14:05:13 -08:00
Adeeb Shihadeh 305a8eac79 locationd: disable falling device detector (#23431)
old-commit-hash: ef225e3e3515c449ba9f69d6e28c02912f1579c3
2022-01-06 12:01:14 -08:00
Dean Lee 179a685894 paramsd: follow capnp best practices (#23399)
old-commit-hash: df7126b982d6663d7016b6ad28c10af94dc00b19
2022-01-04 15:57:38 -08:00
George Hotz 86a39e838b Add More Types for mypy (#23268)
* mypy passes

* a few more

* a few in manager

* more types, will lint

* more

* simple types

* events type

* Update selfdrive/thermald/thermald.py

* Apply suggestions from code review

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
old-commit-hash: dc96d4bee7b898172a6a15de4799af0e2d35605e
2021-12-28 18:07:00 +01:00
Ewout ter Hoeven f206ebd054 Pyupgrade 3.6: Update syntax with Python 3.6+ features (#23305)
Updated Python code with Python 3.6+ features:
- utf-8 encoding is now the default (PEP 3120)
- Replace list comprehensions by Generator Expressions (PEP 289)
- Replace yield loop by yield from (PEP 380)
- Remove the (object) subclass when defining a class
- Replace the IOError alias by OSError (PEP 3151)
- Define sets with curly braces {} instead of set()
- Remove "r" parameter from open function, which is default

Co-Authored-By: Adeeb Shihadeh <8762862+adeebshihadeh@users.noreply.github.com>
Co-Authored-By: GregorKikelj <96022003+GregorKikelj@users.noreply.github.com>

Co-authored-by: Adeeb Shihadeh <8762862+adeebshihadeh@users.noreply.github.com>
Co-authored-by: GregorKikelj <96022003+GregorKikelj@users.noreply.github.com>
old-commit-hash: 332f568a8241fba9459cb70c76840b9670e6993a
2021-12-24 11:18:39 -08:00
HaraldSchafer f64c2974b4 Road Roll Compensation Rebased (#23251)
* first commit

* update refs
old-commit-hash: cf466222f623df5fac325b86b71dc4e181b40d55
2021-12-16 17:34:12 -08:00
HaraldSchafer 4de7b45d40 Calibrationd: check size of valid_blocks without current (#23223)
old-commit-hash: cd190dc85d3b917137bd3d7efa8032fe3045dc84
2021-12-14 15:14:14 -08:00
HaraldSchafer 22ec491d1f Calibrationd: don't use noisy current block (#23222)
old-commit-hash: 40dcc6382343df687f8304fe48a27d60c09f5d11
2021-12-14 14:09:38 -08:00
HaraldSchafer 4708268c7d Revert "Dont use erratic current block (#23211)" (#23221)
This reverts commit 5c76900f565c8e55f5738efb8fdf5d6a846dbe0e.
old-commit-hash: 837823ff58b57d49bc079a5d7f9ea8db55dc7d76
2021-12-14 13:59:39 -08:00
HaraldSchafer 6a7849aea3 Dont use erratic current block (#23211)
old-commit-hash: 19335bb6a48f0e3558c837557a1ae7c66b8b8587
2021-12-14 13:58:42 -08:00