Skip to content

Quickstart

farzad edited this page Oct 7, 2026 · 2 revisions

Quickstart

1. Start a simulated vehicle and the MCP server

peykan demo

You should see:

INFO  Starting Peykan server on 127.0.0.1:6278 (transport=sse)
INFO  Dashboard:    http://localhost:6278/dashboard
INFO  MCP endpoint: http://localhost:6278/sse

demo runs the simulator and the server in one process. That matters: the virtual CAN bus only exists inside one Python process, so a separately started peykan simulate would be invisible to the server (see Troubleshooting).

The server listens on 127.0.0.1 only. Use --host 0.0.0.0 if other machines need to reach it (the tools have no authentication).

2. Look at the dashboard

Open http://localhost:6278 (it redirects to /dashboard): live signal values grouped by message, and recent frames. See Dashboard.

3. Connect an AI client

Point any MCP client at http://localhost:6278/sse. Setup for Claude Desktop, VS Code, Cursor, Windsurf, MCP Inspector and Ollama is in Connecting MCP Clients.

Things to ask:

  • "What's the latest vehicle speed and coolant temperature?"
  • "Read the VIN and any stored trouble codes."
  • "Activate the misfire fault, then diagnose the vehicle."
  • "Analyse the sample log and tell me what happened."

Or use the built-in prompts: diagnose_vehicle, explain_dtc, trip_summary, fault_drill, analyze_log.

4. Try the CLI

The CLI commands that talk to the bus need a simulator in the same process (see above), so the easiest way to experiment from a terminal is with commands that don't, or through the MCP server. These work anywhere:

peykan dbc-info ENGINE_STATUS                          # the DBC's messages and signals
peykan decode 0x100 "e8 03 a0 32 32 c8 8d 00"          # decode one frame
peykan j1939-decode 0x0CF00400 "00 00 00 20 4e 00 00 00"
peykan j1939-pgns                                      # the J1939 catalog
peykan fault list                                      # the fault scenarios
peykan log-info sample                                 # analyse the bundled recording
peykan log-signal sample BATTERY_VOLTAGE               # one signal over time

To record your own simulated drive with a fault in it:

peykan record my_drive.asc --simulate --seconds 30 --fault misfire --fault-at 15
peykan log-info my_drive.asc

Full list: CLI Reference.

Next steps

Clone this wiki locally