Commit Graph

37 Commits (e0a706e4f013b69253f300eeeda3a60915e10adf)

Author SHA1 Message Date
Willem Melching e0a706e4f0
Stricter pylint (#550)
* stricter pylint

* Add as argument
2020-06-02 16:27:07 -07:00
Adeeb d7f7b14118
Enable almost all Flake8 checks (#548)
* fix W391

* E262

* E703

* W293

* some E

* E231

* some more E

* E225

* more E

* E252

* no tabs

* more tabs

* E701

* uds.py

* almost all of them

* only e265 left

* not sure why this is triggering on commented out code

* ignore esptool
2020-06-01 01:49:26 -07:00
Adeeb Shihadeh eba113cb67 backslash is redundant between brackets 2020-05-31 17:39:42 -07:00
Adeeb 9ebde2535c
Reset state on safety mode init (#542)
* reset state on safety mode init

* more global state

* reset message seen too

* misra
2020-05-26 14:23:39 -07:00
Adeeb c9102c00ee
Chrysler: use can packer in safety tests (#522)
* Chrysler: use can packer in safety tests

* bump opendbc
2020-04-30 14:26:28 -07:00
Adeeb 9874e73350
Abstract steering safety tests for Toyota and Chrysler (#520)
* start abstracting torque steering tests

* remove duplicate

* chrysler

* remove that

* revert that for now

* fix toyota

* unused
2020-04-29 20:37:12 -07:00
Adeeb 0bc864b3d5
Make torque-based steering state global (#518)
* use generic steering state vars for toyota

* chrysler

* gm

* comment

* more unnecessary lines

* hyundai

* subaru

* vw

* fix mazda
2020-04-28 10:33:20 -07:00
Adeeb Shihadeh bd98fe6031 safety tests: use shorter function name 2020-04-27 15:27:28 -07:00
Adeeb 884afa0ef7
Safety Test Refactor: Chrysler and Volkswagen PQ (#508)
* volkswagen pq

* chrysler

* cleanup
2020-04-17 13:34:23 -07:00
Adeeb 62e4d3c369
Chrysler: fix missing button signal on TX (#490)
* Chrysler: fix missing button signal on TX

* fix test
2020-04-10 13:48:41 -07:00
eFini 4e98bbe8c9
Apply unsafe allow gas mode to all cars. (#480)
Apply unsafe iso accel/decel limit to toyota.
2020-04-06 08:56:36 -07:00
rbiasini ceff91d3c5
Standardize brake safety tests (#465)
* WIP: improve safety test format

* Fix tests
2020-03-07 23:22:47 -08:00
rbiasini 11ef24bc16
Improve tests (#456)
* much more thorough Honda-Bosch tests and better test inheritance. Also fix counter test bug

* Fixed other counters too

* remove unnecessary function
2020-02-29 09:00:29 -08:00
rbiasini dad5858b8c
Chrysler: add brakepress cancellation (#451) 2020-02-26 18:19:18 -08:00
rbiasini d7f1195d1e
Chrysler Checksum/counter (#450)
* abstract crc function

* counter-checksum for chrysler

* also adding checksum to tests
2020-02-24 16:36:46 -08:00
rbiasini b2ffaae60e
Chrysler: disengage on gas press (#442)
* add gas cancellation for chrysler
* added regr test too
* also add bus checks to chrysler. SHould have been there already
2020-02-19 23:46:38 -08:00
Riccardo 4f9c879696 remove abunch of lines from safety regression tests by using common make_msg function 2019-11-19 11:29:04 -08:00
Riccardo 212d336b3d Safety Chrysler: Added cancel spam button check 2019-11-17 22:32:13 -08:00
rbiasini 6249a183d6
tx_hook shall have a white-list of messages (#381)
* Started whitelisting messages

* Also toyota and cadilalc fix

* bug fixes and better checks. Need to figure out a solution for honda

* Whitelist also for subaru

* Added Chrysler as well to whitelist

* And Hyundai too

* now all supported cars should have a whitelist of messages

* Fix linter

* This should fix process replay

* Honda too is now whitelisted

* struct typedef

* Had forgot GM

* had a wrong addr for GM whitelist

* This should fix all the tests

* bump panda
2019-11-17 00:24:19 -08:00
Riccardo e74ed93640 safety tests a bit more simplified 2019-11-15 01:12:54 -08:00
Riccardo 2027765bd0 relay malfunction test centralized 2019-11-15 01:03:34 -08:00
Riccardo 8af1a01ac6 clean up safety tests 2019-11-15 00:52:34 -08:00
rbiasini cfcce8f06b
WIP: Relay malfunction (#384)
* relay malfunction handling. WIP

* more cars to relay_malfunctions

* fixed safety tests

* minor change

* Fix linter

* all cars now have a relay_malfunction safety check

* added relay_malfunction safety test for fwd hooks

* added proper regression tests for relay malfunction to all cars

* temp patch to not fail regression in honda bosch

* also addr 0x194 is some nidec honda is steer control

* proper relay check for honda bosch too
2019-11-15 00:32:45 -08:00
Riccardo e8d7ed1d90 Rename function name to not confuse safety_set_mode and set_safety_mode 2019-11-06 14:30:22 -08:00
rbiasini fce38a91d7
Linter python (#299)
* Added pyflakes and Pylint for python

* Actually run linter in CI

* some simple pyflakes changes

* Add flake8 to panda reqs for linter test

* flake8 errors are fixed

* run flake8 in regression tests

* meant to run flake8

* hack to ignore unused import

* bug

* fix bugs in tucan_loopback

* Another fix by using set_safety_mode

* added pylintrc file

* more fixes and enabled pylint as well

* Fix pylint in circleci

* added linter to readme
2019-10-15 14:03:31 -07:00
rbiasini 70219d7bb2
match safety enum in cereal (#285)
* match safety enum in cereal

* removing tons of hardcoding

* add pythonpath to safety test

* Fix safety test in Docker
2019-10-02 18:20:32 -07:00
Riccardo 0de9ef73cc Revert "Final 2to3 on the whole repo"
This reverts commit c92fd3bc90.
2019-09-25 17:01:13 -07:00
Riccardo c92fd3bc90 Final 2to3 on the whole repo 2019-09-25 16:58:56 -07:00
Riccardo 2dc34096a0 2to3 applied 2019-09-24 22:33:46 -07:00
Riccardo 1e2412a297 env python -> env python3 2019-09-24 17:50:53 -07:00
Riccardo 133269a1a4 Added fwd test coverage for Toyota, Hyundai and Chrysler too. Removed replay tools for Chrysler, as a generic replay tool has been recently added 2019-06-11 19:24:08 -07:00
quillford cd20d123c4 refactor tests/safety to use generic hooks (#208)
* refactor tests/safety to use generic hooks

* cleanup refactor

* removed dead code
2019-06-11 01:31:00 -07:00
Drew Hintz 7b504d2f88 panda safety test that replays drives of saved CAN messages (#151)
* panda safety test that replays drives of saved CAN messages

* utility to trim Cabana CSV logs to just messages relevant for panda safety testing

* when trimming, only output the same line once even if it matches both criteria
2019-02-21 13:35:04 -08:00
Riccardo be0061dccb Chrysler: safety now based on motor torque 2019-01-02 21:53:07 -08:00
Riccardo Biasini 039d1834b6 Chrysler: fixed regression test 2019-01-01 20:00:11 -08:00
Riccardo cf3ecd629d Chrysler safety: re-using hyundai framework 2018-12-28 19:20:57 -08:00
Drew Hintz 799c33868d Chrysler safety controls (#130)
* Chrysler safety model and tests.

* fix comments

* when ACC is canceled, disallow controls

* update SAFETY_CHRYSLER value in Python API and add other SAFETY values
2018-11-06 12:28:33 -08:00