Commit Graph

803 Commits

Author SHA1 Message Date
Justin Newberry 7dbdf6ba2b
Safety Tests: Create common gas brake safety test (#1537)
* create common gas brake safety test

* remove unrelated subaru reference

* also test below min_value

* better name and hardcoded

* use same as acceleration limits

* revert gm

* remove callable

* added common brake test and moved generic test to base safety class

* remove duplicate test

* wip

* wip

* rename longitudinalaccelsafety

* revert limits correct test

* fix controls allowed test

* move gm over to long gas brake test

* assert that limits are reasonable

* fix typing

* fix linter again

* fix linter again

* fix linter again

* like to make it clear

* typo

* fix from merge

* clearer names

* dont need thesemore

---------

Co-authored-by: Shane Smiskol <shane@smiskol.com>
2023-08-12 14:03:40 -07:00
Justin Newberry f29c753ba4
Safety: generic limit safety check (#1575)
* generic limit safety check

* fix messagefunction
2023-08-12 13:51:26 -07:00
Shane Smiskol 20b1e505c3
GM: move more longitudinal related function into class (#1574)
move these into the long test
2023-08-10 23:59:58 -07:00
Shane Smiskol 61590b681a
GM: clean up longitudinal safety test (#1573)
* clean up gm long safety test

* move to long base

* common brake
2023-08-10 23:49:28 -07:00
Igor Biletskyy 25f1444d73
panda: add CAN-FD throughput test (#1572)
init
2023-08-10 18:41:50 -07:00
Adeeb Shihadeh 61e987f6e2
remove safety replay test (#1569) 2023-08-07 18:38:01 -07:00
Igor Biletskyy a651fe3c6b
set OBD to False after test (#1568)
* reset OBD after test

* add comment
2023-08-07 10:54:39 -07:00
Justin Newberry 5801582baf
Subaru: convert measured angle to centigrees (#1567)
convert to centigrees
2023-08-07 09:29:34 -07:00
Adeeb Shihadeh 235067a22b
run HITL tests in parallel (#1566)
* seems to work

* cleanup

* run in ci

* fail on first

* fix jungle scope

---------

Co-authored-by: Bruce Wayne <batman@comma.ai>
2023-08-06 20:51:26 -07:00
Adeeb Shihadeh 77b09a3160
misc hitl test cleanup (#1562)
* misc hitl test cleanup

* adjust that

* update

* tres fix

---------

Co-authored-by: Bruce Wayne <batman@comma.ai>
Co-authored-by: Comma Device <device@comma.ai>
2023-08-06 16:30:21 -07:00
Adeeb Shihadeh 3dc3b58e20
ruff: enable bugbear checks (#1565) 2023-08-06 14:59:22 -07:00
Adeeb Shihadeh fc506e7b39
switch to ruff linter (#1564)
* switch to ruff linter

* cleanup
2023-08-06 14:29:28 -07:00
Adeeb Shihadeh 33a95d6bea
pedal: fix warning on invalid serial (#1563)
* pedal: fix warning on invalid serial

* fix

* fix:

* shouldn't need that

* fix

---------

Co-authored-by: Bruce Wayne <batman@comma.ai>
2023-08-06 13:47:37 -07:00
Adeeb Shihadeh c66b98b2a6
finish esp/gps removal (#1559) 2023-08-06 12:29:54 -07:00
Adeeb Shihadeh b976cf426a libpanda: silence build warning 2023-08-04 22:16:49 -07:00
Adeeb Shihadeh 6e1d35b033
more complete jungle reflash (#1557)
* more complete jungle reflash

* no spi!

* mv flash

* mv that
2023-08-04 21:51:09 -07:00
Adeeb Shihadeh 0f479a30a3
CI: reflash jungle (#1546) 2023-08-04 18:11:29 -07:00
Justin Newberry 7b6806c270
Safety: Add desired angle to safety helpers (#1554)
add desired angle
2023-08-04 17:30:10 -07:00
Justin Newberry 2a72404ccb
Subaru: Add measured steering angle and vehicle speed (#1528)
* correct vehicle speed and add measured angle

* misra

* misra

* common test for angle

* PR cleanup

* use subaru prefix

* clean it up a bit

* minimize whitespace diff

* need float for deg_to_can
2023-08-04 17:16:35 -07:00
Adeeb Shihadeh 1950ba6f83 cleanup bus count constant 2023-08-04 10:47:03 -07:00
Adeeb Shihadeh 977d702770
cleanup old pedal stuff (#1552) 2023-08-04 10:40:53 -07:00
Adeeb Shihadeh d7120be904
panda jungle (#1547)
* mv jungle

* match pedal style

* fix linter

* fix fw path

* fix paths

* safety!
2023-08-03 23:55:13 -07:00
Adeeb Shihadeh e7894e6770
Move CanHandle to python/ (#1550) 2023-08-03 23:10:16 -07:00
Adeeb Shihadeh f37f8d90ba
cleanup build, prep for jungle (#1549)
* cleanup build, prep for jungle

* cleanup

* update pedal obj path
2023-08-03 19:07:41 -07:00
Adeeb Shihadeh 1eac0d7634
HITL: remove old check, it's always checked on panda connect now 2023-07-20 11:25:06 -07:00
Adeeb Shihadeh b2741013f6
instructions for flashing internal panda (#1521)
* instructions for flashing internal panda

* Update board/README.md
2023-07-17 20:17:18 -07:00
Adeeb Shihadeh 5d873444b2
SPI: connect by VERSION command (#1495)
* SPI: connect by VERSION command

* shorter timeout

* add exception

* simple test

* fallback

* bootstub check

* update comments

---------

Co-authored-by: Comma Device <device@comma.ai>
2023-07-16 19:33:18 -07:00
Cameron Clough 0c33554624
Ford CAN FD safety (#1455) 2023-07-16 15:09:37 +01:00
Shane Smiskol 8e31711aa2
safety helpers: cruise engaged prev setter (#1511)
* bbb

* Apply suggestions from code review
2023-07-14 18:21:28 -07:00
Justin Newberry c8acdc6f61
Subaru: cleanup tests (#1508)
* macro

* base tests

* leave it same as ford

* call base setupclass

* Update common.py

* Update test_hyundai_canfd.py

* merge
2023-07-14 12:43:49 -07:00
Adeeb Shihadeh 6b9b448259
log device boot time (#1503)
* log device boot time

* misra

* only log real boots

* set gpio

* true

* initial

* log bootkick

* fix RPv2

---------

Co-authored-by: Comma Device <device@comma.ai>
Co-authored-by: Igor Biletksyy <bs@privacy.im>
2023-07-12 20:34:46 -07:00
Adeeb Shihadeh 14fd5ff5a3
SPI: send bootstub status in version request (#1492)
* mv first

* switch to crc8

* bootstub

* test

* cleanup

* little more

* misra

---------

Co-authored-by: Comma Device <device@comma.ai>
2023-07-03 15:23:12 -07:00
Adeeb Shihadeh d693e89df2
SPI: send hw type with version (#1490)
Co-authored-by: Comma Device <device@comma.ai>
2023-07-02 23:50:30 -07:00
Adeeb Shihadeh abcbfb44b4
SPI: send serial with protocol version (#1489)
* SPI: send serial with protocol version

* misra

* fix test

---------

Co-authored-by: Comma Device <device@comma.ai>
2023-07-02 23:13:57 -07:00
Adeeb Shihadeh 5abb2b58da
SPI: add protcol version request (#1488)
* SPI: add protcol version request

* quick test

* fix linter

* misra

---------

Co-authored-by: Comma Device <device@comma.ai>
2023-07-02 15:51:35 -07:00
Adeeb Shihadeh 21843092ff
bump to python 3.11.4 (#1481)
* bump to python 3.11.4

* Update .pre-commit-config.yaml

* lint

* import

* no | yet

* rm ignores

* Update tests/libpanda/libpanda_py.py

---------

Co-authored-by: Maxime Desroches <desroches.maxime@gmail.com>
2023-07-01 17:43:34 -07:00
Igor Biletksyy 04f0c4261c Revert "HITL tests: reset jungle on init (#1473)"
This reverts commit 1c574f8a99.
2023-06-28 12:34:18 -07:00
Igor Biletksyy 6309bb8a6a Normal to have REC and TEC counters > 0, but less than threshould 2023-06-26 14:16:34 -07:00
Adeeb Shihadeh 1c574f8a99
HITL tests: reset jungle on init (#1473)
Co-authored-by: Comma Device <device@comma.ai>
2023-06-20 19:34:05 -07:00
Adeeb Shihadeh 6eb3a7324f
tres: enable fan overshoot test (#1465)
* tres: enable fan overshoot test

* rm
2023-06-16 21:56:11 -07:00
Cameron Clough 55ef91d9ab
Ford: don't check vehicle roll quality flag (#1461) 2023-06-17 01:11:21 +01:00
Adeeb Shihadeh c6283759e6
increase fan test timeout, can take a while to recover 2023-06-16 14:06:32 -07:00
Adeeb Shihadeh fc994f5cf9
HITL: check FW version before every test (#1463) 2023-06-16 13:59:07 -07:00
Robbe Derks 0cc91a7f7b
Logging (#1445)
* try 1

* some fixes

* fix some misra

* first poc working

* more things

* more misra fixes

* fix misra

* add rate limiting

* fix misra

* add some unit tests through libpanda

* add more tests and fix some stuff

* fix misra again

* add startup log hitl test

* list

* don't fail on wrong timestamps

* improvements

* fix tests

* expected logs test?

* not sure why this passed

* oh, it doesn't reset

* only show last few

* guess at expected logs

* needs this

* ugh

* reduce compiler warnings

* adjust expected logs

* this is correct

* is it really 1?

* min max

* reduce spam in SPI test

* some cleanup
2023-06-13 17:00:56 +02:00
Adeeb Shihadeh adc0c12f7b HITL tests: enable flashing tests on tres 2023-06-11 19:56:09 -07:00
Adeeb Shihadeh a4ed5bb943
adjust timeouts (#1444) 2023-06-04 21:17:44 -07:00
vanillagorillaa aa03163a92
Nissan: use generated DBCs (#1438)
* update nissan dbcs

* update opendbc ref

* Update Dockerfile

* Update Dockerfile

* fix

* try again

* need that too

* cp

---------

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
2023-06-04 16:06:46 -07:00
Adeeb Shihadeh 92ed48ae5c
HITL tests: add timeouts (#1352)
* set timeout

* closest

* more timeout

* fan test is slow

* retry

* break

* bump
2023-06-04 01:00:17 -07:00
Adeeb Shihadeh e1e9bd048d benchmarking script 2023-06-03 15:22:47 -07:00
Robbe Derks 5847d7dbc0
Tesla safety: fix wrong message rate (#1277)
* half the freq, double the rate

* fix test

* fix names
2023-06-01 23:10:36 +02:00