DirtyJTAG
FreeJTAG adapter firmware for STM32F1
FreeFree tier
About DirtyJTAG
DirtyJTAG is an open-source firmware that transforms cheap ST-Link v2 clones and generic STM32F1 development boards (blue pill, black pill) into a low-cost JTAG adapter. Designed as an alternative to obsolete LPT Wiggler cables and expensive USB JTAG probes, it supports multiple software tools including UrJTAG, openFPGAloader, and flashrom. The firmware is intentionally simple (~1k lines of C code) and easy to hack, with detailed documentation for compilation and debugging. It is licensed under MIT and uses USB VID 0x1209/PID 0xC0CA registered via pid.codes.
Key Features
Cost-effective: uses $2 ST-Link clones and generic STM32F1 boards
Open source under MIT license
Compatible with UrJTAG, openFPGAloader, flashrom (OpenOCD patch in review)
Easily hackable: ~1k lines of C code with clear structure
Supports multiple boards: Bluepill, ST-Link v2 clone (dongle, white case, Baite), Olimex STM32-H103, Raspberry Pi Pico, Tang Nano 20k
USB VID/PID registered with pid.codes (0x1209/0xC0CA)
Detailed compilation and debugging documentation provided
Pros & Cons
Pros
- Very low cost (hardware from $2)
- Open source, MIT licensed
- Simple and understandable codebase (around 1k lines)
- Broad software compatibility (UrJTAG, flashrom, openFPGAloader)
- Supports various STM32 development boards
Cons
- Not fast or a perfect JTAG implementation (stated by project)
- Limited to STM32F1-based boards (F101, F103)
- Requires building firmware from source (no pre-built binaries provided)
- OpenOCD support is not yet official (patch still under review)
Best For
Debugging and programming JTAG-compatible devices (FPGAs, microcontrollers)Educational projects for learning JTAG protocol and firmware developmentLow-cost alternative to commercial JTAG probes for hobbyists and researchersHardware hacking and firmware reverse engineering
FAQ
What is DirtyJTAG?
DirtyJTAG is a JTAG adapter firmware for $2 ST-Link clones and generic STM32 development boards (blue pill/black pill).
Which hardware boards are supported?
Bluepill, ST-Link v2 clone (dongle, white case, Baite), Olimex STM32-H103, Raspberry Pi Pico, and Tang Nano 20k.
What software tools are compatible?
UrJTAG (since 2017.10), openFPGAloader (since v0.1), flashrom (since 1.3), and OpenOCD (patch in review).
What USB VID/PID does it use?
VID=0x1209, PID=0xC0CA (registered with pid.codes).
Is DirtyJTAG fast?
No, it is not fast nor a perfect implementation of the JTAG protocol, as stated by the project.