* gm: test the other relay malfunction addr when using long with gmcam (ASCMGasRegenCmd)
* make it a dict
* might want to split these changes
* messy
* Revert "messy"
This reverts commit 25cd68fcab.
* some more
* ford: check longitudinal addr
* chrysler
* fix ford!
* gm and subaru
* common
* draft
* clean up
* clean up check
* rm line
* clean up
* add context
* apparently None isn't optional
* conventional test
* Revert "conventional test"
This reverts commit 4b265ad4ab.
* whoops, clean that up
* more clean up
* add a helpful cmt
* more hlpfl cmt
* can remove this test now
* hyundai cmts
* not really needed
* test safety_defaults
* rename panda safety test
* add PandaSafetyTest base back
* remove car-specific tests from PandaSafetyTest (for ALLOUTPUT, NOOUTPUT, ELM327 tests)
duh
* Add TestAllOutput comparison
* needs to be list
* fix extra loops (faster)
* create lin msg correctly
according to ad79b7f4d2
* use bytes
* some clean up
* revert coverage
* ensure same
* fix typing
* rx hook: scan all addrs
* this is cleanest
* parameterized_class doesn't work nicely
* Revert "parameterized_class doesn't work nicely"
This reverts commit 3a46f1f514.
* add test for silent
* rm spaces
* common?
forgot
* Revert "common?"
This reverts commit f136ae276f.
* Update tests/safety/test_defaults.py
* Ford AEB safety
* whoops
* working tests
* debugging
* clean up
* stock aeb test
* split up test
* rm
* cmt
* rm
* just test stateless sigs for simple branch
* clean up
* rm
* just test this bit
* it's signed now
* cmt
* cmt
* clean up
* ohh
* add ACCDATA msg
* ford long safety
* long flag
* split stock and op long tests
* use accel limits for brake
* add comment
* fix acceleration limits
fix acceleration limits
* fix gas limits
* temp bug
* fix min gas, allow -0.5 (engine braking?)
* fix test
* fix tests
* yay it caught this
* pylint
* base name
* typing
* Revert "typing"
This reverts commit 7fb5e304cb.
* temp fix
* rm line
* this is handled by PandaSafetyTest
* revert
* move
---------
Co-authored-by: Cameron Clough <cameronjclough@gmail.com>
* ford curvature rate limits draft
* make common angle tests work with curvature
* comment
* no need for this
* extra line
* fix test
* generic curvature test class
* more reasonable limits
* adjust limits
* draft
* works
* works
* clean up
* add vehicle speed
* works
* clean up
* clean up
* more clean up
* more clean up
* lower
* double
* add updated bp
* remove
* can clean that up
* draft
* this works!
* think that's the correct placement
* try this
* closer
* use min
* add/sub one to not falsely trip
* remove old angle error safety
* i'm not sure if clamp is more readable
* fix that
* fix
* stash
* fix these tests
* ternary
* floats are a pain
* draft, works kinda
* even better
* round that
* need tolerance
* this should work (adding tol=1 wouldn't let us have multiple rate limits)
* test works
* clamp breaks if low is higher than high :(((
down from 150 blocked msgs to 7!
* no blocked msgs!!!
* test a whole bunch
* stash
* stash
* clean up test
* clean up test to be more like torque (+ speeds)
* clean up
* cmt
* test up
* up and down are good
* rename and remove
* this is tested
* uncomment
* this is tested by ensuring we move towards error at a minimum rate
* not used any more
* revert common
* clean up test_ford a bit more
* some clean up (combine variables where it makes sense)
* yeah can't use clamp since min isn't always < max, min(max(.. handles this
* clean up
* revert that
* comments
* cmt
* another
* that's old
* misra!
* Update board/safety/safety_ford.h
* Update board/safety/safety_ford.h
* add todo, fix test case
* more clear, matches panda
* add comment
* Update tests/safety/test_ford.py
* more fine speed increments
* rm comment
* better names
* this is expected behavior (tested by common checks)
* CURVATURE_ERROR_LIMIT_SPEED
* better name?
* pretty clean!
* same for up
* only used in one place now
* these are now clear
* common term
* make vehicle_speed a sample_t
* need to use values[0]
* speed is a float
* Revert "speed is a float"
This reverts commit 01af02f1d3.
* Revert "need to use values[0]"
This reverts commit 8f6d68345a.
* Revert "make vehicle_speed a sample_t"
This reverts commit ecd8dc86b6.
* safety fixes for new speed sample
* test fixes for new speed sample
* fix misra and make intermediate variable
* this isn't needed
* test angle meas readback (ensures speed and yaw rate are used properly)
* revert
* rm
* tuple
* temp
* clean up
* stash
* Revert "stash"
This reverts commit cab96b3e2b.
* use global
* test negative
* name
* test that we can send curvature=0 if enabled=False while control_allowed=True (let's say EPS faults, OP doesn't want to actuate)
* draft
* only check error if apply bit is 1
* subtest
* no subtest
* fix safety and tests
* tests say this works
* clean up
* subtests are sloww
* Revert "subtests are sloww"
This reverts commit 560c6745c8.
* fix test from merge
* add comment
* add comment
* add another comment
* spacing
* set ford vehicle speed
* parse yaw rate signals
* misra
* misra
* misra
* misra
* draft
* update module
* already checked
* and set it properly
* some stuff
* draft
* clean up (will fail tests because we don't send yaw rate yet)
* could do something like this
* this is better and less prone to bugs
* match simple op limiting, debugging
* set checksum for messages in tests
* clean up
* fix that
* one m/s fudge
* fix sign of yaw rate
* interpolate detects size
* forgot OP flips the curvature sign. it matches yaw on can
* all my debugging crap
* make replay work for ford
* fix panda blocking messages (array is fixed size so size-1 is 0 rate at high speed)
* uncomment safety test limits
* revert
* round for zero blocked msgs
* fix limits
* meas safety checks that down rate is >=, not <
* test pass
* lots of comments and draft what one meas torque check would look like
* fix that
* add curvature meas
* add debugging stuff
* Revert "add debugging stuff"
This reverts commit 449783fc62.
* messy but at least one test passes now
* draft
* add max_steer
* some safety clean up
* and that
* start with a test that works
* another test that works (sort of, we need more strict panda safety without false positives)
* no max curvature check (not safety related), allow any rate limits
* add new function
* also need to consider max val here, since OP will send up to that
* and now use the function
* lower to 10
* compilation fixes
* clean up (no rate limiting)
* remove that too
* curvature diff test
* more clean up
* debug
* ?
* better names
* more official
* use _curvature_meas_msg_array here
* bit faster
* no i don't
* revert that
* why not just use angle_meas?
* bb ll
* bb deb
* clean up debug vals
* more
* revert replay drive debugging changes
* Update board/safety.h
* rm line
* only need to round the final thing
* not needed, under 10 ms
* make a class variable
* fix a misra?
* another misra?
better
* ?
* 12.1
* need to explicitly convert
* add one to not false trigger the violation (float rounding)
* not really needed
* rm line
* cmt
* use clamp
* rename
* in struct
* comment
* use max_limit_check
* draft clean up
* Revert "draft clean up"
This reverts commit d1a0e8acd1.
* make a global
make a global
* this is fine
* Add second speed
* 2.5 m/s is 9 kph, 4 kph is the max in the field
* add quality signal
* qf signal name
* comment
* checksum matches except it goes to zero when turning the car off despite counter still active
* update comments
* now test it
* spacing
* Update board/safety/safety_ford.h
* zzzz
* not needed
* whoops
* test vehicle state mismatch
* add to safety_helpers
* probably misra
* we might want to check it in both speed signals in case one doesn't exist on a car
* Revert "we might want to check it in both speed signals in case one doesn't exist on a car"
This reverts commit 3338931409.
* fix formatting
* 2 m/s (7 kph)
* set controls_allowed directly like other safety models
remove vehicle_state_mismatch
* obv
* Add second speed
* 2.5 m/s is 9 kph, 4 kph is the max in the field
* add quality signal
* qf signal name
* comment
* checksum matches except it goes to zero when turning the car off despite counter still active
* update comments
* now test it
* spacing
* Update board/safety/safety_ford.h
* zzzz
* not needed
* whoops
* test vehicle state mismatch
* add to safety_helpers
* probably misra
* we might want to check it in both speed signals in case one doesn't exist on a car
* Revert "we might want to check it in both speed signals in case one doesn't exist on a car"
This reverts commit 3338931409.
* fix formatting
* 2 m/s (7 kph)
* revert mismatch stuff
* adeeb
Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
* check checksum
* think pylint won't like this
* complete test
* do this
* no need
---------
Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
* assert the other signals are zeroed
* add to tja function
* fix misra
* test
* should tx
* ?
* rm line
* up here
* Update tests/safety/test_ford.py
* faster
* adjust round
* allow sending steering buttons msg to camera
The DBC lists both the IPMA and PCM as receiving modules for the `CcAslButtnCnclPress` and `CcAsllButtnResPress` signals used to cancel/resume ACC.
Sending resume to both buses is confirmed to work by three testers, now it's just down to tweaking openpilot to get high reliability.
* add test for both buses
* only send TJA to bus 2