ESP32 Bit Pirate home
  • CAN
  • Intermediate
  • 5 min
  • Serial CLI

Recipe · Intermediate · CAN

How to receive a specific CAN frame ID

Configure MCP2515 CAN mode and wait for frames matching a selected CAN identifier.

CAN bus connected to an MCP2515 controller module.
A practical ESP32 Bit Pirate workflow based on the documented firmware commands.

Wiring View

BP MCP2515 SCK/SI/...SPI pinsCANH/CANLsafe CAN bus or...GNDshared ground
Generated from the wiring summary: to BP.
Step 1

Commands

Run the workflow from the CLI after selecting the matching mode.

Result

What it means

The output confirms that the protocol path is working and gives you a baseline for deeper experiments.

Troubleshooting

  • Match the bus bitrate in config.
  • Check termination on your test bus.
  • Use status to inspect MCP2515 errors.

Next steps

  • Run sniff to discover IDs.
  • Send a known test frame on a lab bus.
  • Log frames from repeated actions.

CAN frame ID receive FAQ

What does receive with an ID filter do?

It waits for CAN frames matching the selected identifier, which is useful after sniffing a bus and choosing one message to watch closely.

Why do I receive no frames for a known ID?

The MCP2515 bitrate may not match the bus, the bus may lack termination, the frame may be extended instead of standard, or the event that sends that ID may not be occurring.

Should I start with sniff or receive?

Start with sniff when the bus is unknown. Use receive once you know the bitrate and have a specific ID worth monitoring.

Go deeper