Skip to the content
2 layers22.5 × 19 mmMedalv2, the printed circuit board in 3D

PCB ping-pong medal: round ATtiny1616 board with an 8-LED ring animation, designed code-first (circuit-synth + headless pcbnew/Freerouting). The board is the medal.

Size
22.5 × 19 mm
Copper layers
2
Thickness
1.6 mm
Parts
22
Nets
20
Pads
70
Tracks, vias
107, 3
Pours
2
Routed
Yes
KiCad
KiCad 10.0 (file 20260206)
Created
11 Jun 2026
Updated
15 Jun 2026

Overview

Medalv2 is an open-source printed circuit board by VincentPeters, from the VincentPeters/pingpong-medal repository on GitHub, published under the MIT licence. It is a 2-layer board of 22.5 × 19 mm with 22 parts on 20 nets, routed with 107 tracks and 3 vias.

Its parts include 8 resistors, 8 diodes, 2 capacitors, 1 IC and 1 connector.

README

README.md

🏓 PCB Ping-Pong Medal

A wearable circuit board that lights up, and dares you to reflash it.

License: MIT  MCU: ATtiny1616  Firmware: megaTinyCore  EDA: KiCad  Cost: ~6 EUR/medal

Four finished medals on KdG lanyards with their LED rings lit

Reflash it · How it works · Make your own · Build journey

▶ Watch: all four running · animation demo · first bring-up


A round 45 mm ENIG PCB on a lanyard, built for the KdG Graduaat IoT ping-pong tournament. The board is the medal: an ATtiny1616 plays an 8-LED ring animation when you flip the switch, a CR2032 lives on the back, and reflashing the chip with your own animation is part of the prize.

Front (gold ENIG, LED comet)Back (CR2032, switch, rank box)
Four medal fronts on lanyardsMedal backs with coin cell and marked rank

The hardware was designed code-first: the schematic and netlist generated from Python with circuit-synth, the board placed, routed, and silkscreened headlessly through the KiCad pcbnew API plus Freerouting, and the animation core developed test-first on the host. The build journey walks through it; the design notes cover the rationale.

How it works

Schematic overview: ATtiny1616 with an 8-LED ring, CR2032 plus slide switch, and UPDI programming pads

An ATtiny1616 sits at the center and direct-drives 8 LEDs in a ring, each through its own 470 Ω resistor (PAx → R → LED → GND). A CR2032 powers it through a slide switch; two capacitors decouple the rail. Three back pads (J1: GND / VCC / UPDI) let you reflash it. That is the whole circuit, generated and verified net-for-net against the netlist (hardware/cs/medal-sch.pdf).

Reflash your medal

Reprogramming the medal is the point: it is a wearable dev board. The three pads at the bottom of the back are the programming header J1 (back view, lanyard hole up): GND · VCC · UPDI.

Take the CR2032 out while flashing. The programmer powers the board.

What you need

Either of:

  • An Arduino Uno (or Nano), a 4.7 kΩ resistor, and 3 jumper wires. One time, upload the vendored jtag2updi sketch to the Uno. Then wire D6 through the 4.7 kΩ resistor to UPDI, 5V to VCC, and GND to GND. Step-by-step with the breadboard jig: BUILD_GUIDE.md.
  • A 3.3 V USB-serial adapter (CP2102 / CH340 / FT232, at 3.3 V, not 5 V). Wire TX through the 4.7 kΩ resistor to UPDI, RX to UPDI, 3V3 to VCC, GND to GND.
Wiring diagram: Arduino Uno through a breadboard with a 4.7 kilohm resistor on UPDI to the medal's J1 pads

Flash

On Windows, flash.ps1 compiles and uploads in one go:

powershell
firmware\flash.ps1 -Port COM7 -BurnFuses -Test   # fresh chip: set fuses + run the LED self-test
firmware\flash.ps1 -Port COM7 -Rank 1            # medal firmware; rank = victory pulses (1-4)
firmware\flash.ps1 -Port COM7 -Programmer serialupdi -Rank 2   # USB-serial adapter instead of the Uno

On other platforms, call arduino-cli directly with --programmer jtag2updi (or serialupdi). The commands are in firmware/README.md.

Make it yours

The firmware is split so the fun part is easy and safe to hack:

  • firmware/medal/config.h holds the knobs: RANK (victory pulses on power-up), SHOW_MS (how long the show plays before the chip deep-sleeps), and BLINK_TEST (wiring self-test mode).

  • firmware/medal/animations.cpp holds the animations. An animation is just a function that fills 8 brightness bytes (0 to 255, one per LED) for a given time t_ms. Edit spin_frame / pulse_frame, or add your own frame function and call it from medal.ino. No Arduino knowledge needed here: it is pure C++ you can unit-test on your laptop.

    sh
    sh firmware/test/run-tests.sh

Reflash, flip the switch, admire. Keep only a few LEDs bright at once: the CR2032 sags if you light all 8 at full brightness, and the battery lasts much longer with comet or chase patterns. The medal animates for about 12 seconds after you slide the switch ON, then the MCU drops to power-down sleep (µA range). Cycle the switch to replay.

