USB C-thru: Open USB Type-C/PD Probe

← View All Updates

Mar

07

Demo #2: Explore Google Chromium USB Type-C example designs using USB C-thru

Google is one of the early adopters of USB Type-C and USB Power Delivery in their Chromium projects. Interestingly, Google shared the complete design of the USB Type-C products in the public domain, from the schematic to source code of their implementations. This article explores how to use USB C-Thru board to explore Google’s designs, thereby helping you to develop custom design of your own.

This article shows you how to make your own Google USB-PD Sniffer, a.k.a. “Twinkie”, using the USB C-Thru and a STM32 development board ($65.00 USD) in three steps.

Hardware requirements:

  1. USB C-Thru

  2. STM32F072B development kit

Step 1: Preparing software and firmware binary for Google’s USB PD Sniffer

  • Google has made its USB Type-C designs public via its Chromium website as shown in Figure 1 below:

Figure 1: List of USB Type-C design examples from Chromium website

  • In this exercise we’ll explore the “USB Type-C debug dongle and sniffer for USB-PD communications” project. (The USB PD Sniffer tool is also known as Twinkie.)

  • Check out the complete Twinkie setup guide.

  • Order an STM32F072 Discovery kit, which is the base platform used by Twinkie.

  • Generate the binary file “twinkie.bin” and flash it to the STM32 Discovery kit using the “dfu-utils” host utility, as described in Chromium website.

Step 2: Setting up Hardware STM32F072B-DISCO with USB C-thru

Now that you’ve set up the necessary software and flashed the board with firmware, let’s explore how to set up the hardware to build a Twinkie.

Figure 2: Schematic of Twinkie indicating CC pins

  • Now, connect pins PA1(grey), PA3(orange) and ground(black) from the STM32 board to the USB C-Thru (PA1 to CC1, PA3 to CC2) as shown in Figure-3 below:

Figure 3: Schematic of Twinkie indicating CC pins

This setup gives you enough of the Twinkie functionality to act as a USB PD sniffer.

Step 3: Start sniffing USB PD data with homemade sniffer

With the USB C-thru board and the STM32 discovery board set up and connected, the sniffer is ready to deploy for debugging. In the example setup, we are using a laptop with a USB Type-C charger and USB-C Thru-based sniffer connected to an Ubuntu PC.

  • Using a USB2.0 mini cable, connect the STM32 development board to the host PC where Google’s USB PD sniffer software was set up (Step 1). An “lsusb” on the host PC shows the USB PD Sniffer as shown in the Figure-4 below:

Figure 4: Enumeration of STM32 development board as Twinkie device

  • Plug USB C-Thru into the laptop and the USB Type-C Charger to the receptacle end of the USB C-Thru as shown in Figure-5 below:

Figure 5: Google’s USB Type-C example design Twinkie implementation using USB C-thru and STM32


Conclusion

This article provided a quick walk-through of how to use USB C-Thru board with an existing development kit, demonstrating how to make your own USB Type-C experimental design. You can explore other Chromium USB Type-C design examples in similar manner with a few wire wrapped electronics.

In the next article we will provide test results of USB C-Thru from 3rd party labs.

Order your USB C-thru today, and feel free to write us for any clarification at info@goarks.com.

$2,015 raised

of $5,000 goal

Funding Unsuccessful

Apr 01

ended

40%

funded

11

pledges

Credits

GoArks

We are a systems software startup focusing in USB Type-C and Legacy USB products and services.


Kartik Raghavan

Founder

Rajaram Regupathy

Founder

Subscribe to receive the Crowd Supply weekly newsletter, highlighting the latest creators and projects: