Robbe Derks
3ccf712ac9
small typo
2021-09-24 10:23:41 +02:00
Adeeb Shihadeh
0f8c6f130b
add log docs
2021-09-23 14:41:35 -07:00
ntegan1
54b5972cf6
Upload when on ethernet ( #22188 )
...
in addition to when on wifi
Co-authored-by: ntegan <nick@egan.gg>
2021-09-10 12:05:12 -07:00
Willem Melching
377fe84948
remove loggerd todo about encodeIdx decimation
2021-09-08 12:16:16 -07:00
Dean Lee
8bca70878f
loggerd: remove obsolete ethernetsniffer.py ( #22139 )
2021-09-06 12:11:19 -07:00
Dean Lee
5a8ca8b449
loggerd: remove obsolete testraw.cc ( #22138 )
2021-09-06 12:10:12 -07:00
Willem Melching
48035e9535
Disable encoder sync logic if only one rotate camera present ( #22107 )
...
* disable sync logic if only one rotate camera
* consistent brackets
2021-09-01 23:08:06 -07:00
Willem Melching
a93271a518
Ensure that first segment starts with all cameras on the same frameId ( #22096 )
...
* test that segment starts with the same frame id
* improve test
* add sync logic
* atomic max
* review comments
2021-09-01 14:28:50 -07:00
Dean Lee
f02c8d0e2c
Handle EINTR for all syscalls that can return it ( #21948 )
2021-08-31 16:22:56 -07:00
Dean Lee
d9baaf7eb9
loggerd: create encoder threads from cameras_logged ( #21875 )
2021-08-30 19:33:00 -07:00
Dean Lee
935cbd3139
LoggerState: test cases ( #21855 )
...
* test multiple threads writing to log
* fix typo
* use util::getenv
* check INIT_DATA and SENTINEL
* test END_OF_SEGMENT
* add comment
* test multiple threads logging and rotation
* cleanup
* update
* LoggerHandle:quick fix
* cleanup
* revert test_loggerd.py
* refactor test case
* check lock file
* check refcnt after close
* test_runner.cc
d
* int eixt_signal
2021-08-30 17:12:09 -07:00
Willem Melching
dddab597bc
Less open file permissions ( #21922 )
...
* Less open file permissions
* add test back
* remove params test for permissions
* remove umask
* bump cereal
Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
2021-08-28 18:25:05 -07:00
Adeeb Shihadeh
54a4eeb0fc
Revert "tici: give loggerd rt priority ( #21503 )"
...
This reverts commit 7e2752c878
.
2021-08-22 16:57:53 -07:00
Adeeb Shihadeh
7e2752c878
tici: give loggerd rt priority ( #21503 )
...
* give loggerd rt priority
* assert
* little more
Co-authored-by: Comma Device <device@comma.ai>
2021-08-20 21:27:31 -07:00
Dean Lee
c6a34dd9f7
capnp:Text::Reader: use implicit conversion from string ( #21980 )
2021-08-19 13:49:08 -07:00
Dean Lee
b66e8adbef
BZFile: handle EINTR on BZ2_bzWrite ( #21949 )
2021-08-18 12:08:07 +02:00
Dean Lee
4625098a79
enclose macro arguments in parentheses ( #21947 )
...
* macro argument should be enclosed in parentheses
* CL_CHECK
2021-08-18 10:56:37 +02:00
Adeeb Shihadeh
1d4b19f739
use same env variable for loggerd, deleter, and uploader
2021-08-07 18:58:11 -07:00
Willem Melching
a39873872d
refactor loggerd: trigger rotate in encoder thread ( #21860 )
...
* trigger rotate in eoncode thread
* rotate in time
* lgtm
* dcam trigger rotate on C3
* check trigger rotate field
* Use >=
* add rotator thread
* set cnt to 0
* test encodeIdx is increasing across segments
* test both segmentId and encodeId
* fix encodeIdx
* no thread needed
* add log for failed to encode
* stricter C3 test, dont check start encodeId on C2 dcam
* only update last_camera_seen_tms when considered for rotate
Co-authored-by: deanlee <deanlee3@gmail.com>
2021-08-06 11:10:33 +02:00
Dean Lee
fefc70b4ca
hw.h: move Hardware-related paths to namespace Path ( #21826 )
...
* refactor getenv and path
* apply review
2021-08-04 13:29:03 +02:00
George Hotz
8354cfc53c
loggerd: implement DONT_LOG flag ( #21832 )
...
* implement DONT_LOG flag
* better typing
2021-08-02 20:16:38 -07:00
Adeeb Shihadeh
d748b44f48
fix loggerd test failure when camerad is slow to start
2021-08-02 09:10:29 -07:00
Dean Lee
fecdf16f6b
logger.cc/logger_build_init_data(): reuse params_map ( #21811 )
...
* faster log params
* Update selfdrive/loggerd/logger.cc
* fix build
Co-authored-by: Willem Melching <willem.melching@gmail.com>
2021-08-02 11:21:12 +02:00
Dean Lee
11ffbc6936
util/read_files_in_dir: return map by value ( #21815 )
2021-08-02 10:59:54 +02:00
Adeeb Shihadeh
48652db706
debug msg for loggerd tests
2021-07-28 14:01:27 -07:00
Adeeb Shihadeh
6b69032807
publish uploader state ( #21580 )
...
* uploader state
* add time
* bump
* populate whole packet
* bump cereal
* revert
Co-authored-by: Comma Device <device@comma.ai>
2021-07-13 17:18:10 -07:00
Willem Melching
dd128f5916
loggerd: power failure print sync done
2021-07-12 12:28:07 +02:00
Adeeb Shihadeh
d8411e7a62
fix qlog decimation calculation in loggerd tests
2021-07-10 23:20:15 -07:00
Greg Hogan
d066b8f7e8
upload can only create ( #21513 )
2021-07-07 18:28:06 -07:00
Adeeb Shihadeh
0bfd994f73
fast jenkins ( #21472 )
...
* speed up setup
* speedup onroad test
* .git doesn't like inplace
* tici2
* no inplace
* revert
* fix
* that one too
2021-07-02 16:29:57 -07:00
Adeeb Shihadeh
4a1aec27ef
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
2021-06-28 21:44:40 -07:00
Dean Lee
e4e669bb0f
add space after function name and if statement ( #21225 )
2021-06-11 10:17:52 +02:00
Dean Lee
c53cb5d570
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
2021-06-08 13:46:22 -07:00
Adeeb Shihadeh
c76c30fa2d
disable uploading raw by default ( #21128 )
2021-06-03 15:24:30 -07:00
Willem Melching
129c760e4f
deleter.py: delete boot and crash folders last ( #21028 )
2021-06-01 14:08:08 -07:00
Dean Lee
65e0b1e699
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
2021-06-01 16:53:12 +02:00
Willem Melching
6e22f16ddb
loggerd: put signal in end of route sentinel ( #21025 )
2021-05-25 17:34:40 +02:00
Adeeb Shihadeh
ec976b3b44
log OS version in initData ( #20979 )
2021-05-20 13:00:34 -07:00
Dean Lee
0495426535
Cleanup includes ( #20925 )
...
* remove #include <pthread.h>
* remove #include<stdbool.h> for cc files
* remove #include<iostream>
2021-05-17 10:31:31 +02:00
Adeeb Shihadeh
2bc9b97aba
bootlog: setup cloudlog on keywords ( #20898 )
...
* bootlog: setup cloudlog on keywords
* just log
2021-05-13 23:02:08 -07:00
Willem Melching
4742f55749
store all files in /sys/fs/pstore in bootlog ( #20875 )
...
* store all files in /sys/fs/pstore in bootlog
* whitespace
* fix bootlog test
2021-05-12 11:15:54 +02:00
Dean Lee
7222d0f20d
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>
2021-05-08 22:15:17 -07:00
Willem Melching
ab319d4f54
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>
2021-05-06 14:39:05 +02:00
Willem Melching
3a95d3ccaa
Revert "Replace ifdefs with hardware abstraction layer ( #20801 )"
...
This reverts commit 757d2923d2
.
2021-05-06 12:29:30 +02:00
Dean Lee
757d2923d2
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
2021-05-06 11:41:46 +02:00
Adeeb Shihadeh
ec414e2eb1
set nice values for non RT processes ( #20812 )
...
* set nice values for non RT processes
* builds
* fix qcom build
Co-authored-by: Comma Device <device@comma.ai>
2021-05-04 22:00:11 -07:00
Dean Lee
27d3f820bf
Params: move keys from cython to cc ( #20814 )
...
* move keys from cython to cc
* consistency
* passes tests
* more consistency
Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
2021-05-04 10:49:26 -07:00
Adeeb Shihadeh
8a280fbb8e
bump cereal
2021-05-03 20:47:11 -07:00
Adeeb Shihadeh
9813c0ddbd
log encodeIdx packets in qlog ( #20738 )
2021-04-23 16:14:45 -07:00
Adeeb Shihadeh
1786d04239
handle unregistered devices ( #20728 )
...
* handle unregistered devices
* cleanup
* no uploader or athena
* clean up
2021-04-22 21:03:57 -07:00
Adeeb Shihadeh
36d8c89ebf
enable --as-needed linking ( #20619 )
...
* only link as needed
* a few more
* need to fix order
* everywhre
* fix mac
* update spinner + text
* fix c2 build
* another fix
Co-authored-by: Comma Device <device@comma.ai>
2021-04-08 11:17:07 -07:00
Willem Melching
c4e2d374c9
More encoder test cleanup ( #20623 )
...
* more encode test cleanup
* fix check at end of function
2021-04-08 17:48:57 +02:00
Willem Melching
ec5465ffd5
check encodeIdx in loggerd test ( #20621 )
2021-04-08 16:50:48 +02:00
Willem Melching
ae094042ad
add putBool/getBool wrappers to cython params class ( #20611 )
...
* add putBool/getBool wrappers to cython class
* use new API
* some more puts
* fix mockparams arguments
* add get_bool to MockParams
* typo
2021-04-07 15:36:37 +02:00
Adeeb Shihadeh
538df2596d
increase log level of NVME cloudlog
2021-04-02 21:43:58 -07:00
Dean Lee
98e55996f6
Params: python-like interface ( #20506 )
...
* rebase master
* delete outdated test_params.c
* putBool & more robust getBool
* putBool(SshEnabled)
2021-03-30 12:54:59 +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
Adeeb Shihadeh
33500bf23f
log when nvme isn't mounted ( #20428 )
...
Co-authored-by: Comma Device <device@comma.ai>
2021-03-21 23:12:09 -07:00
Willem Melching
0a88304e8d
use class AlignedBuffer ( #20388 )
...
* use class AlignedBuffer from cereal (#20343 )
* AlignedBuffer
* move AlignedBuffer to cereal/messaging.hpp
* rename function aligned to get
* use overloaded function AlignedBuffer:: get(Message *)
* use AlignedBuffer
Co-authored-by: Dean Lee <deanlee3@gmail.com>
2021-03-17 14:43:23 +01:00
Willem Melching
e3ad952902
Revert "use class AlignedBuffer from cereal ( #20343 )"
...
This reverts commit 7aa379e123
.
2021-03-16 20:21:03 +01:00
Dean Lee
7aa379e123
use class AlignedBuffer from cereal ( #20343 )
...
* AlignedBuffer
* move AlignedBuffer to cereal/messaging.hpp
* rename function aligned to get
* use overloaded function AlignedBuffer:: get(Message *)
2021-03-16 11:13:15 +01:00
Dean Lee
e736029235
fix Fix problematic realloc ( #19812 )
2021-03-12 19:57:07 -08:00
Dean Lee
51d46e289a
raw_logger: remove unneeded recursive_mutex ( #20274 )
...
* remove lock
* remove forword declared err
* cleanup include
2021-03-07 21:36:37 -08: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
Willem Melching
511cb2680f
write params in initData as Data
2021-02-26 14:45:41 +01:00
Willem Melching
6e26403cee
test loggerd: limit samples to number of services
2021-02-23 16:45:08 +01:00
ZwX1616
e2044ca5a2
up tici hevc bitrate ( #20093 )
...
* 2x tici bitrate
* update test
* clean up
2021-02-22 09:15:56 -08:00
Willem Melching
d3dfb47d0e
loggerd: clean exit on SIGPWR ( #20100 )
...
* loggerd: clean exit on SIGPRW
* no SIGPWR on macos
2021-02-18 17:46:46 +01:00
Adeeb Shihadeh
312b681a46
cereal cleanup part 2 ( #20092 )
...
* car stuff
* thermal
* Revert "car stuff"
This reverts commit 77fd1c65eb
.
* 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
Greg Hogan
1cd9105e96
adjust qcamera quality ( #20066 )
...
* better ts
* fix test
2021-02-11 17:55:00 -08:00
Dean Lee
1fad5216ea
loggerd: remove the segment variable from encoders ( #20034 )
2021-02-07 17:48:46 -08:00
Dean Lee
1588a6f0ac
Logger: added function logger_get_route_name ( #19995 )
...
* added function logger_get_route_name
* remove empty line
2021-02-02 12:09:27 +01:00
Dean Lee
678c149246
mv logger_build_boot to bootlog.cc ( #19996 )
2021-02-02 12:07:52 +01:00
Dean Lee
aa37e95341
OmxEncoder: use c++ mutex&condition_variable ( #19786 )
...
* use c++ mutex&condition_variable
* rebase
* cleanup includes&use while
* remove include pthread.h
2021-02-01 21:57:17 -08:00
Dean Lee
ef6d1aeaaa
Logger: new class BZFile ( #19959 )
...
* add class BZFile
* inline
* cleanup includes
* stack bzfile
* log first error
* remove assert
* rename log_err to err_logged
* assert in destructor
* LOGE
* don't assert statement
* assert error of fclose
2021-02-01 21:00:42 -08:00
Dean Lee
9a9641a296
OMXEncoder: remove pthread_mutex_t lock from member variables ( #19948 )
...
* remove mutex
* rebase master
2021-01-30 19:11:03 -08:00
Dean Lee
16e259cadf
loggerd: small cleanup ( #19864 )
2021-01-30 18:37:58 -08:00
Adeeb Shihadeh
20a2bfdd31
Revert "OmxEncoder: new function set_state, set and wait state changed ( #19906 )"
...
This reverts commit 36a596eb1e
.
2021-01-28 11:57:29 -08:00
Dean Lee
36a596eb1e
OmxEncoder: new function set_state, set and wait state changed ( #19906 )
...
* free buffers after state is loaded
* set_data_blocking
* fix indentation
* Empty commit,trigger Build
2021-01-28 11:45:44 -08:00
Willem Melching
5693773ae1
fix safequeue import
2021-01-28 15:25:24 +01:00
Dean Lee
e6783f4d9f
remove cqueue, use class SafeQueue ( #19774 )
...
* class SafeQueue
* cleanup includes
* space
* add timeout
use try_poll
* add function empty() & size()
* class SafeQueue
* add timeout
use try_poll
* add function empty() & size()
* rebase master
* rebase master
* for loop
* fix bug
2021-01-28 15:12:45 +01:00
Dean Lee
79e05965c4
bootlog: fix dangling pointer problem in logger_build_boot ( #19942 )
...
* fix dangling pointer problem
* logger_build_init_data() has same problem
* return kj::Array<capnp::byte>
* Revert "return kj::Array<capnp::byte>"
This reverts commit 4df4685bfc
.
* Empty commit,trigger Build
* fix each segment in a route having a different initial logMonoTime
2021-01-28 13:34:07 +01:00
Adeeb Shihadeh
ea74f558f4
Revert "OMXEncoder: add calls to OMX_Init()&OMX_Deinit() ( #19905 )"
...
This reverts commit 8f00813089
.
2021-01-27 20:17:35 -08:00
Adeeb Shihadeh
0411015103
fix up encoder test for tici rotation ( #19941 )
...
* fix encoder test
* revert for c2
Co-authored-by: Comma Device <device@comma.ai>
2021-01-27 14:20:48 -08:00
Dean Lee
8f00813089
OMXEncoder: add calls to OMX_Init()&OMX_Deinit() ( #19905 )
...
* add calls to OMX_Init()&OMX_Deinit()
* fix indentation
2021-01-27 13:37:42 -08:00
Willem Melching
87119aebe2
Put bootlog in own folder ( #19939 )
...
* put bootlog in own folder
* fix uploader
* remove print statements
* update test
* remove comment
* also write initddata
* remove sentinels from test
2021-01-27 13:36:40 -08:00
Adeeb Shihadeh
9f2088e2c3
make loggerd rotation test more reliable
2021-01-24 19:38:20 -08:00
Adeeb Shihadeh
810ed30cab
more tici tests in jenkins ( #19908 )
...
* run loggerd tests on tici
* boardd loopback
* fix up seg length
* this doesn't add more coverage
2021-01-24 17:54:03 -08:00
Adeeb Shihadeh
1ed77847fe
loggerd: remove vipc arg from encode frame
2021-01-23 17:11:36 -08:00
Adeeb Shihadeh
d4489fbf91
OMX encoder stability ( #19758 )
...
* cleanup test first
* wait for other encoder threads
* fixes initial crash
* no print
* unused
* fix up tests
* need that
Co-authored-by: Comma Device <device@comma.ai>
2021-01-21 10:40:08 -08:00
Dean Lee
a5be02c2c7
OmxEncoder: set s->of to nullptr after close ( #19814 )
2021-01-19 14:28:03 -08:00
Adeeb Shihadeh
2e64049ea4
fix loggerd after bootlog split ( #19840 )
...
* fix loggerd after bootlog split
* logger handles that
* unused
Co-authored-by: Comma Device <device@comma.ai>
2021-01-19 14:27:19 -08:00
Dean Lee
f973c56a36
loggerd: split bootlog to a separate program ( #19831 )
...
* bootlog
* blank lines
* move file_exists to util.h
* src = ['loggerd.cc']
* log_init_data
* Revert "src = ['loggerd.cc']"
This reverts commit 18a587023d
.
* add bootlog to .gitignore
* use s->has_qlog instead of true
* add blank lines & remove extern C
2021-01-19 12:16:12 -08:00
Willem Melching
f3db94a0c4
Linux tombstones: add stacktrace and upload ( #19737 )
...
* Add stacktrace to tombstones
* make sentry output prettier
* Refactor
* Generate upload filename
* Actually move file
* Fix spaces
* copy and upload
* dont delete just yet
Co-authored-by: Comma Device <device@comma.ai>
2021-01-18 13:29:01 +01:00
Dean Lee
d085adb9ec
loggerd: make sure to print one statistics every 1000 times ( #19803 )
2021-01-17 15:50:13 -08:00
Dean Lee
e04cecd169
OmxEncoder: use std::vector to keep buffer ( #19807 )
2021-01-17 15:48:06 -08:00
Dean Lee
caf87c25dd
loggerd: do not LOGW twice when logger.part == 0 ( #19795 )
...
* fix LOGW
* space
2021-01-16 18:34:11 -08:00
Dean Lee
0592c326ed
OmxEncoder: use macro to check error ( #19785 )
2021-01-16 12:43:59 -08:00
Willem Melching
10790304c9
RecordFront remove ifdef ( #19773 )
2021-01-15 13:21:39 -08:00
Adeeb Shihadeh
5221450f2d
loggerd: another rotation test ( #19742 )
...
* another rotation test
* make encoder test fast
* fix pc
Co-authored-by: Comma Device <device@comma.ai>
2021-01-12 19:40:57 -08:00