Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/commaai/openpilot/llms.txt

Use this file to discover all available pages before exploring further.

Cabana is openpilot’s built-in CAN bus analysis tool. It lets you view raw CAN messages from recorded drives or in realtime from a connected comma device or panda, overlay video from the drive, decode signals using DBC files, and plot any signal over time. Cabana integrates directly with commaai/opendbc so you can load and save DBC files from source as you work through a new car port.

Launching Cabana

Cabana is built as part of the openpilot build. After running scons -u, the binary is at tools/cabana/cabana. Running it without arguments opens the stream selector dialog so you can choose a data source interactively.
# Open the stream selector dialog
./tools/cabana/cabana

# Load a built-in demo route
./tools/cabana/cabana --demo

# Load a specific route from comma connect
./tools/cabana/cabana "5beb9b58bd12b691/0000010a--a51155e496"

# Load a route with driver and wide road cameras
./tools/cabana/cabana "5beb9b58bd12b691/0000010a--a51155e496" --dcam --ecam

Full options reference

$ ./cabana -h
Usage: ./cabana [options] route

Options:
  -h, --help                     Displays help on commandline options.
  --help-all                     Displays help including Qt specific options.
  --demo                         use a demo route instead of providing your own
  --auto                         Auto load the route from the best available source (no video)
  --qcam                         load qcamera
  --ecam                         load wide road camera
  --msgq                         read can messages from msgq
  --panda                        read can messages from panda
  --panda-serial <panda-serial>  read can messages from panda with given serial
  --socketcan <socketcan>        read can messages from given SocketCAN device
  --zmq <ip-address>             read can messages from zmq at the specified ip-address
  --data_dir <data_dir>          local directory with routes
  --no-vipc                      do not output video
  --dbc <dbc>                    dbc file to open

Arguments:
  route                          the drive to replay (find drives at connect.comma.ai)

Use cases

When porting openpilot to a new car, Cabana lets you watch raw CAN traffic and assign signals to a DBC file. Load a route from the car, open a DBC file from opendbc, and start mapping byte positions to known control values like steering angle, wheel speed, and gas pedal position.
Load any route from comma connect by pasting the route identifier. Cabana downloads and decodes the log, displays all CAN messages in a table, and plots any decoded signal against the drive video timeline.
SSH into your comma device and start the bridge, then connect Cabana over ZMQ. Cabana will log the stream to ~/cabana_live_stream/ by default, and you can replay the saved data afterwards via the stream selector dialog.
# On your comma device: start the bridge
cd /data/openpilot/cereal/messaging/
./bridge &

# On your laptop: connect Cabana to the device
./tools/cabana/cabana --zmq <ipaddress>
Connect a panda to your PC via USB and read CAN messages directly without needing a comma device or route.
./tools/cabana/cabana --panda

# If you have multiple pandas connected, target one by serial
./tools/cabana/cabana --panda-serial <panda-serial>
If you have route segments stored locally (for example, downloaded from a comma device), point Cabana at the directory.
./tools/cabana/cabana "5beb9b58bd12b691/0000010a--a51155e496" \
  --data_dir /path/to/routes

Changing the log directory for live streams

When streaming from a comma device, Cabana saves CAN messages to ~/cabana_live_stream/ by default. To change this, go to Menu → Tools → Settings inside Cabana.
To replay a recorded route you only need the route identifier from connect.comma.ai — no hardware required. For live CAN streaming you need either a connected comma device (via ZMQ) or a panda connected directly to your PC over USB.

Build docs developers (and LLMs) love