Skip to the content
4 layers63 × 55 mmCAN BUS sniffer, the printed circuit board in 3D

Built a four-layer STM32-based CAN bus sniffer PCB to detect and translate CAN codes from a vehicle

Size
63 × 55 mm
Copper layers
4
Thickness
1.59 mm
Parts
46
Nets
56
Pads
177
Tracks, vias
348, 69
Pours
5
Routed
Yes
KiCad
KiCad 10.0 (file 20260206)
Created
29 Jun 2026
Updated
30 Jun 2026

Overview

CAN BUS sniffer is an open-source printed circuit board by dvallemo, from the dvallemo/CANBUS-Sniffer-PCB repository on GitHub. It is a 4-layer board of 63 × 55 mm with 46 parts on 56 nets, routed with 348 tracks and 69 vias.

It is built around the CH340E, SN65HVD230D and CH213K, with the USBLC6-2SC6 among its other parts. Its parts include 17 capacitors, 10 resistors, 6 ICs, 4 connectors and 2 diodes. It belongs with the interfaces and adapters boards and the STM32 boards of this library.

Main components

4

README

README.md

CANBUS Sniffer PCB

A compact USB-to-CAN Bus interface designed around an STM32F0 microcontroller and a CAN transceiver. This project was built to practice professional PCB design techniques from schematic capture through PCB layout while following industry design practices.

Version: V1.0.0


Features

  • USB Type-C Interface
  • STM32F0 Microcontroller
  • CAN Bus Transceiver
  • USB 2.0 Full-Speed Differential Pair
  • 3.3V Linear Regulator
  • TVS Protection
  • Reverse Polarity Protection
  • Power LEDs
  • CAN Activity LEDs
  • SWD Programming Header
  • RESET Button
  • BOOT Button
  • Four Mounting Holes
  • Four-Layer PCB

Project Images

PCB Layout with Ground Pours


3D Render with Ground Pours


Schematic


Routed PCB


3D Render


Overview

The goal of this project was to design a complete CAN Bus Sniffer PCB using KiCad while applying professional hardware engineering methodologies.

The board receives power over USB Type-C, regulates the voltage to 3.3V, communicates over a CAN transceiver, and provides an SWD interface for programming and debugging.

Rather than only creating a working PCB, this project focused heavily on layout quality, manufacturability, and signal integrity.

Topics practiced include:

  • PCB floorplanning
  • Component placement
  • USB differential pair routing
  • Controlled impedance routing
  • Four-layer PCB stackup
  • Power distribution
  • Ground plane implementation
  • Decoupling capacitor placement
  • EMI reduction techniques
  • Design Rule Checks (DRC)
  • Design for Manufacturability (DFM)
  • Design for Assembly (DFA)

Hardware Specifications

ItemSpecification
MicrocontrollerSTM32F0 Series
CAN TransceiverSN65HVD230 Compatible
USBUSB Type-C (USB 2.0 Full Speed)
Input Voltage5V USB
Output Voltage3.3V
PCB Layers4
PCB Thickness1.6 mm
USB RoutingControlled Impedance Differential Pair

PCB Stackup

Layer 1

  • Components
  • Signal Routing
  • USB Differential Pair

Layer 2

  • Solid Ground Plane

Layer 3

  • Solid Ground Plane

Layer 4

  • Signal Routing
  • Power Routing

Using two dedicated internal ground planes provides:

  • Continuous return paths
  • Reduced EMI
  • Improved signal integrity
  • Lower ground impedance
  • Better high-frequency performance
  • Improved power distribution

Engineering Design Decisions

USB Type-C

USB Type-C was selected for modern compatibility and ease of use.

USB CC pull-down resistors were implemented to correctly identify the board as a USB device.

The USB D+ and D− lines were routed as a differential pair using KiCad's differential pair router.

Special attention was given to:

  • Matched trace lengths
  • Constant spacing
  • Controlled impedance
  • Minimal discontinuities
  • Smooth routing
  • Short path between the connector and downstream circuitry

Differential Pair Routing

Although USB Full-Speed is more forgiving than USB High-Speed, the layout follows professional differential routing practices.

Design considerations included:

  • Constant differential spacing
  • Matched lengths
  • 45° bends
  • Minimal skew
  • No unnecessary vias
  • Short routing distance
  • Continuous reference plane underneath the pair

