Commit Graph

192 Commits

Author SHA1 Message Date
Willem Melching
16fe1bb2ad Hardware abstraction class (#2080)
* hardware abstraction class

* De Morgan

* Rename pc hardware class

* Fix sound card in controlsd

* Pc get sim info

* fix hardware in test

* two more

* No more random imei on android

* no randomness on android

* Need to return something that looks like imei for registration to work

* Return proper network strength

* Unused import

* Bug fixes + gpsd is only android
old-commit-hash: c7152d54192605c833912b69cf85514ac2e1b1fc
2020-08-26 14:57:17 +02:00
Willem Melching
22e0a2474a Pandad: turn on panda power (#2073)
* pandad turn on panda power

* Add gpio.py

* needs bytes

Co-authored-by: Comma Device <device@comma.ai>
old-commit-hash: 6bb2630eba1bff2db745e56d639fce8b85ec6d0d
2020-08-24 16:56:29 +02:00
robbederks
bcaf2a36af Car power integrator + power management refactor (#1994)
* wip, ready to test

* tweaks

* fix

* fix

* fix power monitoring

* fix param writing

* no forced charging on high voltage

* reset capacity on reboot

* don't shutdown unless started seen

* fix unused var warning

* fix linting errors

* time is always valid

* QCOM gate

* Local params

* decimate saving

* fix linting

* rename param

* Log car battery capacity

* fix put_nonblocking

* Added some unit tests

* Add test to docker test list

* fix precommit

* cleanup

* run tests in CI

* bump cereal

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
old-commit-hash: 7555379b2b1da2f800e98963ad4436b7fb91cce9
2020-08-17 11:56:27 +02:00
Adeeb Shihadeh
017b084154 Alert when updated consistently fails (#2013)
* alert when update fails more than 10 times

* bring over offroad alert refactor from other branch

* and we have tests

* use it in snapshot

* bump apk

* don't show exceptions on release branches

* only write when changed

* why does delete use so much cpu

* clean that up

* little more
old-commit-hash: 8e63f065400ea1868f077560ae89b2c17f5523f8
2020-08-11 16:23:57 -07:00
Harald Schafer
a6b31a2ec6 makes more sense
old-commit-hash: e704da0c28546fd9fc8ee53ea19793880d042059
2020-08-04 15:30:20 -07:00
Harald Schafer
c199717a71 dont init sound
old-commit-hash: 0a01d88139dd35cd4d979dbac78e2f0ff69a7664
2020-07-31 13:11:59 -07:00
Harald Schafer
82691a0427 needed in pipeline
old-commit-hash: e03f9d7c7370ead66acf84e27e8361c6fd453379
2020-07-28 15:12:16 -07:00
Willem Melching
760044710c update pipfile.lock (#1896)
* update pipfile

* matrix is deprecated

* Numpy almost equal

* sympy 1.6
old-commit-hash: 95b0c69c12cb859025b77d1ba9ed9433c78f1e9f
2020-07-21 21:15:09 +02:00
Willem Melching
9c291968f6 Speedup URLFile (#1888)
* add parallel download support to URLFile

* make python 3.8 happy

* Fix chunk size

* Automatic number of threads

* No daemon threads in unlogger

* Cache length

* dont touch old filereader

* Remove debug info

* remove debug script

* Ignore type
old-commit-hash: c70700758d9e3227a157d2e9fdcb9d3204b433c2
2020-07-20 17:10:08 +02:00
Adeeb Shihadeh
cd317b0780 Fix most remaining LGTM alerts (#1893)
* fixups from LGTM

* short globals

* fix spinner and textwindow

* total ordering

* no spinner/text window when import from manager

* not android
old-commit-hash: 5db81f60ca8fbc0ef28924b7e93f25a1d4bb3764
2020-07-19 16:12:22 -07:00
Adeeb Shihadeh
86d9da50c5 add test for params permissions
old-commit-hash: 2ad9c50e3613674cb6170b46411d7dba0b1edff9
2020-07-18 18:30:29 -07:00
Adeeb Shihadeh
2e066f16e8 fix params permissions after #1890
old-commit-hash: 8db641efec5d3c4df284afd9b8c8e9c2838ccabb
2020-07-18 18:10:46 -07:00
Mufeed VH
9b94e0ae8b Fix insecure temporary file creation (#1890)
* Fix insecure temporary file creation

* minor error fix

tmp_path.name (NamedTemporaryFile().name) is required to return the filename string.
old-commit-hash: a34b9f5cb5a691b2153f6a2ba905e6f1f84af341
2020-07-17 23:49:57 -07:00
Adeeb Shihadeh
370a68623e minor cleanups from LGTM
old-commit-hash: 35a5b057c1ab6d3f77daae6a40d14c9bff28f08b
2020-07-17 23:34:38 -07:00
Adeeb Shihadeh
993eeaf694 Rebuild cython extensions when dependency version changes (#1886)
* rebuild cython extensions when python/cython/distutils version changes

* submodules and boardd

* kalman and transformations
old-commit-hash: 165e14d10384a67777ec5ed787cf1ec82ec61ccb
2020-07-16 13:59:32 -07:00
George Hotz
3a004596e9 add calmodel
old-commit-hash: 4619401bfc8ce4f5a6fac5167e5e386ffbf36409
2020-07-06 11:56:31 -07:00
Adeeb Shihadeh
0d79150606 Sound test (#1820)
* WIP sound test

* it does something

* refactor

* phone only

* update release files

* test sound card init

* add to CI

* check writes

* increase time

* unused

* only build cereal

* small tolerance

Co-authored-by: Comma Device <device@comma.ai>
old-commit-hash: f1afb3e3ae4b95a1de0262d1408c49093c5ada6f
2020-07-05 17:56:24 -07:00
Adeeb Shihadeh
4f4c83a0c3 remove manager_helpers.py after CPU usage test refactor
old-commit-hash: b23d7950e3d38d4b436801e35c76b66657b35c95
2020-07-04 00:10:58 -07:00
Greg Hogan
7ed2fb158c remove duplicate logging context
old-commit-hash: 1206409b2e83f7def11d9b8473fa30e16736f41f
2020-07-03 16:18:29 -07:00
Adeeb Shihadeh
f74865bedf Refactor CPU usage test (#1802)
* pull CPU usage test out of manager

* remove that

* add to release files

* cleanup

* executable

* this should work

* check if car started procs are running

* debug

* add min cpu usage

* remove debug prints

* adjust min cpu threshold

Co-authored-by: Comma Device <device@comma.ai>
old-commit-hash: 6db7fa8c033841c82d1139119aad8a20645449f4
2020-07-03 15:40:13 -07:00
George Hotz
70dbce450c Add an SSH param to disable updates (#1807)
* disable updates with optional param

* dont create the alert

* Revert "dont create the alert"

This reverts commit 7179a6c8b4b4656e0b203b5a590b33d3388aa9c9.

* keep alert, but allow engagement

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
old-commit-hash: cb495bb8c9af8b9347bfe3cf4b59baf1f6d10482
2020-07-01 14:26:35 -07:00
Adeeb Shihadeh
2c80231922 support code for NEOS update alert
old-commit-hash: d08864572fd60465650150734c43565d7a5d27b0
2020-06-25 13:05:12 -07:00
Adeeb Shihadeh
e8bc334d22 fail CPU usage test if can't get usage for a process
old-commit-hash: b89d10c086a6d6b8d881af58f859db9e40c7ee67
2020-06-23 16:11:41 -07:00
Adeeb Shihadeh
68dd136645 fix CPU usage test for thermald and dmonitoringd
old-commit-hash: 33f905b1ed131c26557c5429a9ba8af9f16110bd
2020-06-23 15:51:43 -07:00
Adeeb Shihadeh
880e607c2f remove unsused file
old-commit-hash: 59e77423c4af2f867b26a2e1c239399e6b637b55
2020-06-23 11:40:40 -07:00
Adeeb Shihadeh
d8adab2ce5 enable flake8 F error codes
old-commit-hash: d204d87b95114f8aa6e719b4628be2abe8be27dc
2020-06-22 14:00:32 -07:00
Willem Melching
fe4fb82b5d add getter for LocalCoord transformation matrices
old-commit-hash: 29262db5d63f0e5d65c2f00d4929991fb2e0d848
2020-06-10 11:35:45 -07:00
Willem Melching
76a465e0ec Write orientation & transform in C++ (#1637)
* locationd at 20hz

* update ref

* bump cereal

* dont modify global state

* add scons files

* ecef2geodetic and geodetic2ecef

* Finish local coords class

* Add header file

* Add orientation.cc

* cleanup

* Add functions to header file

* Add cython wrapper

* y u no work?

* This passes the tests

* test rot2quat and quat2rot

* Teste euler2rot and rot2euler

* rot_matrix

* test ecef_euler_from_ned and ned_euler_from_ecef

* add benchmark

* Add test

* Consistent newlines

* no more radians supported in geodetic

* test localcoord single

* test localcoord single

* all tests pass

* Unused import

* Add alternate namings

* Add source for formulas

* no explicit tests needed

* remove benchmark

* Add release files

* Typo

* Remove print statement

* no access to raw transform matrix

* temporarily add tolerance

* handcode quat2euler

* update ref
old-commit-hash: c18e7da3c25c59a19efda8ec3a1b716c2571cc2f
2020-06-09 16:44:26 -07:00
Greg Hogan
02d68d91fb mkdirs_exists_ok more specific URL detection
old-commit-hash: 3b180240d53564274a9258ff1f851a478bb0b741
2020-06-09 08:56:16 -07:00
Greg Hogan
5db2854138 ensure mkdirs_exists_ok is not called for URLs
old-commit-hash: 7bf9b04570b0eea77de33181a58134ec8ddb4b19
2020-06-08 19:29:33 -07:00
HaraldSchafer
5df437cb14 More rigorous definition of calibration
old-commit-hash: 51061175252d14265e608fe6ed5640d0840fdb70
2020-06-05 21:52:58 -07:00
Jason Young
ebed52527b Reduce scheduler latency for realtime processes (#1638)
* WIP: reduce boardd and other lags

* Copypasta fault

* Silence spurious startup warning

Co-authored-by: Comma Device <device@comma.ai>
old-commit-hash: 68531b071cde6fa5856d9b68bed63ecb50e03c2a
2020-06-05 17:09:41 -04:00
Adeeb
d035394ce7 Add pre-commit hooks (#1629)
old-commit-hash: ab83e48ec4f7c7ddaa742d9797b0d38646fdb268
2020-06-03 12:54:49 -07:00
Willem Melching
a56e2b01f8 Make pylint more strict (#1626)
* make pylint more strict

* cleanup in progress

* done cleaning up

* no opendbc
old-commit-hash: 843a64c72fb94397a1edf814fa66044c8d92acbf
2020-06-02 16:29:32 -07:00
Willem Melching
3ac6adc393 Turn Jenkins CPU test back on (#1617)
* run cpu test again

* Update cpu values

* Locationd can be more too

* Give some updater allowance

* Just remove updated
old-commit-hash: b042ac034e539df09a7040dd4f28b2afc2429f55
2020-06-01 18:57:04 -07:00
Harald Schafer
96c280aa94 better name
old-commit-hash: 56e155d41cc84f480f3b72c68476fddbf786c6e2
2020-06-01 12:09:09 -07:00
Adeeb Shihadeh
37a67a2a14 enable flake8 E502: backslash is redundant between brackets
old-commit-hash: 6466ec982aa47bcbbc7c6a3a7cf60cec0163be84
2020-05-31 17:41:18 -07:00
Adeeb Shihadeh
8b3418b0f9 enable flake8 E251: unexpected spaces around keyword / parameter equals
old-commit-hash: ebed2d1dcc53f092696b61fd1e004045c9bde893
2020-05-31 17:34:47 -07:00
Adeeb Shihadeh
9823f1164c enable flake8 E303: too many blank lines
old-commit-hash: f3dcf861c73b47c52b5dd77a8f1f8858005ae18b
2020-05-31 17:21:11 -07:00
Adeeb Shihadeh
68a3061c9d enable E261 in flake8: two spaces before inline comment
old-commit-hash: 27754a277c36b82ef4040e536cc918ba8ad77bec
2020-05-31 14:07:29 -07:00
Willem Melching
5fb17dc296 Enable new params learner for improved vehicle model estimation
old-commit-hash: a0adc4482108a3b89b6e4cb3fe27b8f51291bc08
2020-05-31 13:36:27 -07:00
Willem Melching
9e46dc99c2 fake text window has no close
old-commit-hash: 0e7d50941551d27c8f12e618fac0c03a96109f07
2020-05-31 12:50:43 -07:00
Adeeb Shihadeh
be0b43f339 enable flake8 E231: missing whitespace after comma
old-commit-hash: efd5dffb1e727c70065fdbe7499ec9e009dfd282
2020-05-31 12:49:11 -07:00
Adeeb
7965569766 Flake8 E22X (#1607)
* e221

* e225

* bump opendbc
old-commit-hash: 6051061ff8e7809960cc1f2bad9a582801d5a83e
2020-05-31 00:48:47 -07:00
Adeeb
5e857427ba Enable more flake8 checks (#1602)
* enable some more flake8 checks

* some more quick ones

* bump opendbc

* e401

* e711 e712

* e115 e116

* e222

* e301

* remove that

* e129

* e701 e702

* e125 e131

* e227

* e306

* e262

* W503

* e713

* e704

* e731

* bump opendbc

* fix some e722
old-commit-hash: d9bf9f0a4036f55411f6dfbb438990a5eb7f4930
2020-05-30 20:14:58 -07:00
Adeeb Shihadeh
60f348e310 Revert "minor LGTM fixes"
This reverts commit 58d908531bfb28b46719d74121325a7e6548d98c.

old-commit-hash: 6230f366c5f0b319755e537f4cc621f0805b270d
2020-05-29 11:10:48 -07:00
Adeeb Shihadeh
dc81f74851 minor LGTM fixes
old-commit-hash: f10c2eff7d8bbbaab62f1fc3712309a29558be07
2020-05-29 00:44:27 -07:00
Willem Melching
2ac27def5a Running pre-commit in CI (#1590)
* Running pre-commit in CI

* fix dockerfile syntax

* dont run on submodule repo folders

* Fix some import errors in ci

* more stuff

* That should be the last one
old-commit-hash: ba2ac1207a554d277e01af5b9514de4500d4f66a
2020-05-28 15:40:48 -07:00
Willem Melching
2b60ee9531 Run mypy commit hook (#1591)
* run mypy commit hook

* fix mypy errors
old-commit-hash: 3d08dcc3b27936cb14c0eae63605be9a6c077380
2020-05-28 15:05:04 -07:00
Willem Melching
12a306021d flake8 in pre-commit(#1583)
old-commit-hash: 29aaa44740b5dae3c1cc0c273c72c7eb53135e5e
2020-05-27 20:33:05 -07:00