Make your own

  1. Order the boards from the gerbers and assembly files in hardware/cs/medalv2/fab/. JLCPCB assembles the top-side SMD parts; the battery holder, switch, and header are hand-soldered (parts list in bom/bom.csv). This is what you are ordering:

    Front renderBack render
    Board render, frontBoard render, back
  2. Assemble and flash. Follow FINISHING.md, or BUILD_GUIDE.md for the Arduino-Uno-as-programmer jig.

    Hand-soldering the holdersFlashing via the Uno jig
    Assembly bench with boards, holders, and a soldering ironMedal in helping hands, wired to an Arduino Uno breadboard jig
  3. Hang it on a ribbon and lose gracefully at ping pong.

Per-medal cost lands around 5 to 7 EUR including the share of the PCB run.

Repository layout

PathWhat's inside
firmware/medal/megaTinyCore sketch and the pure-C++ animation core
firmware/test/host unit tests for the animation core (no hardware needed)
firmware/flash.ps1compile and flash a medal (jtag2updi or SerialUPDI)
firmware/jtag2updi/vendored jtag2updi (MIT): turns an Arduino Uno into a UPDI programmer
hardware/cs/code-defined hardware: circuit-synth schematic, pcbnew layout and routing scripts, final board in medalv2/
hardware/cs/medalv2/fab/gerbers, drill, JLCPCB assembly BOM and CPL
hardware/art/medal-face silkscreen SVG
bom/parts list with LCSC numbers and per-medal cost
docs/design and build documentation

License

MIT, see LICENSE. The vendored firmware/jtag2updi/ is MIT by Joao N. Rosa.

Parts

22
QtyValueFootprintReferences
8LED_0805_2012MetricLED_0805_2012MetricD1, D2, D3, D4, D5, D6, D7, D8
8R_0805_2012MetricR_0805_2012MetricR1, R2, R3, R4, R5, R6, R7, R8
2C_0805_2012MetricC_0805_2012MetricC1, C2
1BatteryHolder_Keystone_1058_1x2032BatteryHolder_Keystone_1058_1x2032BT1
1PinHeader_1x03_P2.54mm_VerticalPinHeader_1x03_P2.54mm_VerticalJ1
1SOIC-20W_7.5x12.8mm_P1.27mmSOIC-20W_7.5x12.8mm_P1.27mmU1
1SW_SPDT_PCM12SW_SPDT_PCM12SW1

Similar boards

  • 2 layers158 × 11 mmDaylight Matchstick, the printed circuit board in 3D

    Daylight Matchstick

    VoronDesign/Voron-Hardware

    Cool Hardware designed by the Voron Design group

    22 parts1.1kGPL-3.0
  • 2 layers57 × 65 mmRgb to hdmi, the printed circuit board in 3D

    Rgb to hdmi

    hoglet67/RGBtoHDMI

    Bare-metal Raspberry Pi project that provides pixel-perfect sampling of Retro Computer RGB/YUV video and conversion to HDMI

    22 parts1kGPL-3.0
  • 2 layers81 × 57.2 mmRP2040-Macropad, the printed circuit board in 3D

    RP2040-Macropad

    hackclub/OnBoard

    💡 Join 1,000 teenagers and make your first PCB with a $100 grant!

    22 parts915
  • 2 layers54.6 × 70.9 mmBeagleLogic Cape, the printed circuit board in 3D

    BeagleLogic Cape

    abhishek-kakkar/BeagleLogic

    A Software Suite that implements a logic analyzer with the PRU on the BeagleBone / BeagleBone Black.

    22 parts479GPL-3.0
  • 2 layers66.4 × 24.5 mmConnecting piece, the printed circuit board in 3D

    Connecting piece

    Chrismettal/flipper-zero-backpacks

    Backpack-style addon boards for the Flipper Zero!

    22 parts456
  • 2 layers51 × 70 mmDMG A04-01, the printed circuit board in 3D

    DMG A04-01

    HDR/NintendoPCBs

    Replacement pcb's for Nintendo games.

    22 parts321
  • 2 layers27.8 × 16 mmSpi 1v8 level shifter, the printed circuit board in 3D

    Spi 1v8 level shifter

    CRImier/MyKiCad

    My KiCad boards. Can't be bothered uploading individually anymore, so here you go.

    22 parts253GPL-3.0

Questions

How big is the Medalv2 PCB?

It measures 22.5 × 19 mm and has 2 copper layers, 1.6 mm thick.

What parts does the Medalv2 use?

22 parts. 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 Medalv2 KiCad files?

From the VincentPeters/pingpong-medal repository on GitHub, at the commit this page was made from: the board is hardware/cs/medalv2/medalv2.kicad_pcb and its schematic hardware/cs/medal/kdg_pingpong_medal.kicad_sch. PCBKit opens the board in the browser, with nothing to install.

Can I use the Medalv2 design in my own project?

Its repository publishes it under the MIT licence: you may reuse it on that licence's terms (keep the author's notice, and for a copyleft licence share your changes alike).