Skip to content

canair discover

Alias: disc

usage: canair discover [-h] [--range START-END] [--delay DELAY] [--register]
                       [--dry-run] [--identify] [--save] [--label TEXT]
                       [--state TEXT] [--notes TEXT] [--wican WICAN]
                       [--transport {slcan-tcp,wican-ws,elm327-tcp}]
                       [--no-fallback] [--wait] [--elm-timeout MS]
                       [--timeout SECONDS] [--json] [--verbose] [--timings]
                       [--reboot] [--unsafe] [--force]

[UDS] Sweep a range of TX addresses (sends 10 01 to each) to find ECUs.

options:
  -h, --help            show this help message and exit
  --range START-END     Address range (default: 700-7EF for 11-bit, 00-FF for
                        29-bit target bytes)
  --delay DELAY         Delay between probes in seconds (default 0.2)
  --register            Register newly-discovered ECUs as files in the
                        profile's ecus/ directory
  --dry-run             With --register: show what would be added without
                        writing
  --identify            Run `canair identity` on each alive ECU after the
                        sweep (otherwise offer interactively)
  --save                Save results to captures/
  --label TEXT          Session label for --save
  --state TEXT          Session state for --save
  --notes TEXT          Session notes for --save
  --wican WICAN         WiCAN address: ap or IP (default: config
                        transport.host / default_wican=ap)
  --transport {slcan-tcp,wican-ws,elm327-tcp}
                        CAN transport: slcan-tcp (raw CAN), wican-ws (WiCAN
                        ELM327 WebSocket), or elm327-tcp (direct ELM327
                        adapter over TCP). Overrides the config
                        `transport.type` (default: slcan-tcp).
  --no-fallback         Don't auto-fall-back to other configured devices when
                        the selected one is unreachable (see config
                        transport.fallback).
  --wait                Keep retrying to reach the device indefinitely, then
                        start as soon as it comes online (Ctrl-C to stop). For
                        'monitor', also reconnects forever if the connection
                        drops mid-session (auto-failover to another same-
                        transport device is bounded by default; --wait makes
                        it unbounded).
  --elm-timeout MS      ELM327 ECU response timeout in ms (sent as ATSTxx
                        after init)
  --timeout SECONDS     Overall UDS response timeout in seconds (default 3.0
                        ELM / 2.0 raw). Overrides any per-ECU
                        response_timeout_ms for the whole run.
  --json                Output results as JSON
  --verbose, -v         Show raw transport traffic and expressions
  --timings             Print per-ECU/PID round-trip timing stats on exit (to
                        stderr)
  --reboot              Reboot WiCAN after session to restore AutoPID mode
  --unsafe              Bypass dangerous command blocklist (requires explicit
                        per-command consent)
  --force               Ask a session already holding the connection to
                        release it, then wait for it

examples:
  canair discover                     Discover ECUs in 0x700-0x7EF (default)
  canair discover --range 600-6FF     Custom range
  canair discover --delay 0.5         Slower pacing
  canair discover --register          Auto-add newly-found ECUs to ecus/
  canair discover --register --dry-run  Preview what would be registered
  canair discover --identify          Read identity DIDs from each ECU found