Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Virtual bus

The virtual bus is the easiest way to test two roles without hardware. It is the recommended first integration environment because it exercises real stack routing without requiring SocketCAN permissions, wiring, or a running tractor.

Common setup:

  • tractor node
  • implement node
  • both attached to the same in-process bus
  • run ticks until both claim addresses
  • send one workflow message
  • drain events on the peer

This is how many stack tests prove behavior without relying on SocketCAN timing or machine wiring. After the virtual-bus workflow passes, move to SocketCAN traces.

make run EXAMPLE=virtual_can_demo

Two-node checklist

StepTractor-like nodeImplement-like node
NAMEfunction/identity for tractor rolefunction/identity for implement role
preferred addressnormally tractor rangenormally implement range
enabled surfacesdiagnostics, GNSS, tractor/persona helpersdiagnostics, VT/TC/FS/implement helpers
startupstart address claimstart address claim
loopcall tick()call tick()
proofdrain tractor eventsdrain implement events

Why this matters

The virtual bus catches address conflicts, destination-specific PGN mistakes, event fan-out bugs, and many high-level stack regressions before you touch real hardware. It does not prove physical timing or transceiver behavior.