Skip to content
/ PiCCANTE Public

PiCCANTE is a powerful tool for exploring and reversing CAN busses of vehicles, based on Raspberry Pi Pico (any model)

License

Notifications You must be signed in to change notification settings

Alia5/PiCCANTE

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation


Build Status License: GPL-3.0 Release Issues PRs Welcome

PiCCANTE 🌢️

PiCCANTE Car Controller Area Network Tool for Exploration

PiCCANTE is a powerful hacking tool for accessing, exploring, and manipulating vehicle CAN bus networks, built on the affordable Raspberry Pi Pico platform. Designed for researchers, security professionals, and automotive enthusiasts looking to dive deep into vehicle systems without expensive proprietary equipment.

🚧 WORK IN PROGRESS 🚧

ℹ️ About PiCCANTE

PiCCANTE is designed to be a dead-simple, dirt-cheap, and readily-available hardware platform for vehicle research and exploration.
As cars become more and more computerized, manufacturers keep locking them behind proprietary tools and restrictive systems, even connect vehicles to the internet, yet they still rely on communication standards from the 1980s.
Car hacking and independent research grows increasingly important to discover security vulnerabilities, reverse engineer vehicle systems, and empower owners with custom tools for diagnostics and tuning that support the Right to Repair movement.

The project leverages Raspberry Pi Pico (2 [W]) development boards, selected for their exceptional affordability, global availability, impressive specifications, and well-documented open-source SDK.

⚠️ Always exercise caution when connecting to vehicle systems.

🎯 Core Goals

Keep it D.I.R.T.Y πŸ˜‰

  • Dead-Simple πŸ”¨
    • Simple enough for perfboard soldering with minimal components.
    • No fiddling around with compilers and SDKs: Pre-built firmware releases for immediate use.
  • Inexpensive πŸ’°
    • Minimal hardware requirements to keep costs dirt-cheap.
    • Based on affordable, off-the-shelf components.
  • Readily-Available 🌎
    • Fully open-source hardware and software.
    • Uses widely available Raspberry Pi Pico boards.
  • Tool-Compatible πŸ”Œ
    • Seamless integration with existing CAN tools.
  • Your-First Choice πŸ’‘
    • Driverless across all major operating systems.
    • Easy to use for beginners and experts alike.
    • πŸ”œ Documentation

✨ Features

  • βœ… Up to 3Γ— CAN 2.0B interfaces (2Γ— on RP2040 (Pico[W]), 3Γ— on RP2350 (Pico 2[W]))
  • βœ… 1Γ— USB-CDC PiCCANTE command + GVRET (binary only) interface
    • Compatible with SavvyCAN and other automotive tools
  • βœ… Up to 3Γ— USB-CDC SLCAN interfaces (dedicated to each CAN channel)
  • βœ… LED status indicators
  • βœ… Command line interface for configuration and diagnostics
  • βœ… Auto (Deep) sleep on idle + Wakeup on CAN activity.
  • βœ… WiFi support (on Pico W models)
    • βœ… Create WiFi access point (wifi ap <ssid> <password> <channel>)
    • βœ… Connect to existing WiFi networks (wifi connect <ssid> <password>)
    • βœ… WiFi status and configuration commands
    • βœ… PiCCANTE configuration + GVRET interface as Telnet server
  • βœ… Web-based configuration interface (on Pico W models)
    • βœ… Fully responsive on desktop and mobile
    • βœ… Full device configuration
    • βœ… Device Monitoring
    • πŸ”œ Integrated Web CLI:
      • Live CAN-bus monitoring
      • ELM327 commands
    • πŸ”œ MITM mode configuration
  • πŸ”œ ELM327 emulator
  • πŸ”œ 3D printable case designs for creating PiCCANTE based OBD-II dongles
  • πŸ”œ Bluetooth support (on Pico W models)
  • πŸ”œ MITM mode for advanced analysis / vehicle tuning
  • πŸ”œ (Software) CAN filters
  • πŸ”œ Data logging to SD card (maybe)

πŸ“‹ Quick Start

πŸ›’ What You'll Need

  • 1Γ— Raspberry Pi Pico (any model, RP2040 or RP2350)
    • Note: The Pico 2 W (RP2350) is recommended for full feature support, including WiFi and Bluetooth.
  • 1-3Γ— CAN transceivers (readily available SN65HVD23x or any other 3.3V compatible transceiver)
    • Note: Most readily available transceiver breakout-boards have a 120Ohm terminating Resistor on them, for research in a vehicle, you may need to remove it.
  • USB cable
  • Perfboard
    • [OPTIONAL] or custom PCB πŸ”œ
  • Soldering iron
  • Basic soldering skills
  • [Optional] Low dropout Buck-Converter module and OBD Plug for directly connecting to the vehicle's OBD-II port
  • [Optional] 3D printed case for the Pico and transceivers

πŸš€ Basic Usage Examples

🐧 Linux with can-utils (slcan)

# Set up SLCAN interface
sudo slcand -o -s6 -t hw -S 3000000 /dev/ttyACM1 can0
sudo ip link set up can0

# Monitor CAN traffic
candump can0

πŸ–₯️ Cross Platform with SavvyCAN

  1. Connect PiCCANTE to USB
  2. Open SavvyCAN
  3. Go to Connection ➑️ Open Connection Window ➑️ Add device Connection
  4. Select "Serial Connection (GVRET)" and choose the appropriate COM port / TTY
  5. Click "Create New Connection"

πŸ”§ Hardware

Comprehensive documentation for self-built perfboard hardware is coming soon.
Custom PCB designs may follow at a later date.

