Commit Graph

29 Commits

Author SHA1 Message Date
Dean Lee
1ecef2c6be add ui_draw_image to reduce code repetition 2020-04-13 15:38:45 -07:00
andyh2
76052865cd offroad/ui: Fix layout bugs (offroad drawing on top, settings open after drive) 2020-04-13 08:53:52 -07:00
Willem Melching
54d8f9c27b ui.cc: use thermald to decide when to go onroad (#1351)
* use thermald to decide when to go onroad

* Check for stopped

* set alert timeout to 0 when going offroad

* set controls seen to false

* Don't mark as seen when already stopped

* Don't process controlsState when stopped

* Needs free

* Small cleanup

* Remove that again

* Process controlsState when started

* Need that back
2020-04-10 16:12:39 -07:00
George Hotz
ef8aaa77b7 Remove bg_thread from ui (#1347)
* remove bg_thread

* debug print app

Co-authored-by: Comma Device <device@comma.ai>
2020-04-09 20:55:54 -07:00
Andy
35b34fb700 offroad/ui: Transparent layout mode and msgq-based layout control (#1337)
* offroadLayout

* replace broadcasts with offroadLayout socket

* apk

* set 'none' layoutstate for transparent offroad

* refactor, hide offroad when vision connected

* apk supporting transparency

* reset layout state when stopping

* apk

* cleanup includes

* permit offroad to mangae sidebar state only when vision disconnected

* apk

* use c-capnp

* always upd

* send that too

* sync layout state with offroad

* apk

* fix regression in onboarding (mock engage green border)

* apk

* bump apks

* simplify event processing

* bump cereal to master

* in case ui exited in a bad state

Co-authored-by: Comma Device <device@comma.ai>
2020-04-09 19:28:11 -07:00
Dean Lee
ee52046957 remove unnecessary nvgLineTo (#1333) 2020-04-08 15:10:42 -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
Comma Device
6abbda1467 fix background on computer ui 2020-04-01 23:01:17 +00:00
Willem Melching
202a4c2011 Add binary to display text (#1301)
* add binary to display text

* fake text needs status too

* Rename to TextWindow

Co-authored-by: Comma Device <device@comma.ai>
2020-03-31 20:14:26 -07:00
eFini
4311550293 only run system() command when vol has changed (#1148)
* only run system command when vol has changed

* fix indent
2020-03-30 14:41:17 -07:00
eFini
47f17622d9 paint.cc uses color defined in ui.hpp (#1261)
* pain.cc uses color defined in ui.hpp

* use macro
2020-03-27 11:00:42 -07:00
DeanLee
993b0e9427 repace nvgFontFace with nvgFontFaceId (#1279) 2020-03-27 11:00:07 -07:00
George Hotz
f0779d86e4 fix offroad processing events in bg (#1266)
* fix offroad processing events in bg

* first run of ui

* actually, we don't need that at all

Co-authored-by: Comma Device <device@comma.ai>
2020-03-23 14:16:51 -07:00
Comma Device
50d2dc24d2 fix multiline strings in ui_draw_sidebar_metric 2020-03-23 20:11:48 +00:00
Greg Hogan
16ad4bf58b remove storage metric from sidebar (#1254) 2020-03-20 10:35:58 -07:00
Willem Melching
e69e0486ff camerad zmq_poll, also recover from EAGAIN 2020-03-17 13:40:07 -07:00
Willem Melching
a4c94128c2 No logging on EINTR, and log all the errnos 2020-03-16 14:58:21 -07:00
Willem Melching
439b4625b6 Add logging to poll EINTR handling, add another catch in camerad/main.cc 2020-03-16 14:55:12 -07:00
Andrew Valish
0aafd67b56 fix sidebar shadow in network settings (#1245) 2020-03-16 13:02:45 -07:00
Andrew Valish
fa7abadc80 filter ublox packets for sidebar (#1233) 2020-03-11 14:28:29 -07:00
Andrew Valish
5ba6beed17 Refactor frame (#1192)
* start drawing new sidebar, add assets

* add thermal to ui, draw network_type and battery

* draw sidebar metrics, add freeSpace and paTemp

* draw static panda metric and network strength, start ubloxGnss messaging

* use array for network_img

* start sidebar touch events

* prevent multiple touch events with touch_timeout

* filter old touches, isolate sidebar events

* add hwType check with timeout for panda metric

* cleanup touch poll, handle vision touch, remove frame and black apks

* cleanup per willem comments

* update offroad, only read active_app from cereal

* tweak sidebar behavior, show active app status

* update offroad apk

* read networkstrength from thermal in sidebar
2020-03-09 19:13:32 -07: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
Willem Melching
049f2d0e1b Don't add 2.7 m to lead distance in ui. The reference frame shifted a while ago. 2020-02-20 14:29:09 -08:00
Arne Schwarck
175243af40 Draw leadTwo chevron in ui (#1133)
* Add leadTwo

* Add leadTwo

* Draw leadTwo car indicator

* Reuse leaddatad

* refactor draw_lead

No idea if this is the correct syntax

* Python is too good to us

Add ;

* Only show if more than 3m apart

* Delete unused scene
2020-02-20 14:27:11 -08:00
George Hotz
811b3b7a9a Fix ui on mac (#1044)
* remove line_shader dead code

* fix glfwCreateWindow

* don't assert on ipc socket failure

* window now appears on mac
2020-02-02 22:19:26 -08:00
George Hotz
f72f78f2b9 Support scons build on Mac (#1034)
* fix clock and add Darwin sconstruct

* it builds, this changes should be simplifications too

* fix boardd build

* that's the real type of EGLClientBuffer

* remove extra lines

* ui needs opencl on phone
2020-02-01 23:36:50 -08:00
Arne Schwarck
855abbd99e Subsock no longer exsists (#987)
* Subsock no longer exsists

use the new SubSocket as SubSock has been removed

* fix poller syntax

update to the new syntax and remove unused messaging library
2020-01-21 11:25:12 -08:00
George Hotz
a3dde4e7fe ui was gitignored 2020-01-17 17:34:23 -08:00
George Hotz
aeb2fff068 selfdrive/ui 2020-01-17 11:05:23 -08:00