Commit Graph

29 Commits (spacecruft)

Author SHA1 Message Date
Willem Melching 86aefbe766
Mapbox widget (#20751)
* squash mapbox stuff

* only hacks for pc

* no hack there

* only update when needed

* get destination from param

* no need for user agent

* add athena method

* change nav path color

* layout cleanups

* margin top

* add build scripts

* rename header file

* set pitch

* fix icon blinking

* keep both options

* draw on top to fix last blinking

* only recomput with gps

* fix include

* put map in onroadwidget

* update mapbox plugin to allow specifying directions url

* cycle through views

* dynamic resize

* only when present

* add map_helpers

* whitespace

* small fixes

* let scons decide

* update setup files

* implicit dependency

* fix alerts

* Update selfdrive/ui/SConscript

* move clearLayout to util.h

* only build when map.cc present

* move maps to own folder

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
2021-05-17 14:57:07 +02:00
Willem Melching f59c6d379d athenad: catch WebSocketException 2021-05-12 16:03:56 +02:00
Willem Melching 75c0594cdb athenad: catch connection/timeoutError 2021-05-12 16:01:31 +02:00
Adeeb Shihadeh b93ccc465d
offroad alert for unregistered devices (#20870)
* offroad alert for unregistered devices

* update tests

* add param

* fix stretch
2021-05-11 03:18:45 -07:00
Adeeb Shihadeh 5b764ab477
registration unit tests (#20792)
* start tests

* more test

* done
2021-05-01 17:16:58 -07:00
Adeeb Shihadeh 47ad2a485f
disable sentry for devices without a dongle ID (#20729)
* disable sentry for devices without a dongle ID

* import pc

* unused
2021-04-23 11:29:38 -07:00
Willem Melching ea0e611872
Switch to new sentry_sdk (#20690)
* remove unused crash.install

* use sentry_sdk in crash.py

* athena crashes dont rely on excepthook

* make default crash handler work

* make it work in athena

* fixup tombstoned
2021-04-22 15:24:35 +02:00
Greg Hogan 1e3f8b014e
logging cleanup (#20502)
* switch some uploader messages to debug log

* use allow_sleep

* log when not request or response

* test both with params and without params
2021-03-26 17:36:01 -07:00
Greg Hogan b88ca985d6 fix athena calls that do not use params 2021-03-25 17:58:49 -07:00
Greg Hogan 3d48bd934d
log to file and send through athena (#20250)
* log to file and send through athena

* rename logging level

* pass thru log formatter

* logMessage is TEXT

* send queue always strings

* switch to xattr and lower priority queue

* enable cloud logging for devices

* time or size based log rotation

* basename -> dirname

* remove HARDWARE.get_cloudlog_enabled

* fix errors

* fix another exception

* xattrs need to be bytes

* sending works

* cleanup files at start

* add id and adjust formatting

* do not send active log file

* better names

* separate log formatters

* fix formatter super init

* fix log file order

* ensure file always has file formatter

* i see why there was no formatter

* apply same formatting to cpp log msgs

* apply same formatting to cpp log msgs

* update queue names in tests

* strip deprecated keys in STATUS_PACKET

* strip DEPRECATED from dict recursively

* athena log queue test

* instanceof instead of type

* isinstance instead of type

* use super

* remove logentries

* last_scan param unused

* comment about special log msg attr names

* add dict_helpers.py to release files

* use monotonic time and counter for log rotation

* update for adjusted log file naming

* use monotonic clock for tracking last log file scan
2021-03-25 13:30:09 -07:00
Willem Melching 5a3b511306
Manager cleanup (#20231)
* move manager in folder

* inital refactor

* call start

* small cleanup

* add comments

* use self.signal()

* order shouldnt matter

* newlines

* add helpers

* newlines

* add process config

* split out build part of manager

* this should fix most tests

* no sensord on pc

* dont start athena

* remove comment

* fix old athena test

* fix inject model

* fix test car models

* should be not none

* fix helpers exitcode

* ignore manage_athenad

* Use time.monotonic()

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>

* combine init, remove spinner

* move manager test

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
2021-03-05 11:03:23 +01: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
Adeeb Shihadeh c9679222ae
add device type to clouglog ctx (#19890)
* add device type to clouglog ctx

* remove is_eon

* str
2021-01-22 20:02:48 -08:00
Adeeb Shihadeh 7c82bac27e
athena fixups (#19791)
* fix leak

* assert raises

* no q

* guess the queue did something
2021-01-16 15:36:10 -08:00
Adeeb Shihadeh ffa7e0cbdb
manager tests + make all processes exit cleanly (#19595)
* manager tests

* logcatd exits cleanly

* sigint

* boardd

* multiple dbus connections hangs for some reason

* clocksd proclogd

* network type from thermal

* fix tests

* fix android logcatd

* fix mac

* fix mac proclogd

* move on device athena tests

* build first

* build first

Co-authored-by: Comma Device <device@comma.ai>
2020-12-29 22:32:03 -08:00
Adeeb Shihadeh 63cdf2a70c increase athena test timeout 2020-12-19 16:13:29 -08:00
Adeeb Shihadeh 8674b023ba
HW abstraction layer (#19530)
* start hw refactor

* move that

* pins

* put that back
2020-12-16 21:30:23 -08:00
Greg Hogan 7a121862a8
athenad: add getNetworkType (#19517) 2020-12-15 23:25:52 -08: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
Adeeb 367155168a
Update Flake8 config (#1624)
* update flake8 checks

* add E502

* no whitespace warnings

* fix violations

* no W391

Co-authored-by: Jason Young <jason@comma.ai>
2020-06-03 16:13:34 -07:00
Willem Melching 843a64c72f
Make pylint more strict (#1626)
* make pylint more strict

* cleanup in progress

* done cleaning up

* no opendbc
2020-06-02 16:29:32 -07:00
Willem Melching 3d08dcc3b2
Run mypy commit hook (#1591)
* run mypy commit hook

* fix mypy errors
2020-05-28 15:05:04 -07:00
William aef01f4bdf
Shebang Fix (#1477)
* Shebang Fix

Per George's "I'd merge a PR replacing the 4 python3.7 with python3" on Discord. George updated Python to 3.8.2 for webcam tools, which broke manager from launching. Instead of chasing the exact version, it seems more reasonable to fall back to 3.

* More Python3.7's
2020-05-08 18:08:11 -07:00
George Hotz 1295cfe06c
Using lgtm.com and fixing found alerts (#1452)
* lgtm in readme, and mac nui fixes

* call super inits in radars

* unused imports, dup lines

* more radars, more unused imports

* pass CP into RadarInterfaceBase

* more fixups

* unused imports

* delete unused lines

* ugh, new unused import

Co-authored-by: George Hotz <geohot@gmail.com>
2020-05-02 12:07:34 -07:00
Andy 41bb3ac7ca
Sidebar Connectivity Status (#1268)
* store athena connected-at time

* refactor

* deref

* dt import

* Athena status based on last ping time param

* upd test for pingtime

* lower error timeout
2020-04-05 11:06:49 -07:00
Shane Smiskol 6ff881f789
initialize all messages in 1 line (#1206) 2020-03-05 17:32:52 -08:00
Adeeb e8cb6ea06a
Abstract common events + event cleanup (#1129)
* too many if

* unused

* whitespace

* key

* sefldrive/car/*

* no more gctx

* lower

* start abstracting common events

* all cars

* start small

* all cars

* reverse gear

* wrongCarMode

* wrongGear

* espDisabled

* steerUnvailable

* make linter happy

* c isn't used

* fix esp_disabled in VW

* update ref

* more red

* more cleanup

* fix subaru

* update ref
2020-02-20 16:22:25 -08:00
George Hotz c42e2ecc50
manager runs on Mac, and other openpilot for PC fixes (#1037)
* use the openpilot/persist directory on PC

* manager runs on mac

* sim runs w/o carla

* fix params location in test

* that rmtree can fail and it's okay

* refactor params clear functionality

* set PARAMS_PATH
2020-02-02 12:15:02 -08:00
George Hotz 341c0da987 selfdrive/athenad 2020-01-17 10:54:24 -08:00