Power Architecture

Power flow:

text
USB Type-C
    ↓
Protection Circuit
    ↓
Filtering
    ↓
3.3V LDO
    ↓
STM32 + CAN Transceiver

Wide power traces were used where appropriate to reduce voltage drop and improve current handling.


Power Integrity

Each power pin is locally decoupled with ceramic capacitors placed as close as possible to the corresponding IC supply pins.

This reduces:

  • Supply noise
  • Voltage ripple
  • Transient voltage drops
  • EMI

Grounding Strategy

The board utilizes:

  • Layer 2 Solid Ground Plane
  • Layer 3 Solid Ground Plane
  • Top Ground Pour
  • Bottom Ground Pour
  • Ground stitching vias

This creates low-impedance return paths and improves signal integrity throughout the design.

The exposed thermal pad underneath the STM32 is connected directly into the internal ground planes through a thermal via.


CAN Interface

The CAN transceiver converts the MCU CAN peripheral into differential CANH and CANL signals suitable for automotive communication.

The layout emphasizes:

  • Short routing
  • Clean return paths
  • Differential signaling
  • Noise immunity

Crystal Oscillator

The crystal and its load capacitors were placed immediately adjacent to the MCU oscillator pins.

This minimizes:

  • Loop area
  • EMI susceptibility
  • Clock jitter

Component Placement

Components were grouped by function:

USB Section

  • USB Connector
  • ESD Protection
  • CC Resistors

Power Section

  • Protection
  • LDO
  • Filtering
  • LEDs

CAN Section

  • CAN Connector
  • CAN Transceiver
  • Termination Components

MCU Section

  • STM32
  • Crystal
  • Decoupling
  • Programming Header

Keeping functional blocks together improves routing quality and simplifies debugging.


PCB Design Practices

The layout follows several common PCB design guidelines:

  • Functional component grouping
  • Short decoupling connections
  • Short crystal routing
  • Controlled impedance USB routing
  • Wide power traces
  • Ground stitching
  • Clean routing
  • Minimal unnecessary vias
  • Four-layer stackup
  • Continuous reference planes
  • Full Design Rule Check verification

Software Used

  • KiCad 9
  • STM32CubeMX
  • STM32CubeIDE

Current Status

  • ✅ Schematic Complete
  • ✅ PCB Layout Complete
  • ✅ Four-Layer PCB
  • ✅ USB Differential Pair Routed
  • ✅ Ground Planes Implemented
  • ✅ Design Rule Check Passed
  • ✅ 3D Model Generated
  • ✅ GitHub Documentation Complete

Future Improvements

  • PCB Manufacturing
  • Board Bring-up
  • Firmware Development
  • USB CDC Interface
  • CAN Frame Decoder
  • Desktop GUI
  • Oscilloscope Validation
  • Enclosure Design

Lessons Learned

This project provided hands-on experience with:

  • USB Type-C hardware implementation
  • Controlled impedance routing
  • Differential pair routing
  • Four-layer PCB stackups
  • Ground plane design
  • Decoupling strategies
  • CAN Bus hardware
  • STM32 hardware design
  • PCB floorplanning
  • PCB routing techniques
  • Power integrity
  • Signal integrity
  • Design Rule Checks
  • Design for Manufacturability
  • Design for Assembly
  • Professional hardware documentation using GitHub

Repository Structure

text
CANBUS-Sniffer-PCB/
│
├── README.md
├── LICENSE
│
├── Hardware/
│   ├── CAN_BUS_sniffer.kicad_pro
│   ├── CAN_BUS_sniffer.kicad_sch
│   ├── CAN_BUS_sniffer.kicad_pcb
│   └── ...
│
├── images/
│   ├── schematic.png
│   ├── pcb_layout.png
│   ├── pcb_layout_w_gndpours.png
│   ├── pcb_3d.png
│   └── pcb_3d_w_gndpours.png
│
├── Manufacturing/
│
└── Firmware/

License

This project is released under the MIT License.


Designed by David Valle
Electrical Engineer | PCB Design | Embedded Systems

Parts

