

Lokdecoder TI altQuartz
DCC locomotive decoder
- Size
- 22.9 × 15.8 mm
- Copper layers
- 4
- Thickness
- 1.6 mm
- Parts
- 63
- Nets
- 51
- Pads
- 171
- Tracks, vias
- 362, 30
- Pours
- 4
- Routed
- Yes
- KiCad
- KiCad 5 (file 20171130)
- Created
- 12 Feb 2021
- Updated
- 17 Feb 2021
Overview
Lokdecoder TI altQuartz is an open-source printed circuit board by gyuritill, from the gyuritill/DCC-Lokdecoder repository on GitHub, published under the CC0-1.0 licence. It is a 4-layer board of 22.9 × 15.8 mm with 63 parts on 51 nets, routed with 362 tracks and 30 vias.
It is built around the DRV8872DDAR and MIC5205-5.0YM5-TR. Its parts include 10 capacitors, 10 resistors, 8 diodes, 3 ICs and 1 crystal. It belongs with the AVR (ATmega, ATtiny) boards of this library.
Main components
2DRV8872DDAR
HSOP-8-EP-40℃~+125℃ 1 10uA 3.6A 565mΩ Yes HSOP-8-EP Brushed DC Motor Drivers ROHSTexas InstrumentsStepper Motor DriverMIC5205-5.0YM5-TR
SOT-23-5-40℃~+125℃ 1 150mA 16V 350mV@(150mA) 5V 75dB@(100Hz) Fixed Over Current Protection、Over Temperature Protection、Enable Positive SOT-23-5 Voltage Regulators - Linear, Low Drop Out (LDO) Regulators ROHSMicrochip TechnologyVoltage Regulators - Linear, Low Drop Out (LDO) Regulators
README
README.mdDCC-Lokdecoder
Description
DCC multifunction decoder for H0 locomotives
Features
- 1 motor H-bridge output
- 3.6 A peak current
- PWM frequency configurable (1-40 kHz)
- overcurrent and temperature protected
- 10 function outputs
- 115 mA per output
- F0f, F0r, AUX1 and AUX2 are dimmable todo
- mappable to F0-F12 function keys
- DCC asymmetry can be detected (for automatic brake control) todo
Hardware
- 4-layer PCB esigned in KiCAD
- fairly standard components (available from Digi-Key, Farnell, Mouser, etc...)
- hand solderable (I did it too)
- 4 debug LEDs (red, yellow, green and blue)
![]() | ![]() |
|---|---|
| top side | bottom side |
Firmware
- Arduino compatible programming (behaves like an UNO)
- DCC decoding by NmraDcc library
JMRI integration
![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
|---|---|---|---|---|---|
| Basic | Motor | Basic speed control | Speed table | Function map | Advanced |
Install guide
- Get the PCB (e.g. JLCPCB) and the components (e.g. mouser, digikey)
- Solder the components. The SOIC with exposed pad is a bit tricky, it can be soldered from the other side with a big tip and a lot of flux.
- Install the Arduino bootloader using the pads 5V, GND, SCK, MISO, MOSI, RST and an Arduino. Arduino as ISP
- Uncomment the line
#define RESET_FACTORY_DEFAULTSto fill the EEPROM with the default CV values - Upload the code using the pads 5V, GND, RX, TX, DTR and a USB TTL UART cable like this
- Re-comment the line
#define RESET_FACTORY_DEFAULTSto avoid resetting to factory defaults every time. - Upload the code again.
- Add the decoder XML file to JMRI. In DecoderPro select "File-> Import Decoder File..." and browse to the decoder XML. It will take some time, then adds the decoder definition to the database.
- Connect the T1 and T2 pads to the programming track of your DCC system.
- Add new locomotive with the "New Loco" button and then "Read type from decoder". It should detect the correct type:

- If everything is fine, you can install the decoder into your locomotive!
Pinout
| Pad | Function |
|---|---|
| M1 | Motor 1 |
| M2 | Motor 2 |
| T1 | Track 1 |
| T2 | Track 2 |
| V+ | Positive common for function outputs (keep-alive capacitor positive) |
| F0f | F0 function output forward (open drain) |
| F0r | F0 function output reverse (open drain) |
| 1-8 | AUX function output n (open drain) |
| 5V | internal microcontroller +5V supply |
| GND | ground (keep alive capacitor negative) |
| SCK | ISP programming clock (connect to ISP SCK) |
| MISO | ISP programming read (connect to ISP MISO) |
| MOSI | ISP programming write (connect to ISP MOSI) |
| RST | ISP programming reset (connect to ISP reset output) |
| RX | serial programming receive (connect to TTL UART TX) |
| TX | serial programming transmit (connect to TTL UART RX) |
| DTR | serial programming reset through a 100 nF capacitor (connect to TTL UART DTR) |
Todo list
- CV15, CV16 decoder locking
- CV65 kick start
- CV67-94 speed table
- CV27 automatic brake control
- function output dimming
- motor fault check
Parts
63| Qty | Value | Footprint | References |
|---|---|---|---|
| 5 | 2N7002DWCT | Package_TO_SOT_SMD:SOT-363_SC-70-6 | T1, T2, T3, T4, T5 |
| 4 | 100nF | Capacitor_SMD:C_0603_1608Metric | C1, C2, C5, C10 |
| 4 | 1k | Resistor_SMD:R_0603_1608Metric | R7, R9, R10, R11 |
| 3 | 27k | Resistor_SMD:R_0603_1608Metric | R2, R3, R4 |
| 3 | 4.7k | Resistor_SMD:R_0603_1608Metric | R1, R5, R6 |
| 2 | +V | TestPoint:TestPoint_Pad_1.5x1.5mm | TP6, TP17 |
| 2 | 10pF | Capacitor_SMD:C_0603_1608Metric | C8, C9 |
| 2 | 4.7uF | Capacitor_SMD:C_0603_1608Metric | C6, C7 |
| 2 | NSR0530HT1G | Diode_SMD:D_SOD-323 | D3, D4 |
| 1 | 1 | TestPoint:TestPoint_Pad_1.5x1.5mm | TP9 |
| 1 | 16M | myCrystal:Crystal_SMD_2520-2Pin_2.5x2.0mm_HandSoldering | X1 |
| 1 | 2 | TestPoint:TestPoint_Pad_1.5x1.5mm | TP10 |
| 1 | 2.2uF | Capacitor_SMD:C_0805_2012Metric | C4 |
| 1 | 3 | TestPoint:TestPoint_Pad_1.5x1.5mm | TP11 |
| 1 | 4 | TestPoint:TestPoint_Pad_1.5x1.5mm | TP12 |
| 1 | 470pF | Capacitor_SMD:C_0603_1608Metric | C3 |
| 1 | 5 | TestPoint:TestPoint_Pad_1.5x1.5mm | TP13 |
| 1 | 5V | TestPoint:TestPoint_Pad_1.0x1.0mm | TP22 |
| 1 | 6 | TestPoint:TestPoint_Pad_1.5x1.5mm | TP14 |
| 1 | 7 | TestPoint:TestPoint_Pad_1.5x1.5mm | TP15 |
| 1 | 8 | TestPoint:TestPoint_Pad_1.5x1.5mm | TP16 |
| 1 | ATMEGA328P-AUR | Package_QFP:TQFP-32_7x7mm_P0.8mm | IC2 |
| 1 | Bl_LED | LED_SMD:LED_0603_1608Metric | D8 |
| 1 | DRV8872DDAR | Package_SO:Texas_HTSOP-8-1EP_3.9x4.9mm_P1.27mm_EP2.95x4.9mm_Mask2.4x3.1mm_ThermalVias | IC3 |
| 1 | DTR | TestPoint:TestPoint_Pad_1.0x1.0mm | TP25 |
| 1 | D_Bridge_+-AA | Package_TO_SOT_SMD:TO-269AA | D1 |
| 1 | F0f | TestPoint:TestPoint_Pad_1.5x1.5mm | TP7 |
| 1 | F0r | TestPoint:TestPoint_Pad_1.5x1.5mm | TP8 |
| 1 | GND | TestPoint:TestPoint_Pad_1.5x1.5mm | TP5 |
| 1 | GND | TestPoint:TestPoint_Pad_1.0x1.0mm | TP26 |
| 1 | Gr_LED | LED_SMD:LED_0603_1608Metric | D6 |
| 1 | M1 | TestPoint:TestPoint_Pad_1.5x1.5mm | TP1 |
| 1 | M2 | TestPoint:TestPoint_Pad_1.5x1.5mm | TP2 |
| 1 | MIC5205-5.0YM5-TR | Package_TO_SOT_SMD:SOT-23-5 | IC1 |
| 1 | MISO | TestPoint:TestPoint_Pad_1.0x1.0mm | TP20 |
| 1 | MM3Z4V7ST1G | Diode_SMD:D_SOD-323 | D2 |
| 1 | MOSI | TestPoint:TestPoint_Pad_1.0x1.0mm | TP21 |
| 1 | RESET | TestPoint:TestPoint_Pad_1.0x1.0mm | TP18 |
| 1 | RX | TestPoint:TestPoint_Pad_1.0x1.0mm | TP23 |
| 1 | Rd_LED | LED_SMD:LED_0603_1608Metric | D7 |
| 1 | SCK | TestPoint:TestPoint_Pad_1.0x1.0mm | TP19 |
| 1 | T1 | TestPoint:TestPoint_Pad_1.5x1.5mm | TP3 |
| 1 | T2 | TestPoint:TestPoint_Pad_1.5x1.5mm | TP4 |
| 1 | TX | TestPoint:TestPoint_Pad_1.0x1.0mm | TP24 |
| 1 | Ye_LED | LED_SMD:LED_0603_1608Metric | D5 |
Questions
How big is the Lokdecoder TI altQuartz PCB?
It measures 22.9 × 15.8 mm and has 4 copper layers, 1.6 mm thick.
What parts does the Lokdecoder TI altQuartz use?
63 parts, built around the DRV8872DDAR and MIC5205-5.0YM5-TR. 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 Lokdecoder TI altQuartz KiCad files?
From the gyuritill/DCC-Lokdecoder repository on GitHub, at the commit this page was made from: the board is KiCAD_project/Lokdecoder_TI_altQuartz/Lokdecoder_TI_altQuartz.kicad_pcb. PCBKit opens the board in the browser, with nothing to install.
Can I use the Lokdecoder TI altQuartz design in my own project?
Its repository publishes it under the CC0-1.0 licence: you may reuse it on that licence's terms (keep the author's notice, and for a copyleft licence share your changes alike).
Similar boards
- 2 layers120 × 110 mm

- 4 layers27 × 31.5 mm

Amp macom vga
loxodes/vna
Under development open hardware microwave vector network analyzer
63 parts205 - 4 layers71 × 10 mm

001 dot flipper
pierre-muth/fast-flipdot
Driving a flipdot matrix differently. All dots simultaneously.
63 parts145GPL-3.0 - 4 layers68.1 × 66 mm

Ambient
lab11/signpost
Exploring what happens when you put computers on sign posts.
63 parts97Apache-2.0 - 4 layers40 × 40 mm

- 4 layers60.2 × 20.8 mm

PhaseLatchMini
AndersBNielsen/PhaseLatchMini
High-rate continuous streaming of interleaved dual ADC (I/Q) samples over USB Full‑Speed (FS) using only the built‑in CDC class on an STM32F103C8 ("Blue Pill" style) board.
63 parts72 - 4 layers54 × 34 mm

Neurband main
jlcjak/neurband
Open, minimal sEMG wristband like the Meta Neural Band: 8-ch ADS1298 + nRF52832 BLE, dry gold electrodes on a flex, 3D-printed band. KiCad, FreeCAD, Zephyr, Python, simulations.
63 parts46 - 4 layers20.5 × 50.8 mm








