2021-02-18 12:37:01 +08:00
|
|
|
# Run openpilot with webcam on PC
|
|
|
|
|
2020-06-04 03:54:49 +08:00
|
|
|
What's needed:
|
2024-06-18 11:30:32 +08:00
|
|
|
- Ubuntu 24.04
|
2020-06-04 03:54:49 +08:00
|
|
|
- GPU (recommended)
|
|
|
|
- Two USB webcams, at least 720p and 78 degrees FOV (e.g. Logitech C920/C615)
|
2020-11-04 11:56:25 +08:00
|
|
|
- [Car harness](https://comma.ai/shop/products/comma-car-harness) with black panda to connect to your car
|
2021-02-18 12:37:01 +08:00
|
|
|
- [Panda paw](https://comma.ai/shop/products/panda-paw) or USB-A to USB-A cable to connect panda to your computer
|
2020-06-04 03:54:49 +08:00
|
|
|
That's it!
|
2020-03-27 10:19:47 +08:00
|
|
|
|
2021-02-18 12:37:01 +08:00
|
|
|
## Setup openpilot
|
2020-03-27 10:19:47 +08:00
|
|
|
```
|
2020-06-04 03:54:49 +08:00
|
|
|
cd ~
|
|
|
|
git clone https://github.com/commaai/openpilot.git
|
2020-03-27 10:19:47 +08:00
|
|
|
```
|
2020-06-04 03:54:49 +08:00
|
|
|
- Follow [this readme](https://github.com/commaai/openpilot/tree/master/tools) to install the requirements
|
2022-12-01 13:45:44 +08:00
|
|
|
- Install [OpenCL Driver](https://registrationcenter-download.intel.com/akdlm/irc_nas/vcp/15532/l_opencl_p_18.1.0.015.tgz)
|
2020-03-28 03:42:05 +08:00
|
|
|
|
2020-06-04 03:54:49 +08:00
|
|
|
## Build openpilot for webcam
|
2020-03-27 10:19:47 +08:00
|
|
|
```
|
2020-06-04 03:54:49 +08:00
|
|
|
cd ~/openpilot
|
2020-10-17 06:16:17 +08:00
|
|
|
USE_WEBCAM=1 scons -j$(nproc)
|
2020-03-27 10:19:47 +08:00
|
|
|
```
|
2020-03-28 03:42:05 +08:00
|
|
|
|
2020-06-07 12:21:25 +08:00
|
|
|
## Connect the hardware
|
2020-06-04 03:54:49 +08:00
|
|
|
- Connect the road facing camera first, then the driver facing camera
|
2022-06-20 05:43:49 +08:00
|
|
|
- (default indexes are 1 and 2; can be modified in system/camerad/cameras/camera_webcam.cc)
|
2020-06-04 03:54:49 +08:00
|
|
|
- Connect your computer to panda
|
2020-03-28 03:42:05 +08:00
|
|
|
|
2020-06-04 03:54:49 +08:00
|
|
|
## GO
|
2020-03-27 10:19:47 +08:00
|
|
|
```
|
2024-05-26 03:41:17 +08:00
|
|
|
cd ~/openpilot/system/manager
|
2024-01-20 06:05:03 +08:00
|
|
|
NOSENSOR=1 USE_WEBCAM=1 ./manager.py
|
2020-03-27 10:19:47 +08:00
|
|
|
```
|
2020-06-04 03:54:49 +08:00
|
|
|
- Start the car, then the UI should show the road webcam's view
|
|
|
|
- Adjust and secure the webcams (you can run tools/webcam/front_mount_helper.py to help mount the driver camera)
|
|
|
|
- Finish calibration and engage!
|