Commit Graph

254 Commits

Author SHA1 Message Date
Mitchell Goff 3fb1a1c746 New desire model (#21729)
* New model: b822ee32-917c-4639-99f8-25be3e6aabad/900

* Enable keeps

* use new packet

* Send keep pulses once per second

* Updated model_replay_ref_commit

* New model: 0f160bf9-1bce-43e6-9785-564b2453eeac

* Bump model_replay_ref_commit

* Bump submodules

* New model: fd904bf9-5dd8-4619-8997-c5668400e078/550

* New model: fd904bf9-5dd8-4619-8997-c5668400e078/950

* No keeps

* Bumped model replay ref

Co-authored-by: Harald Schafer <harald.the.engineer@gmail.com>
old-commit-hash: e83973b9b31199c1594b9be2371a7af0c589c2d9
2021-07-26 21:11:09 -07:00
Adeeb Shihadeh e8161a42ee athena: detect no prime (#21718)
* detect no prime

* show in sidebar

* revert timeout

* clear ping param

* fix typo

Co-authored-by: Comma Device <device@comma.ai>
old-commit-hash: 7b94cf0ca79e570dd217f164b0a0ca163566eea9
2021-07-26 13:50:58 -07:00
Adeeb Shihadeh f559d321b4 bump version to 0.8.7
old-commit-hash: 973e016fa7b21b57037d15385fc3b6481cd605aa
2021-07-21 17:31:19 -07:00
Adeeb Shihadeh b39d2d441a remove wide toggle (#21669)
old-commit-hash: 4e6c268b1784f7899a91760f20142bc7809e044f
2021-07-21 00:58:42 -07:00
Adeeb Shihadeh 477e2e22d3 Revert model (#21571)
* Revert "New desire model (#21458)"

This reverts commit 9db03d2a3fefff50b738d288beadc2c2e7c3165e.

* revert rel notes
old-commit-hash: 88424ede2c5bdd2beade731717cbb0bb635034e9
2021-07-12 19:26:50 -07:00
Willem Melching c042bbf09c nav: various cleanup (#21521)
* nav: various cleanup

* eta resize instant

* show
old-commit-hash: 9ea913bcc812ed55d2f8204ced892b81f20af326
2021-07-08 14:33:58 +02:00
HaraldSchafer 7fcdd04541 New desire model (#21458)
* New model: b822ee32-917c-4639-99f8-25be3e6aabad/900

* Enable keeps

* use new packet

* Send keep pulses once per second

* Updated model_replay_ref_commit

* New model: 0f160bf9-1bce-43e6-9785-564b2453eeac

* Bump model_replay_ref_commit

Co-authored-by: mitchell <mitchellgoffpc@gmail.com>
old-commit-hash: 4230d5d2124577b86e69b136d846ca9cc3ecd746
2021-07-07 19:44:17 -07:00
HaraldSchafer 96d4bfbff3 Refactor long (#21433)
* refactor

* needs casting

* tests pass

* fix that test

* refactor in controls

* lets not go crazy

* change of names

* use constants

* better naming

* renamed

* soft constraints

* compile slack variables

* rm git conflict

* add slack variables

* unused

* new edition

* fcw

* fix tests

* dividing causes problems

* was way too slow

* take a step back

* byeeee

* for another time

* bad idxs

* little more cpu for cruise mpc

* update refs

* these limits seem fine

* rename

* test model timings fails sometimes

* add default

* save some cpu

* Revert "little more cpu for cruise mpc"

This reverts commit f0a8163ec90e8dc1eabb3c4a4268ad330d23374d.

* Revert "test model timings fails sometimes"

This reverts commit d259d845710ed2cbeb28b383e2600476527d4838.

* update refs

* less cpu

* Revert "Revert "test model timings fails sometimes""

This reverts commit e0263050d9929bfc7ee70c9788234541a4a8461c.

* Revert "less cpu"

This reverts commit 679007472bc2013e7fafb7b17de7a43d6f82359a.

* cleanup

* not too much until we clean up mpc

* more cost on jerk

* change ref

* add todo

* new ref

* indentation
old-commit-hash: be5ddd25cd3f4c8b7e46cdeecf303e2c73301003
2021-07-07 19:42:26 -07:00
Willem Melching 32cde15035 bump date in time_valid check
old-commit-hash: 86630effcfd8e1aee71e11a79937714de6379757
2021-06-30 12:18:53 +02:00
Adeeb Shihadeh d31397b84b segment regen (#21148)
* start seg regen

* send vipc

* fix up some paths

* set fp

* fix no entries

* engages

* seperate camera procs

* send real frames

* regen test routes

* nice argparser

* fix valgrind test

* move that

* fix that
old-commit-hash: 4a1aec27efb48bdba1d267c86ef66c8a044c4986
2021-06-28 21:44:40 -07:00
Adeeb Shihadeh 784601c8e1 remove lte toggle (#21392)
* remove lte toggle

* little more
old-commit-hash: a420c7ad50eec716e53537957b1439b2ce44d73e
2021-06-23 17:01:17 -07:00
Dean Lee c1aec67697 fix FileLock: fd could be closed twice (#21362)
old-commit-hash: 766f3281bb5edc8ab4e86a745e07f4034e4f249c
2021-06-22 14:05:48 -07:00
Dean Lee f03ca47c9c util.cc: refactor read_file (#21350)
old-commit-hash: ac71384a28cda46126ea5d699697bb7ab701d972
2021-06-22 13:48:41 -07:00
Willem Melching 5bc0d28708 Honda Bosch longitudinal prerequisites (#21217)
* untested changes

* set compute_gb

* community feature for good measure

* add code for rolling backwards

* init needs CarParams

* stay in elm mode until carParams is written

* fix tester present bus number

* fix can errors

* fix enableCruise flag

* print when radar disable is done

* move retry logic to controlsd

* move lookup table into carcontroller params

* cleanup brake error values

* make init return

* that should be 1

* floats

* back to no failure handling

* try simplify knockout

* bump panda

* Move flags to panda

* add warnings

* Revert "try simplify knockout"

This reverts commit 4f496245791ea6bd041d4412b96035c6b434b91c.

* add note about LoC.long_control_state

* update ref
old-commit-hash: a8fac002ae8e7c6ab37e9b1a5deb8cfcea2a71ac
2021-06-22 16:28:11 +02:00
Willem Melching dc19c670b6 nav: home/work shortcuts (#21276)
* add home/work widgets

* remove todo

* set contents from response

* turn into buttons

* add navigate button

* fix includes

* close settings on nav press

* close sidebar when closing settings

* use live api endpoint

* larger fonts

* more text fits

* only place name

* remove static response

* properly clear
old-commit-hash: c21ea8b50653bfb3b4c93e7042d7ffa62abfcf2a
2021-06-22 13:25:22 +02:00
Adeeb Shihadeh 28a9781c51 util::read_file: fix reading from sysfs and add test case (#21325)
* add sysfs test case

* Revert "util.cc: refactor read_file (#21321)"

This reverts commit 2a9ba3e867e4ba8ea8818a5be24807301a945f17.
old-commit-hash: d90d9b2280397bb113c0d5835810cbd5f483f2a1
2021-06-18 01:34:52 -07:00
Dean Lee 0ef41b3e94 util.cc: refactor read_file (#21321)
* mode read & open once

* change return statement for better readibility

* apply reviews

* can't open with ate flag
old-commit-hash: 8d5c61eefe91f9f62ae8109e2c0c32ed2778e770
2021-06-17 23:19:41 -07:00
Adeeb Shihadeh 8742d78051 fix /proc test case for util::read_file
old-commit-hash: ea6f779b3e8bf1a7918617d59534057bad54b990
2021-06-17 15:03:59 -07:00
Adeeb Shihadeh 2476a66cd9 Revert "util.cc: refactor read_file (#21295)"
This reverts commit 32dd5c2454e3f3fca028dacd24bc4758e1134295.

old-commit-hash: 7dec2064370255e00f719ea790c26bd00edbdb6f
2021-06-17 15:02:48 -07:00
Dean Lee b83e0f87a8 util.cc: refactor read_file (#21295)
* mode read & open once

* change return statement for better readibility

* apply reviews

* Update selfdrive/common/util.cc

* fix

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
old-commit-hash: 190a845505b1142166e8b25d953ab20d19276b87
2021-06-17 14:03:07 -07:00
Dean Lee 6bfc7f4ca5 common/util.cc: add unit test, fix bug in util::read_file (#21251)
* add test case for util

* fix bug in read_file

* gitignore test_util

* better test

* referer

* more

* more test

* REQUIRE size

* apply reviews

* only test binary

* simplify the test

* read  non-permission

* debug print

* remove /etc/shadow

* test read directory

* Update selfdrive/common/tests/test_util.cc

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
Co-authored-by: Willem Melching <willem.melching@gmail.com>
old-commit-hash: a873a23e0dbfe43027911acdd270610048eed74a
2021-06-16 11:01:13 +02:00
Willem Melching 196f96f057 UI: check if dongle id is valid before calling API (#21275)
old-commit-hash: e85fa7f1c933baafdecb4a52c16f2003215d423b
2021-06-15 14:10:44 +02:00
Willem Melching 807c95a0f5 Only call ensure_params_path once (#21229)
* Only call ensore_params_path once

* only ensure default params path once
old-commit-hash: fcf9f00a2abfd55e14ca299adcc911b7983cb063
2021-06-14 16:12:27 -07:00
ShaneSmiskol 23ea456f4f Fixup joystick (#21129)
* some common changes

* rename to joystick

* add alert and update controlsd to work with joystick

* update joystickd

* Update Joystick readme

* assume we have inputs

* only send gb or steer when engaged_toggle is true

* Update instructions

* fix --ip

* Easier to understand at a glance

* much better

* -a

* receive events and send msg in same loop

* always import

* Update selfdrive/controls/lib/events.py

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

* Update selfdrive/controls/lib/events.py

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

* combine logic and clean up

* use argparse

* outdated, and use normal class

* rm

* bit of a refactor

* refactor part 2 / 3

* much better (3 / 3)

* Simplify

* bump cereal and update readme

* capitalize

* Update tools/joystick/joystickd.py

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

* Update tools/joystick/joystickd.py

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

* make joystick abstraction class clearer

* use interp, clearer without comments

* no need to use apply_deadzone

* more explicit

* define btns and axes once

* split function by use_keyboard again, but simpler

* we can use handle_button as a reset function

* need to flip sign

* remove

* invert axes map for kb, easier to read the button mapping

* apply changes from review

* new lateral log for debug mode

* bump

* add saturated

* static alert

* joystick_mode

* conditionally subscribe

* Update selfdrive/controls/controlsd.py

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

* move params instantiation

* Spoof active and enabled

* Only allow car to engage

* no startup alert if joystick

* Update controlsd.py

* Should be orange not enabled, green enabled

* no more button states

* should work

* blue

* submaster conflates, so only send when we have an update

* final change

* remove msg

* clean up a bit

sort of clean up

clean up a bit

remove msg

* this was right

* Apply suggestions from code review

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

* lowercase

* suggestions from code review

* forgot laptop

* bump to latest

* fixes

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
Co-authored-by: vanillagorillaa <31773928+vanillagorillaa@users.noreply.github.com>
old-commit-hash: ae77f693a26527ffbee044f852cc4185718c2433
2021-06-11 14:33:17 -07:00
Dean Lee 147b355dde add space after function name and if statement (#21225)
old-commit-hash: e4e669bb0fc1a919dfb38800099f8e3ad52346f1
2021-06-11 10:17:52 +02:00
Willem Melching ba1a20414e nav: add page to settings (#21208)
* add navigation panel to settings

* am/pm display and dynamic width
old-commit-hash: 3c197953bc19c470547b950cd987af39909c5e9e
2021-06-10 09:59:34 +02:00
Maxime Desroches 426df0435b Convert C++ while loops from int to bool (#21214)
old-commit-hash: 03df1b08bbe6b4156e9aa0bfbc5a85717094c877
2021-06-09 21:09:21 -07:00
Dean Lee 51cf285c31 Passing arguments by reference (#21205)
old-commit-hash: ee46672d3c8c86b41fd8ae2fce9120e050b8e628
2021-06-09 14:09:02 +02:00
Dean Lee f70a79b838 Use C++ header files instead of C header files. (#21192)
* use cstring instead of string.h

* use cstdio instead of stdio.h

* remove inttypes.h

* use cstdlib instead of stdlib.h

* use cstdint instead of stdint.h

* #include <cstddef>

* cstdlib

* use cmath

* remove stddef.h

* use cassert

* use csignal

* use ctime

* use cerror

* rebase master
old-commit-hash: c53cb5d570adb82bc454fcabab458d7e7f09738c
2021-06-08 13:46:22 -07:00
Dean Lee 3a698faadc Use full include path (#21194)
old-commit-hash: b06b3ecb60c651dacf079513635f7d9d99228783
2021-06-08 12:09:30 -07:00
Adeeb Shihadeh ff5a7d7806 bump version to 0.8.6
old-commit-hash: e5ef36786f9889f7657086981437e4b67b49e552
2021-06-07 22:42:58 -07:00
Adeeb Shihadeh 7cdcb7a52a log on startup if onroad flag set (#21150)
old-commit-hash: 96271f8bc3187711c5fd879a0a4048ff9e42e979
2021-06-04 22:04:26 -07:00
Willem Melching 879a616ba8 Various nav improvements (#21133)
* various nav improvements

* use traffic aware routing

* read last position from param

* allow compute without gps when no route

* cleanup

* properly hide route

* set pitch
old-commit-hash: 14f09e4ee14ce9c0497c60fbd00bc12ab151ced6
2021-06-04 13:45:42 +02:00
Adeeb Shihadeh 61d3b1f177 disable uploading raw by default (#21128)
old-commit-hash: c76c30fa2d37d471d065e908739c69f06b43ccfe
2021-06-03 15:24:30 -07:00
ShaneSmiskol ddff72ccea Add CLEAR_ON_IGNITION_OFF param type (#21121)
old-commit-hash: 36beaf0d6895c9d69d05c3a25eab21a4d9dbb692
2021-06-03 15:21:53 -07:00
Dean Lee 497472932a Cleanup util.h (#20849)
* cleanup util.h

* fix build error:omx_encoder.cc:408: undefined reference to do_exit

* fix build error

* rebase master

* move helper functions back to util

* ExitHandleHelper->ExitHandlerHelper

* std::clamp

* struct ExitHandlerHelper to class

* rebase master

* cleanup

* restore ExitHandler

* prefer cassert
old-commit-hash: 65e0b1e699092355bfcb1f588a5a2ec949a34b77
2021-06-01 16:53:12 +02:00
Willem Melching 8c3d2ed644 Update UI fixes/improvements (#21089)
* Show latest update time

* utc

* make work more than once

* cleanup

* whitespace

* only while offroad
old-commit-hash: e66bbec52b88abbf712fdd37be3f80bc00a3c7cf
2021-05-31 15:33:49 +02:00
Adeeb Shihadeh c7c49e8e35 fix up model tests + tools (#21071)
* unlogger: send yuv stream

* fix up model test tools

* fix unlogger

* rename model replay

* bump cereal

* test in actions

* no ci for now
old-commit-hash: cf6d133638caac0d974209f92be9c200cdbcbf3f
2021-05-28 23:08:08 -07:00
Willem Melching 80ec32bcf3 loggerd: put signal in end of route sentinel (#21025)
old-commit-hash: 6e22f16ddb03eaa030d5e6a16039c193808e7586
2021-05-25 17:34:40 +02:00
Willem Melching 4d874a90ea Store almanac on ublox poweroff (#20967)
* Store almanac on ublox poweroff

* send current UTC time

* move message building to ublox_msg.h
old-commit-hash: ea5141d9096d64890a23a806612eb4edf58ea548
2021-05-20 11:43:03 +02:00
Mitchell Goff 78927e4ebb New model outputs (#20933)
* New model: 51a237cd-9c43-4281-9072-802325e6744d/950

* Added new meta outputs and proper interp for plan_t_arr

* Added meta-based trigger for FCW

* No nans in planner, separate alert for model FCW

* Cleaned up plan_t interp logic

* Added empty cameraError alert to fix unit tests

* Use the normal FCW event

* Updated filter logic

* Updated model replay ref

* Moved disengage predictions into their own cereal struct

* Updated model replay ref for new cereal structs

* Apparently this breaks stuff?

* Bumped cereal commit and model replay ref
old-commit-hash: 29cc3500a5161b4d2245b8d041f190533be4ee8e
2021-05-19 22:30:23 -07:00
Adeeb Shihadeh 29a2bef998 offroad alert for missing nvme (#20931)
* offroad alert for missing nvme

* remove that

Co-authored-by: Comma Device <device@comma.ai>
old-commit-hash: 313741062ea28a9d0601ff11399d20e9bd1a50bf
2021-05-17 13:35:24 -07:00
Willem Melching efa94a89ff 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>
old-commit-hash: 86aefbe7667f0693402c1883d286ce331e9d6215
2021-05-17 14:57:07 +02:00
Dean Lee 5609f32cee Cleanup includes (#20925)
* remove #include <pthread.h>

* remove #include<stdbool.h> for cc files

* remove #include<iostream>
old-commit-hash: 0495426535490e7d8d503af35ace7a20dc70a7bb
2021-05-17 10:31:31 +02:00
Adeeb Shihadeh 3776051148 bump version to 0.8.5
old-commit-hash: 0b39e0353c3a3076f80ff91e7773bd4e26b3baca
2021-05-15 17:09:41 -07:00
Dean Lee badc577e1d read_files_in_dir: closedir before return (#20903)
old-commit-hash: c08ee575f82b1040d99e90e44449bbb83307d8a5
2021-05-14 17:33:46 -07:00
Willem Melching 8b785f4744 store all files in /sys/fs/pstore in bootlog (#20875)
* store all files in /sys/fs/pstore in bootlog

* whitespace

* fix bootlog test
old-commit-hash: 4742f55749e59f565192589b318841f2133260ed
2021-05-12 11:15:54 +02:00
Adeeb Shihadeh 8002b848b6 offroad alert for unregistered devices (#20870)
* offroad alert for unregistered devices

* update tests

* add param

* fix stretch
old-commit-hash: b93ccc465dbc8b847b65f7d062182465344dac4d
2021-05-11 03:18:45 -07:00
Dean Lee e333e4f189 Cleanup selfdrive/ includes (#20822)
* cleanup include path

* continue

* format includes

* fix testraw.cc

* remove include path from SConstruct

* regroup

* rebase master

* almost done

* apply review

* rename FileReader.xx to filereader.xx

* rename Unlogger.x->unlogger.x

* rename FrameReader.xx -> framereader.xx

* apply reviews

* ui.h

* continue

* fix framebuffer.cc build error:mv util.h up

* full path to msm_media_info

* fix qcom2 camerad

Co-authored-by: Comma Device <device@comma.ai>
old-commit-hash: 7222d0f20dc8edfe0d2f3417d1ce7c84fbd32805
2021-05-08 22:15:17 -07:00
Willem Melching 78bf4f5867 Replace ifdef with hw abstraction layer (#20843)
* Replace ifdefs with hardware abstraction layer (#20801)

* add type to class hadwareXXX

* replace ifdefs with hardware layer

* continue

* continue

* new function get_driver_view_transform

* full path to hw.h

* fix build error setup.cc

* apply review

* fix typo

* fix deprecated error:replace deprecated fromPath with new

* fix build error

* Fixes after ifdef clenaup (#20842)

* inheritance doesnt work with static

* fix debayer

* small cleanup

* Update selfdrive/camerad/cameras/camera_common.cc

* Update selfdrive/ui/qt/offroad/settings.cc

* Update selfdrive/common/modeldata.h

* flip conditions

* fix comment

Co-authored-by: Dean Lee <deanlee3@gmail.com>
old-commit-hash: ab319d4f54a53e1a0aa1c2c0d94d56a9acef8362
2021-05-06 14:39:05 +02:00