46
QtyValueFootprintReferences
6100nCapacitor_SMD:C_0603_1608MetricC3, C4, C5, C6, C10, C15
622uCapacitor_SMD:C_0603_1608MetricC11, C12, C13, C14, C16, C17
4MountingHoleMountingHole:MountingHole_3.2mm_M3_ISO7380H1, H2, H3, H4
218pCapacitor_SMD:C_0603_1608MetricC7, C8
22u2Capacitor_SMD:C_0603_1608MetricC2, C9
25.1kResistor_SMD:R_0603_1608MetricR3, R4
260.4Resistor_SMD:R_0603_1608MetricR6, R7
2Conn_01x03_PinConnector_PinHeader_2.54mm:PinHeader_1x03_P2.54mm_VerticalJ3, J4
2GREENLED_SMD:LED_0603_1608MetricD1, D2
2RResistor_SMD:R_0603_1608MetricR1, R2
2SW_SPSTButton_Switch_SMD:SW_SPST_EVQP0SW1, SW2
110RResistor_SMD:R_0603_1608MetricR8
110kResistor_SMD:R_0603_1608MetricR5
11kResistor_SMD:R_0603_1608MetricR10
12kResistor_SMD:R_0603_1608MetricR9
14u7Capacitor_SMD:C_0603_1608MetricC1
18MHzCrystal:Crystal_SMD_1210-4Pin_1.2x1.0mmY1
1CH213kPackage_TO_SOT_SMD:TSOT-23U4
1CH340EPackage_SO:MSOP-10_3x3mm_P0.5mmU5
1Conn_01x03_SocketConnector_JST:JST_PH_S3B-PH-K_1x03_P2.00mm_HorizontalJ2
1HT75xx-1-SOT89Package_TO_SOT_SMD:SOT-89-3U6
1SN65HVD230Package_SO:SOIC-8_3.9x4.9mm_P1.27mmU2
1STM32F042K6UxPackage_DFN_QFN:QFN-32-1EP_5x5mm_P0.5mm_EP3.45x3.45mmU1
1USBLC6-2SC6Package_TO_SOT_SMD:SOT-23-6U3
1USB_C_Receptacle_USB2.0_16PConnector_USB:USB_C_Receptacle_GCT_USB4105-xx-A_16P_TopMnt_HorizontalJ1

Similar boards

  • 2 layers100 × 86 mmMb n boost, the printed circuit board in 3D

    Mb n boost

    McbeEringi/pcb-stuff

    218 parts2MIT
  • 2 layers149.2 × 82.5 mm0xPM, the printed circuit board in 3D

    0xPM

    llmerlos/0xPM

    PICCTRL 0xPM - 6x3+4 Split Keyboard with onboard CH552

    65 parts11CERN-OHL-P-2.0
  • 4 layers80 × 80 mmKonoha, the printed circuit board in 3D

    Konoha

    aisuneko/konoha

    4-port USB3.0 pure Type-C Hub powered by CH634X

    97 parts1CERN-OHL-S-2.0
  • 2 layers35 × 42 mmAstroUniBoard, the printed circuit board in 3D

    AstroUniBoard

    xlazam01/AstroUniBoard

    STM32G0B1-based telescope focuser/rotator controller — OnStepX firmware port + KiCad PCB

    146 parts1GPL-3.0
  • 2 layers31.8 × 74.2 mmEG8504 RP2040, the printed circuit board in 3D

    EG8504 RP2040

    Talkie181/EG8504_RP2040

    50 parts

Questions

How big is the CAN BUS sniffer PCB?

It measures 63 × 55 mm and has 4 copper layers, 1.59 mm thick.

What parts does the CAN BUS sniffer use?

46 parts, built around the CH340E, SN65HVD230D, CH213K and USBLC6-2SC6. The full list of its parts is on this page, with links to each part's symbol and footprint where PCBKit's library has them.

Where can I download the CAN BUS sniffer KiCad files?

From the dvallemo/CANBUS-Sniffer-PCB repository on GitHub, at the commit this page was made from: the board is CAN_BUS_sniffer.kicad_pcb and its schematic CAN_BUS_sniffer.kicad_sch. PCBKit opens the board in the browser, with nothing to install.

Can I use the CAN BUS sniffer design in my own project?

Its repository states no licence, so its author keeps all rights: ask dvallemo before reusing the design.