Commit Graph

39 Commits (7222d0f20dc8edfe0d2f3417d1ce7c84fbd32805)

Author SHA1 Message Date
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
Dean Lee cf80675369
Use std::size for element counts (#20654) 2021-04-12 12:22:22 +02:00
Dean Lee 9b9bdd3da5
Added function power_set_wait, fix munmap invalid pointer error. (#20189)
* added function power_set_wait_cmd

* cleanup

* rename power_set_wait_cmd to power_set_wait

* rename delay to delay_ms
2021-04-02 21:17:42 -07:00
Dean Lee 5e6e9df407
camera_qcom2: move the common file descriptors to MultiCameraState (#20182)
* move the common file descriptors to MultiCameraState

* use unique_fd for file descriptors

* done

* fix build

Co-authored-by: ZwX1616 <zwx1616@gmail.com>
2021-03-30 19:43:09 -07:00
Dean Lee 4c225c6e1d
camera_qcom2: add std::mutex exp_lock (#20183)
* add std::mutex exp_lock

* auto &meta_data
2021-03-12 20:03:15 -08:00
ZwX1616 65bb979c34
set_exposure_target test (#20318)
* build

* remove junk

* clean up

* clean up rebase

* new patterns

* add gts

* add to jenkis

* this more useful

* typo

* test only

* Update Jenkinsfile

* test flag

* remove from jenkins

* these should all just be common:wq

* oops

* unigt

* add to unit tests?

* build all is fine

Co-authored-by: Comma Device <device@comma.ai>
2021-03-12 17:40:50 -08:00
Dean Lee 92e69e8b75
refactor function alloc (#20192) 2021-03-11 17:40:33 -08:00
Comma Device 0d036de205 better transition 2021-03-04 11:08:52 -08:00
robbederks 491309b639
Tici MIPI config (#20205)
* remove non-default mipi timings and preamble lengths

* actual correct settle count
2021-03-02 14:10:32 +01:00
ZwX1616 dd2bba0b42
Tici art4 (#20210)
* adjust gamma

* trust that light

* trust that chart

* unsrgb

Co-authored-by: Comma Device <device@comma.ai>
2021-03-01 16:35:43 -08:00
Dean Lee 468dc3f5a4
Move duplicate function declarations to camera_common.h (#20176) 2021-02-26 20:35:21 -08:00
Dean Lee 2f718d28e4
camerad: remove param pix_ptr from set_exposure_target (#20157) 2021-02-26 14:42:27 +01:00
Comma Device ab694dbace better gain values 2021-02-25 16:34:15 -08:00
ZwX1616 d8ddc1208e
tici camerart III: prehistoric visuals (#20012)
* reworked

* add ref

* f16

* faster

* extended tm

* fix hdr

* Revert "extended tm"

This reverts commit 55ba3ae3205f7e962bf2f36634b23a595700c9a8.

* reduce static/temporal noise

* split kernels to sync max

* no print

* cleanup qcom2

* optimize

* tune DC

* doesnt work

* minor fix

* adaptive

* smoothen HCG switch

* t

* histogram ceiling

* recalulate params

* group_hold

* less contrast

* recalibrate ccm

* better ae

* better ae revised

* made some changes

* clean up

* midtones

* some improvements

* more

* cleanup

* remove more junk

* lgtm

Co-authored-by: Comma Device <device@comma.ai>
2021-02-21 23:23:40 -08:00
Dean Lee e7906fb446
camerad: rename variables&functions to follow new convention (#20096)
* rename CameraState variables to follow new convention

* continue

* rename camera_process functions

* qcom:rename exposure related variables

* continue

* update commments

* bool real -> bool is_road_cam

* rename sm_front -> sm

* remove paramater tname from start_process_thread

* rename rhd_front to is_rhd

* remove unused varialble name from struct CameraInfo

* rename env_send_xxx

* rename cap_front to cap_driver,cap_rear to cap_road

* rename xxx_camera_process to process_xxx_camera

* update snapshot.py
2021-02-19 13:13:21 -08: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
Willem Melching af8eff4610
camerad fixes for updated agnos kernel (#20062)
* set size

* whitespace

* more cleanup
2021-02-11 23:42:20 -08:00
Dean Lee 80799c7272
fill_frame_data: remove unused paramater cnt (#19936) 2021-01-27 12:03:12 +01:00
Dean Lee cbd08d6f0c
cameras_qcom: fix dangling pointer in fill_frame_image (#19891) 2021-01-26 17:19:06 +01:00
Dean Lee c804059641
camera_qcom2: simplify camera_process_frame (#19763)
* simplify camera_process_frame

* Trigger Build

* Update selfdrive/camerad/cameras/camera_qcom2.cc

Co-authored-by: Willem Melching <willem.melching@gmail.com>
2021-01-15 12:05:31 +01:00
Dean Lee ea9835f293
fill_frame_image: reduce function parameters (#19736)
* reduce function paramaters

* add assert

* Trigger Build
2021-01-15 11:12:56 +01:00
Dean Lee 1b3c93813d
camerad use std::thread (#19771) 2021-01-15 11:10:52 +01:00
Dean Lee 660abb79dc
FIX: It is not safe to call cameras_close before all threads are done. (#19555)
* call cameras_close after all threads exited

* stop buffer before join

* remove buf->stop
2021-01-12 15:27:20 +01:00
Dean Lee 595830135b
merge utilpp.h into util.h (#19710) 2021-01-10 14:57:32 -08:00
Dean Lee cefdca2fd6
create_thumbnail in camera_common (#19553) 2021-01-08 14:31:21 -08:00
Willem Melching fb496c692a
VisionIPC 2.0 (#19641)
* Squashed vipc

* Update release files

* Remove else

* add visionipc to release files

* use poller in vipc receive

* opencl framework instead of lib on macos

* Fix camera webcam

* Fix opencl on mac in ui

* more webcam fixes

* typo in ui sconsfile

* Use cur_yuv_buf

* visionbuf c++ class

* Camera qcom was still using visionbuf_allocate

* Turn loggerd back on

* fix snapshot

* No build needed

* update test camerad

* no more release callback

* make encoder c++

* Revert "no more release callback"

This reverts commit e5707b07002fee665d0483d90713154efc2d70d4.

* fix exit handlers

* No need to check errno

* move release callback call

* s/VIPCBufExtra/VisionIpcBufExtra/g

* use non blocking connect

* ui use non blocking connect

* Lower condition variable wait time

* Snapshot cleanup

* bump cereal

* bump cereal
2021-01-08 14:54:25 +01:00
Dean Lee 86fe2d1697
common exit handler (#19661)
* common signal handle

* fix typo

* rename to ExitHandler

* remove include signal.h

* remove include csignal

* rename variable exit to v

* rebase master
2021-01-05 20:19:53 -08:00
Dean Lee c1cf0882bd
Replace usleep with util::sleep_for (#19643)
* replace usleep with sleep_for

* sleep microseconds

* sleep nanoseconds

* Trigger Build
2021-01-04 18:03:11 +01:00
Dean Lee 37826c0032
should not break if poll timeout (#19578) 2021-01-04 10:17:52 +01:00
Dean Lee 9890f958d9
cameras: use common transform (#19552) 2020-12-20 17:21:46 -08:00
Dean Lee bc1cfa6d4f
cleanup qcom2 (#19506)
* cleanup qcom2

* define DEBAYER_LOCAL_WORKSIZE in camera_qcom2.h
2020-12-17 11:43:50 -08:00
Adeeb Shihadeh c57ee16e86
Set GPU priorities + improved modeld priorities (#2691)
* give gpu threads rt priority

* modeld gets highest prio on core 2

* fix frame stream

* lower prio of cal thread

Co-authored-by: Comma Device <device@comma.ai>
2020-12-15 19:22:03 -08:00
Comma Device 0e84e04539 make qcom2 robust to moving v4l-subdevs 2020-12-10 05:44:59 +00:00
ZwX1616 d3387d540a
tici timing improvements (#2613)
* relocate

* impatience

* should be fine without

Co-authored-by: Comma Device <device@comma.ai>
2020-12-02 16:18:31 -08:00
Dean Lee bd4f6650fa
simplify building capnp messages with arrays (#2617) 2020-11-30 12:08:52 +01:00
Comma Device b9b6ed2d52 underflew 2020-11-19 04:03:16 +00:00
ZwX1616 c630cd44da
send frame in packet on demand (#2567)
* focus lens helper2

* fix

* yes screen

* s

* new/del

* once

* cleanup

Co-authored-by: Comma Device <device@comma.ai>
2020-11-18 13:39:50 -08:00
ZwX1616 b5617c17c8
just use the same (#2419) 2020-10-28 17:43:16 -07:00
ZwX1616 6b020241c9
Clean up and test camerad refactor (#2310)
* refactor

add function get_camerabuf_by_type

remove cl_free

use camera_id

move front stuff into frontview_thread

bigger refactor

more

typo

rename camerabuf *c to *b

cleanup header files

remove wideview_thread

camera_qcom.c to c++

fix SConscript

camera_process_buf

space

sendrgb same with before

do autoexposure in processing_thread

correct sendrgb

add camera_common.cc

move yuv_transform to CameraBuf

* use C to keep consitent

* rebase master

* rebase master

* continue refactor

* refactor all camera related data&function out of main

 done

* cleanup

* -use buf.rgb_width&height

* remoe ,

* rebase master

* remove unused std::vector

* add func common_camera_process_front

* fix max

* fix sendrgb

* less crap being logged

* fix indents

* add back thumbnails

* thumbnail fixed on tici

* junk junk junk

* unify api

* fix ptr ref

* lol!

* cleanup

* more simplified

* typos

* remove terminate

* use standard polling

* ops_thread refactor, too much code!

* fix build

* ok

* assert

* listen

* incl more

* wq!

* fix more build

* macos

* fix exp targets

* front is different

* const

* bye

* remath

* remove irrelevant

* do ops in a thread

* fix init

* return null

* QCOM2 ops

* qcom2 build

* missing comma

Co-authored-by: deanlee <deanlee3@gmail.com>
Co-authored-by: Comma Device <device@comma.ai>
2020-10-16 21:58:05 -07:00