-
Notifications
You must be signed in to change notification settings - Fork 224
17 CAN
Geo edited this page Jan 30, 2026
·
11 revisions
These commands are available to manage operations on the CAN bus.
They allow you to configure and interact with the CAN bus via the MCP2515 module.
Arguments in < > are required, while arguments in [ ] are optional.
| Command | Description |
|---|---|
sniff |
Captures and display all CAN frames |
send [id] |
Send a CAN frame with the specified ID |
receive [id] |
Wait for CAN frames with the specified ID |
status |
Show MCP2515 controller status and error flags |
config |
Configure CAN speed (kbps), pins, and settings |
- The
configcommand allows setting: - CAN speed in kbps (e.g. 125, 250, 500, 1000)
- The CAN speed will be automatically adjusted to the closest supported bitrate.
- CS, SO, SI, SCK pins (for CAN module MCP2515)
- The default CS pin is locked for the device and can't be changed.
-
sendaccepts up to 8 bytes as hexadecimal input, separated by spaces (AA BB 01...) -
receivefilters by a specific frame ID. - MCP2515 Pinout

mode can # Switch to CAN mode
config # Configure bitrate and pins
sniff # Captures all CAN frames
send 0x123 # Prompt frame data to send with frame ID 0x123
send # Prompt frame ID and frame DATA to send
receive # Prompt for frame ID and capture frames with specified ID
receive 0x123 # Wait for framess ith ID 0x123
status # Check controller status and errors
⚠️ Voltage Warning: Devices should only operate at 3.3V or 5V.
Do not connect peripherals using other voltage levels — doing so may damage your ESP32.