ESP32 JTAG Debugging can be done through a MicroSD Card Socket

Found in most microcontrollers and processors, JTAG is an industry standard for verifying designs and testing printed circuit boards after manufacture, and that is also often used for low-level debugging or reverse-engineering.

Espressif ESP32 also has a JTAG interface, but interestingly it’s shared with the SD card interface, and in ESP32 LyRaT audio development board where both MicroSD card slot and JTAG header are present selection is made by jumpers.

ESP32 shared SD card & JTAG signals

The extract from ESP32 LyRaT schematics above shows IO’s 12, 13, 14 and 15 can present on the SD card and 4-pin JTAG header. Some boards may not come with a JTAG header but may feature a MicroSD card slot, but you don’t have to solder wires to the board to access JTAG, and instead, you could simply use a custom MicroSD card adapter to insert into the MicroSD card socket of the board and access JTAG as explained by cibomahto on Twitter.

ESP32 JTAG MicroSD Card Adapter

Nice little hardware trick! The photo below shows what it looks like when an ESP32 board is connected to a “JTAG debugger” (actually ESP32-Ethernet-Kit development board with FTDI chip). If your board comes with a full-sized SD card socket using a standard MicroSD to SD adapter should work too.

ESP32 JTAG via Micro SD Card
Click to Enlarge

Reading comments on Twitter also informs use ESP32 is not the first platform with this trick, as (some?) Allwinner processors also route JTAG signals via the SD card interface.

Support CNX Software - Donate via PayPal or become a Patron on Patreon
Advertisements

15
Leave a Reply

avatar
6 Comment threads
9 Thread replies
1 Followers
 
Most reacted comment
Hottest comment thread
11 Comment authors
dimtassDavid WillmorePhilipp Blum Recent comment authors
  Subscribe  
newest oldest most voted
Notify of
guest
Guest
guest

You can get these on AliExpress for $5. Has JTAG and serial console breakouts. Look for ‘uSD breakout board’.
Serrial console works for AllWinner (RX/TX = D3/CLK) and Amlogic (RX/TX = D2/D3), too. Dunno about JTAG.
This is what these breakout boards look like: https://linux-sunxi.org/MicroSD_Breakout

Peter
Guest
Peter

Amlogic also have official SDIO debug board which uses some secret sauce 🙂

comment image

Philipp Blum
Guest
Philipp Blum

Thanks. This is really interesting. I got some Allwinner Boards.

roel
Guest
roel

Where can you find such a custom MicroSD card adapter?

zoobab
Guest

“as (some?) Allwinner processors also route JTAG signals via the SD card interface.”

Remember the Allwinner A10 JTAG SD card breakout:

https://fr.aliexpress.com/item/527673076.html

Philipp Blum
Guest
Philipp Blum

Yeahh… “Sorry, this item is no longer available!”
Too many people bought it ^^ 😀

David Willmore
Guest
David Willmore

Don’t a bunch of allwinner tablets route the debugging UART to the micro-SD slot?

willy
Guest
willy

Another solution might consist in using HardKernel/FriendlyElec’s eMMC to uSD adapters and to either solder directly on the adapter or use a cable.

Member

the JTAG for microsd you can change the GB expansion example micro sd from 128gb and it changes to 512gb you can Sorry I’m new to these technologies but I’m curious to find out.

Advertisements