Summary of Contents for sparkfun Power Delivery Board - USB-C (Qwiic)
Page 1
USB power with an adjustable USB voltage from anywhere between 5V and 20V and up to 100W of power. The SparkFun Power Delivery Board takes advantage of the power delivery standard with the use of a standalone controller from STMicroelectronics, the STUSB4500. The controller does all the heavy lifting of power negotiation and provides an easy way to configure over I C.
2/25/2020 Power Delivery Board - USB-C (Qwiic) Hookup Guide - learn.sparkfun.com Required Materials To follow along with this guide, you will need the following materials. You may not need everything, depending on what you have. Add it to your cart, read through the guide, and adjust the cart as necessary.
2/25/2020 Power Delivery Board - USB-C (Qwiic) Hookup Guide - learn.sparkfun.com Suggested Reading Before continuing on with this guide, you may want to familiarize yourself with some of these topics if they're unfamiliar to you. If you aren't familiar with the Qwiic system, we recommend reading here for an overview.
Page 4
2/25/2020 Power Delivery Board - USB-C (Qwiic) Hookup Guide - learn.sparkfun.com When it comes to power delivery you have two types of power roles. The first is the provider, also known as the source, which is capable of providing power over the USB power bus. The other role is the consumer, also known as the sink, which draws power from the source.
Page 5
2/25/2020 Power Delivery Board - USB-C (Qwiic) Hookup Guide - learn.sparkfun.com Qwiic Connector Top View Bottom View I2C PTH Pins Pins The board breaks out the following pins: Pin Name Description This is the input power pin, which is connected to VBUS on the Type-C connector.
Page 6
2/25/2020 Power Delivery Board - USB-C (Qwiic) Hookup Guide - learn.sparkfun.com VSNK Power output enabled after successful power negotiation Optional logic power input, 3.0V - 5.5V Ground I C clock input I C data input/output USB 2.0 differential pair, negative USB 2.0 differential pair, positive...
Page 7
2/25/2020 Power Delivery Board - USB-C (Qwiic) Hookup Guide - learn.sparkfun.com How to Work with Jumper Pads and PCB Traces APRIL 2, 2018 Handling PCB jumper pads and traces is an essential skill. Learn how to cut a PCB trace, add a solder jumper between pads to reroute connections, and repair a trace with the green wire method if a trace is damaged.
2/25/2020 Power Delivery Board - USB-C (Qwiic) Hookup Guide - learn.sparkfun.com Open Closed 0x29 Closed Open 0x2A Open Open 0x2B Pull-Up Resistors The board also includes jumpers to disable the pull-up resistors on the I C bus. If you are using a few I C devices on the same bus that already have pull-up resistors on their board, you may want to cut the jumpers to disconnect these pull-up resistors.
Page 9
2/25/2020 Power Delivery Board - USB-C (Qwiic) Hookup Guide - learn.sparkfun.com On power-up, or after a reset, the NVM parameters are copied into the I C registers and used by the controller during the system operation. The controller can store up to three PDOs, with PDO3 having the highest priority and PDO1 having the lowest.
2/25/2020 Power Delivery Board - USB-C (Qwiic) Hookup Guide - learn.sparkfun.com Image courtesy of Chindi.ap, CC BY-SA 4.0 Of the 24 pins of the USB Type-C connector (shown above), the STUSB4500 only connects directly to 10 of these: 4 pins are used for VBUS, another 4 pins to ground, and the 2 channel configuration, or CC, pins. Depending on the cable orientation, one of these CC pins is used to send and receive messages between the sink and source.
Page 11
2/25/2020 Power Delivery Board - USB-C (Qwiic) Hookup Guide - learn.sparkfun.com Note: If you've never connected an CH340 device to your computer before, you may need to install drivers for the USB-to-serial converter. Check out our section on How to Install CH340 Drivers" for help with the installation.
Page 12
Power Delivery Board - USB-C (Qwiic) Hookup Guide - learn.sparkfun.com SparkFun has written a library to control the Power Delivery board for the STUSB4500. You can obtain this library through the Arduino Library Manager. By searching for STUSB4500, you should see one written by SparkFun Electronics and you should be able to install the latest version.
Page 13
2/25/2020 Power Delivery Board - USB-C (Qwiic) Hookup Guide - learn.sparkfun.com uint8_t getUpperVoltageLimit( uint8_t pdo_numb ) - Returns the over voltage lockout parameter for the PDO number (1-3). The value returned will be between 5% and 20%. float getFlexCurrent( void ) - Return the value for the flex current parameter, which is a global variable common to all PDOs.
Page 14
2/25/2020 Power Delivery Board - USB-C (Qwiic) Hookup Guide - learn.sparkfun.com void setCurrent( uint8_t pdo_numb, float current ) - Takes two parameters: pdo_numb (1-3), and current (16 values). The current values are: 0 (Flex Current), 0.5A, 0.75A, 1.0A, 1.25A, 1.50A, 1.75A, 2.0A, 2.25A.
2/25/2020 Power Delivery Board - USB-C (Qwiic) Hookup Guide - learn.sparkfun.com POWER_OK3 Hi-Z No functionality Hi-Z No Source Attached VBUS_EN_SNK Source Attached Hi-Z No explicit PD contract Configuration2 POWER_OK2 PD explicit contract with PDO2 Hi-Z No explicit PD contract POWER_OK3...
Page 16
2/25/2020 Power Delivery Board - USB-C (Qwiic) Hookup Guide - learn.sparkfun.com When the value of bit-0 is 1 No hardware fault Hi-Z Hardware fault detection such as over detected Error temperature, over voltage on the CC pins, Recovery or after a hard reset...
Page 17
After the library has been installed, access the first example from your Arduino menu by clicking on: File > Examples > SparkFun STUSB4500 > Example1-ReadParameters. Select your board (in this case SparkFun RedBoard and COM port that the board enumerated to. Hit the upload button. Open the serial monitor at 115200 baud to see what the current settings are.
Page 18
2/25/2020 Power Delivery Board - USB-C (Qwiic) Hookup Guide - learn.sparkfun.com The input power is 100-240 VAC and up to 1.5A of primary current. The output can provide one of the following: 20V/4.3A, or 15V/2A, or 9V/3A, or 5V/2.4A. Based on these options, let's change the voltage to 15V. That voltage option is able to draw up to 2A of current.
Page 19
This example demonstrates how to write new NVM settings to the STUSB4500 Quick-start: - Use a SparkFun RedBoard Qwiic -or- attach the Qwiic Shield to your Arduino/Photon/ESP 32 or other - Upload example sketch - Plug the Power Delivery Board onto the RedBoard/shield...
Page 20
2/25/2020 Power Delivery Board - USB-C (Qwiic) Hookup Guide - learn.sparkfun.com Serial.println("Cannot connect to STUSB4500."); Serial.println("Is the board connected? Is the device ID correct?"); while(1); Serial.println("Connected to STUSB4500!"); delay(100); float voltage, current; byte lowerTolerance, upperTolerance, pdoNumber; pdoNumber = usb.getPdoNumber(); voltage = usb.getVoltage(3);...
SparkFun Technical Assistance page for some initial troubleshooting. If you don't find what you need there, the SparkFun Forums are a great place to find and ask for help. If this is your first visit, you'll need to create a Forum Account to search product forums and post questions.
Page 23
2/25/2020 Power Delivery Board - USB-C (Qwiic) Hookup Guide - learn.sparkfun.com Qwiic Quad Relay Hookup Guide Beginner Parts Kit Identification Guide SparkFun’s Qwiic Quad Relay is a product designed for The essential parts for beginning (or even experienced) switching not one but four high powered devices from...
Need help?
Do you have a question about the Power Delivery Board - USB-C (Qwiic) and is the answer not in the manual?
Questions and answers