πŸ’Ύ Software

Pre-compiled binaries for all official Raspberry Pi Pico boards are available as CI action artifacts in the GitHub repository.

When connected via USB, PiCCANTE exposes up to 4Γ— USB-CDC interfaces:

  • 1Γ— Combined PiCCANTE command + GVRET (binary) interface
    • Always the first exposed CDC device.
    • Also exposed via telnet if enabled on WiFi enabled boards.
  • Up to 3Γ— SLCAN interfaces (dedicated to each CAN channel)

⌨️ PiCCANTE Commands

binary          - Toggle GVRET binary mode (binary <on|off>)
can_bitrate     - Change CAN bus bitrate (can_bitrate <bus> <bitrate>)
can_disable     - Disable CAN bus (can_disable <bus>)
can_enable      - Enable CAN bus with specified bitrate (can_enable <bus> <bitrate>)
can_status      - Show status of CAN buses
echo            - Toggle command echo (echo <on|off>)
help            - Display this help message
led_mode        - Set LED mode (led_mode <0-3>) 0=OFF, 1=Power, 2=CAN Activity
log_level       - Set log level (log_level <0-3>). 0=DEBUG, 1=INFO, 2=WARNING, 3=ERROR
reset           - Reset the system (reset)
save            - Save current settings to flash
set_num_busses  - Set number of CAN buses (can_num_busses [number])
settings        - Show current system settings
sys_stats       - Display system information and resource usage (sys_stats [cpu|heap|fs|tasks|uptime|adc|wifi])
telnet          - Enable or disable Telnet and set port (telnet enable|disable | telnet <port>)
wifi            - Manage WiFi settings (wifi info | wifi connect <ssid> <password> | wifi ap <ssid> <password> <channel> | wifi disable)

❓ Frequently Asked Questions

πŸ”„ Why only CAN2.0B and not CAN FD/XL?

The Raspberry Pi Pico has no native CAN support. The PIO can2040 implementation we're using only supports CAN 2.0B.
However, if you need CAN FD or other bus types, feel free to open a PR supporting a CAN controller (like MCP2518FD).

πŸ”Œ Can I use PiCCANTE with Linux/Windows/macOS?

Yes! PiCCANTE is designed to be cross-platform. It works with any operating system as a standard USB device with no special drivers required.
For SLCAN interfaces, Linux users can use can-utils to provide a SocketCAN interface, while all platforms support the GVRET/SLCAN interface through tools like SavvyCAN.

πŸ’» How many CAN buses can I monitor simultaneously?

Up to 3 CAN buses on the RP2350 (Pico 2/2W) and up to 2 CAN buses on the RP2040 (original Pico/Pico W).
Each bus has a dedicated USB-CDC SLCAN interface.

πŸ”§ Why build my own instead of buying a commercial CAN adapter?

PiCCANTE gives you a fully open-source solution at a fraction of the cost of commercial tools.
You get complete control over the hardware and software, the ability to customize for specific needs, and valuable learning experience about CAN networks and embedded systems.

❓ Troubleshooting

  • Issue: CAN bus not receiving data
    Solutions:

    • Verify CAN status with can_status command
    • Verify wiring and bitrate settings
    • Check for proper bus termination resistance (remove resistor on the transceiver if connected to an existing CAN-bus)
  • Issue: LED not lighting up / blinking
    Solutions:

    • Check USB connection and power
    • Check led_mode command on the first USB CDC device

πŸ› οΈ Development

PiCCANTE is built using the Raspberry Pi Pico SDK and follows standard Pico development practices. This section covers how to set up your development environment, build the project, and extend its functionality.

🧰 Prerequisites

πŸ”„ Environment Setup

  1. Install the Pico SDK:

    Follow the instructions in the Pico SDK documentation to install the SDK

  2. Clone PiCCANTE:

    git clone [email protected]:Alia5/PiCCANTE.git
    cd PiCCANTE
    git submodule update --init --recursive

πŸ—οΈ Building

πŸ’» Command Line

  1. Configure with CMake:

    cmake -B build -G Ninja -DCMAKE_BUILD_TYPE=Release
  2. Build the project:

    cmake --build build --config Release

πŸ–₯️ Using VS Code

  1. Open the PiCCANTE folder in VS Code
  2. Press F1 and select "CMake: Configure"
  3. Press F7 to build the project
  4. To flash, connect a Pico in BOOTSEL mode and press F5

πŸ‘₯ Contributing

Contributions to PiCCANTE are welcome! Whether it's bug reports, feature requests, documentation improvements, or code contributions, your help makes this project better.

  • Bug Reports: Open an issue describing the problem and steps to reproduce it
  • Feature Requests: Open an issue describing the desired functionality
  • Code Contributions: Fork the repository, make your changes, and submit a pull request

Extending PiCCANTE

PiCCANTE is designed to be modular and extensible. Here are some key areas where you might want to extend functionality:

  • Adding new commands: Extend the command interpreter to add custom commands.
  • Implementing new protocols: Add new protocol handlers in their respective directories.
  • Car-specific tools: Fork PiCCANTE to create a car-specific tool and diagnostics dongle.
  • Custom gauges: Fork PiCCANTE and use it as a base controller to implement custom gauges.
  • Custom data logging: Implement custom data logging to SD card to monitor your vehicle on a track day.

πŸ“„ License

PiCCANTE - PiCCANTE Car Controller Area Network Tool for Exploration
Copyright (C) 2025 Peter Repukat

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program.  If not, see <https://www.gnu.org/licenses/>.