Files
Jason Wen d5b25e14fd Merge branch 'upstream/openpilot/master' into sync-20260317
# Conflicts:
#	.github/workflows/auto_pr_review.yaml
#	.gitignore
#	opendbc_repo
#	panda
#	selfdrive/ui/mici/layouts/home.py
#	selfdrive/ui/mici/layouts/onboarding.py
#	selfdrive/ui/mici/layouts/settings/device.py
#	selfdrive/ui/tests/diff/replay.py
#	selfdrive/ui/translations/app_fr.po
#	system/ui/mici_setup.py
Sync: `commaai/opendbc:master` → `sunnypilot/opendbc:master`
Sync: `commaai/panda:master` → `sunnypilot/panda:master`
2026-03-17 23:02:10 -04:00
..
2026-02-01 15:42:42 -08:00
2026-02-01 15:42:42 -08:00
2022-04-22 18:00:49 +02:00
2024-06-19 19:14:13 -07:00

openpilot in simulator

openpilot implements a bridge that allows it to run in the MetaDrive simulator.

Launching openpilot

First, start openpilot.

# Run locally
./tools/sim/launch_openpilot.sh

Bridge usage

$ ./run_bridge.py -h
usage: run_bridge.py [-h] [--joystick] [--high_quality] [--dual_camera]
Bridge between the simulator and openpilot.

options:
  -h, --help            show this help message and exit
  --joystick
  --high_quality
  --dual_camera

Bridge Controls:

  • To engage openpilot press 2, then press 1 to increase the speed and 2 to decrease.
  • To disengage, press "S" (simulates a user brake)

All inputs:

| key  |   functionality       |
|------|-----------------------|
|  1   | Cruise Resume / Accel |
|  2   | Cruise Set    / Decel |
|  3   | Cruise Cancel         |
|  r   | Reset Simulation      |
|  i   | Toggle Ignition       |
|  q   | Exit all              |
| wasd | Control manually      |

MetaDrive

Launching Metadrive

Start bridge processes located in tools/sim:

./run_bridge.py