Commit Graph

62 Commits

Author SHA1 Message Date
Adeeb Shihadeh
6b83724c50 jenkins: run tests with pytest (#29143)
* jenkins: run tests with pytest

* typo

* fix
2023-07-25 17:06:43 -07:00
Adeeb Shihadeh
2ff33663a7 bump panda (#29066)
* bump panda

* update bootstub
2023-07-20 15:29:29 -07:00
Robbe Derks
70bbb94dc5 Panda logs (#28511)
* log in pandaStates

* Revert "log in pandaStates"

This reverts commit 87ee283ac45c2eeed94d9a958927e3072ec4460f.

* log to param

* dumps datetime

* cloudlog instead

* add truncation

* fix

* try isotimestamp

* duh

* more fixes

* should be __class__

* add some time to account for log gathering

* use new fast interface

* Revert "add some time to account for log gathering"

This reverts commit 2c08ad48052dfc0546530059a0cda03b04c4939a.

* cleanup

* simple test

* fix wrong serial

---------

Co-authored-by: Comma Device <device@comma.ai>
Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
2023-07-19 14:24:57 -07:00
Adeeb Shihadeh
2720fdf2a1 pandad: check comms protocol version (#28983)
* proto version check

* bump panda

* update bootstub

* test

* bump panda

* fix that

* bump panda

* fix test case

* more fix

---------

Co-authored-by: Comma Device <device@comma.ai>
2023-07-16 21:33:24 -07:00
Adeeb Shihadeh
a46ed955e6 pandad: enable tres release -> bootstub test (#28930)
enable tres

Co-authored-by: Comma Device <device@comma.ai>
2023-07-15 22:22:56 -07:00
Adeeb Shihadeh
28980cf4c6 pandad: test release -> devel bootstub reflash (#28330)
* test

* release bootstubs

* rm that

* fixup

* skip earlier

---------

Co-authored-by: Comma Device <device@comma.ai>
2023-06-07 20:25:15 -07:00
Adeeb Shihadeh
e4a37620ee boardd: handle nack on tx buffer full (#28241)
* boardd: handle nack on tx buffer full

* print pandaStates

* rx buffer too small

* connect timeout

---------

Co-authored-by: Comma Device <device@comma.ai>
2023-05-19 23:24:52 -07:00
Adeeb Shihadeh
2014b10ec3 boardd: longer loopback test (#28239)
Co-authored-by: Comma Device <device@comma.ai>
2023-05-19 17:36:30 -07:00
Adeeb Shihadeh
437fcc6582 fix loopback test safety setting (#28184)
* fix loopback safety setting

* pandad: catch and log all exceptions

---------

Co-authored-by: Comma Device <device@comma.ai>
2023-05-13 21:05:00 -07:00
Shane Smiskol
d738f66711 update boardd blocking comment 2023-05-09 17:27:09 -07:00
Adeeb Shihadeh
4fe1b638f8 pandad: improve startup time (#28137)
* pandad: improve startup time

* add test

* reset with gpio

* adjust threshold

* fix

* no panda

* fix

* check unknown

* increase for boardd

---------

Co-authored-by: Comma Device <device@comma.ai>
2023-05-09 15:44:53 -07:00
Adeeb Shihadeh
f832a71038 pandad: wait for internal panda to come up (#27705)
* pandad: wait for internal panda to come up

* test

* more checks
2023-04-14 14:18:13 -07:00
Adeeb Shihadeh
ff89184823 tizi tests in jenkins (#27810)
* add

* mv there for now

* mv

* single panda

* move into parallel

* longer timeout for dfu

---------

Co-authored-by: Comma Device <device@comma.ai>
2023-04-05 11:07:42 -07:00
Shane Smiskol
42449b482d boardd: ability to switch between ELM safety params (#27656)
* indecisive

* rename to generic FW query

* remove code and update comment

* we need this to start off, unless we set multiplexing immediately

* draft

* draft 2

* try that

* can't do this either, boardd might read Enabled after removing, but before setting new Request param

* this should work

* use one less param

* fix params

* match behavior (set all pandas to safety param of 1, disabling multiplexing for fingerprinting

* clean up (some tests may temp break)

* fix param name and sort

* time it

* yes it does matter

* add to hyundai's bus 5 query

* remove hyundai for now

* this should work

* clean up

* clean up

* flip argument around, clean up

* fix test_startup

* some clean up

* rm line

* comment makes more sense

* required typing

* clean up common type

* comments

* Update selfdrive/car/car_helpers.py

* line

* whoops, need to set before vin!

* fix debug

* annoying

* more debugging

* bug fix (needs both keys always)

* debuGG

debuGG

* Revert "debuGG"

This reverts commit 55b2f429324c0b92d5cfb2cabf8b20db1e166248.

* Revert "more debugging"

This reverts commit 02934c3403ad5270f03093508b704c151d1ccb2a.

* Revert "annoying"

This reverts commit 8b4e5e09989f9a0217e3ec1c0ba68735929b7366.

* clean that up

* bumpback

* bumpback

* every second write param

* flip

* stuff

* move up?

* fix timing out in CI

* rm
2023-03-23 00:14:31 -07:00
Adeeb Shihadeh
f7c15c1708 pandad unit tests (#27516)
* pandad unit tests

* only one

* in bootstub

* run in jenkins

* phone only
2023-03-07 11:05:20 -08:00
Adeeb Shihadeh
e07865fe4d boardd: update loopback test with new param 2023-02-01 20:11:40 -08:00
Robbe Derks
3136985b95 No more magic for the can chunks (#26861)
* remove magic and add checksum

* add comms reset

* bump submodule
2023-01-13 15:01:55 -08:00
Robbe Derks
fee6f2efac Simple CAN chunks (#25373)
* simple chunks

* more sizeofs

* fix unit tests

* bump panda

* bump panda

* don't fail for too little data

* bump panda

* bump panda

* bump panda

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
2022-12-01 09:12:16 -08:00
Adeeb Shihadeh
c3e3047080 boardd: cleanup defs from panda (#26628)
* more stuff

* bump pnada
2022-11-29 16:05:46 -08:00
Adeeb Shihadeh
ddb7f91c9b remove old boardd stuff 2022-08-19 23:09:21 -07:00
Adeeb Shihadeh
0fce5d9045 Move a bunch of stuff to system/ part 3 (#24829)
* move swaglog.py

* timezoned

* logmessaged

* version.py

* fix linter
2022-06-11 23:19:27 -07:00
Adeeb Shihadeh
1139fe507b Move selfdrive/hardware/ to system/ (#24725)
* move hardware to system/

* fix mypy
2022-06-11 16:38:24 -07:00
Adeeb Shihadeh
cb8885cffb Merge common/ and selfdrive/common (#24556)
* Merge common/ and selfdrive/common

* fix that

* fix version

* fix unit tests
2022-05-18 14:11:57 -07:00
Adeeb Shihadeh
8af20af66d pylint: enforce indentation (W0311) (#24039)
* pylint: enforce indentation (W0311)

* few more
2022-03-24 23:23:29 -07:00
Ewout ter Hoeven
332f568a82 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>
2021-12-24 11:18:39 -08:00
Igor Biletskyy
285addeef2 Revert "boardd: new class USBDevice (#23015)"
This reverts commit 4061f50da3.
2021-12-16 17:11:45 -08:00
Dean Lee
4061f50da3 boardd: new class USBDevice (#23015)
* USBDevice

* merge master

* rebase master

* add to fiels_common

* inline functions

* namespace

* init err

* remove nested if

* cleanup

* bump panda for branch

* change includes

* bump panda branch

* change name

* bump master panda

Co-authored-by: Igor Biletskyy <briskspirit@users.noreply.github.com>
Co-authored-by: Igor Biletskyy <bs@privacy.im>
2021-12-16 16:53:48 -08:00
Dean Lee
599c07e027 panda: refactor can_recv (#22977)
* refactor

* use macro

* rebase master

* fix incorrect chunk_len

* cleanup

* type fix

* lines

* while

Co-authored-by: Igor Biletksyy <bs@privacy.im>
2021-12-02 16:28:38 -08:00
Igor Biletskyy
65ca9be82a boardd: split usbprotocol unittest and fix paren order in data length assert (#23065) 2021-11-29 15:34:33 -08:00
Dean Lee
c77354009c panda: add unit tests for usb protocol (pack/unpack) (#22955)
* prepare for unit tests

* add to selfdrive_tests.yaml

* test header

* test chunk count

* rename test function

* continue

* don't check chunks count

* test recv_can

* continue

* small cleanup

* merge master

* cleanup

* rename functions

* test different packet size

* fix operator precedence problem

* refactor unpack_can_buffer

* cleanup test

* cleanup unpack_can_buffer

* add test for multiple pandas

* rename to test_panda

* restore test_boardd

* rename to test_boardd_usbprotocol

* fix typo

* bus_offset = [0,4]

* change src

* use USBPACKET_MAX_SIZE
2021-11-23 20:15:22 -08:00
Adeeb Shihadeh
e13630dfee faster jenkins (#22973)
Co-authored-by: Comma Device <device@comma.ai>
2021-11-18 23:43:09 -08:00
Dean Lee
841fb93def boardd/can_recv_thread: improve caching for can_frame (#22944)
* better cache

* use emplace to remove copy&realloc

* rebase master
2021-11-17 17:54:14 -08:00
Adeeb Shihadeh
e8598f7455 add multipanda to loopback tests (#22900) 2021-11-13 17:39:51 -08:00
Adeeb Shihadeh
93d87cdc6f test_boardd: don't modify environment at import time 2021-10-25 09:47:07 -07:00
Adeeb Shihadeh
b5960b9dc8 move nose tests to unittest (#22665)
* move to unittest

* boardd loopback

* no more nose

* phone only

* fix panda decorator
2021-10-25 09:44:04 -07:00
Robbe Derks
91987f38d4 Make pandaState and safetyMode a list (#22454)
* wip: move to pandaStates

* bump cereal

* wip: SafetyMode struct

* move to safetyMode

* fix typo

* this can be None

* fix potential empty pandaStates list

* fix thermald

* fix controlsd

* rename safetyModes to safetyConfigs

* update process_replay

* fix test_models

* bump cereal
2021-10-08 17:54:34 +02:00
Willem Melching
a60f3c6a35 move acados deps out of devpackages (#22376)
* move acados deps out of devpackages

* fix new pylint errors
2021-09-29 23:20:33 +02:00
Adeeb Shihadeh
f9a961f6fb delay controls start (#20761)
* delay controls start

* shouldn't need this stuff anymore

* only delay board

* bail after 2s

* fix loopback test

* fix process replay

* update refs

* bump cereal

Co-authored-by: Comma Device <device@comma.ai>
2021-04-30 13:55:17 -07:00
Adeeb Shihadeh
312b681a46 cereal cleanup part 2 (#20092)
* car stuff

* thermal

* Revert "car stuff"

This reverts commit 77fd1c65ebd01abfa8493ae12c9e6b14f7ada976.

* panda state

* camera stuff

* start deg

* most is building

* builds

* planner + controls run

* fix up paramsd

* cleanup

* process replay passes

* fix webcam build

* camerad

* no more frame

* thermald

* ui

* paramsd

* camera replay

* fix long tests

* fix camerad tests

* maxSteeringAngle

* bump cereal

* more frame

* cereal master
2021-02-16 21:39:32 -08:00
Robbe Derks
935b9ceb05 Add back replay_many script for unlogging over jungles 2021-02-01 15:54:19 +01:00
Adeeb Shihadeh
6e70baa306 actually wait for boardd to start 2021-01-26 15:09:09 -08:00
Adeeb Shihadeh
144227d3d3 wait for pandad to start boardd 2021-01-26 13:39:15 -08:00
Adeeb Shihadeh
59f4ea9fe5 fix boardd loopback test after #19880 2021-01-26 12:12:10 -08:00
Adeeb Shihadeh
e6478c6b35 better can replay script 2021-01-14 17:49:17 -08:00
Adeeb Shihadeh
6c86afee16 Qt spinner (#2494)
* move android spinner

* qt spinner

* rotation

* nothing by default

* spin spin

* fix rotate

* style

* spinner for all

* -2

* unused
2020-11-06 18:44:04 -08:00
Willem Melching
3dd9448981 Params path only in one place (#2344)
* fix params paths

* Qcom & qcom2

* This env variable is not used anywhere

* params path in only one place

* fix other PARAMS_PATH references

* absolute path is probably better
2020-10-15 13:15:22 +02:00
Willem Melching
c7152d5419 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
2020-08-26 14:57:17 +02:00
Willem Melching
80acb32825 Panda abstraction layer in boardd (#1919)
* start on panda abstraction layer

* handle bulk transfer in library

* Safety model abstraction

* Abstract hw type into library

* Handle disconnect

* RTC stuff

* Fan control

* Health

* Panda fw version

* Read serial

* Power saving

* Power mode

* Cleanup pigeon thread init

* Rename safety setter variable name

* Remove comment

* Unused global cleanup

* malloc -> new

* whitespace

* Use std::thread

* Use std::thread for safety setter

* Cleanup igntion_last global

* Heartbeat

* logd

* More global cleanup

* Put back sleep

* ir pwr

* Always broadcast health

* init struct with zeroes

* Fix eon build

* fix race condition

* fix Adeebs comments

* abstract can send and receive
2020-07-31 23:14:31 +02:00
Willem Melching
0ac2f6c470 make sure boardd loopback test can run standalone 2020-07-23 15:31:32 +02:00
Adeeb Shihadeh
3ff373ed0d add UI for boardd loopback test 2020-07-15 11:53:42 -07:00