openpilot/tools/carcontrols
Kevin Roscom 74d47446a9 joystick controls working 2022-02-21 14:05:24 -07:00
..
README.md improving tools readme (#20305) 2021-03-11 15:28:37 -08:00
__init__.py merge in tools 2020-01-17 10:07:22 -08:00
debug_controls.py joystick controls working 2022-02-21 14:05:24 -07:00
joystick_test.py enable flake8 E303: too many blank lines 2020-05-31 17:21:11 -07:00
joystickd.py enable E261 in flake8: two spaces before inline comment 2020-05-31 14:07:29 -07:00
steer.gif improving tools readme (#20305) 2021-03-11 15:28:37 -08:00

README.md

Debug car controls

Hardware needed: panda, giraffe, joystick

Use the panda's OBD-II port to connect with your car and a usb cable to connect the panda to your pc. Also, connect a joystick to your pc.

joystickd.py runs a deamon that reads inputs from a joystick and publishes them over zmq. boardd sends the CAN messages from your pc to the panda. debug_controls is a mocked version of controlsd.py and uses input from a joystick to send controls to your car.

Make sure the conditions are met in the panda to allow controls (e.g. cruise control engaged). You can also make a modification to the panda code to always allow controls.

Usage:

python carcontrols/joystickd.py

# In another terminal:
BASEDIR=$(pwd) selfdrive/boardd/boardd

# In another terminal:
python carcontrols/debug_controls.py

Imgur