...
Table of Contents | |
---|---|
minLevel | 1 |
maxLevel | 6 | include |
outline | false | indent |
style | none | exclude |
type | list | class |
printable | true |
...
Table of Contents | ||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
Panel | ||||||||
---|---|---|---|---|---|---|---|---|
| ||||||||
Warning: this document is purely my notes from my own research. Don’t take everything in it for granted especially since I’m a beginner to this sort of stuff, and double check everything, especially if using it for design purposes. I am not purporting to be good at this or to get everything right or to know everything, since this is my first board for Solar. |
...
Expand |
---|
|
Preliminary Research Notes:
USBPD devices can either act as the source (charger) or sink (device) or DRP (both). For our purposes we probably want a sink-only chip since we'll be plugging a charger into this board and the output will be a 12V/GND line. We don't need this to act as a source from a wall outlet.
Compatibility with USBPD 2.0 and USBPD 3.0 would be nice to allow us to use a wider array of laptop chargers.
USBPD 2.0 allows for fixed voltage outputs of 5, 9, 12, 15, and 20V
USBPD 3.0 allows for incremental voltage outputs anywhere from 3.3V to 21V in increments of 20mV. This is called PPS (programmable power supply). We don't really need this since we only need to provide fixed 12V and 5V.
Perhaps considerations should be made for USBPD 3.1 as well, as that would allow for a higher power delivery of 240W and possibly support driving contactors.
3.1 is backwards compatible so designing a 3.1 sink should allow for interfacing with 3.1/3.0/2.0 source
Since we want to max out current I think 3.1 makes the most sense as USBPD 3.1 EPR (Extended Power Rating) cables have the capability of providing up to 240W @ 48V
This may have to wait as there are not many 3.1 sink chips available
According to this reddit post, USBPD3.1 @ 240W probably isn't possible since the sink functionality of it is not well supported. I took a look at a few chips such as ST-ONEHP and TPS25730USB.
USBPD Controller Chip Evaluations:
Expand |
---|
|
Preliminary Research Notes:
Expand |
---|
|
USBPD Controller Chip Evaluations:
Expand |
---|
|
Buck Converter Research:
...
I suppose we'll need a high-efficiency buck converter to step down from max 20V@5A to 12V@8.333A after the whole USB PD negotiation is complete.
Another design consideration was made in this area about the buck converter pipeline. The two possible options were 20V → 12V → 5V (e.g. having chained buck converters) or 20V → 12V AND 20V → 5V (independent buck converters)
Chaining buck converters means that we can use the same 12V → 5V buck converter we typically use, muRata MYLSM00502ERPL. However, this means that if 12V or above is not in a source’s capabilities, then 5V will also fail. Basically 5V is entirely dependent on the 12V working, which limits the set of USB Type-C chargers we can use with this board.
Independent buck converters means that 5V can function without 12V, so if a PD charger WITHOUT 12-20V support is used, we can still test a low voltage device. This seems better but also makes our job as circuit designers more difficult in terms of validation, cost, or efficiency.
Matthew Yu’s notes on LDO vs Buck Converters:
Another one: Buck Converter 2: Electric Boogaloo
Other typical forms of voltage step-down (Linear Voltage Regulator (LDO), Voltage Divider) dissipate power as heat to step down voltage. We lose power in some capacity as heat.
Buck converters will decrease voltage AND increase current to maintain power (typically higher efficiency but less stability when compared to an LDO)
When the switch is closed, the inductor charges up
When the switch is opened, the inductor releases charge through the load resistor RL. The current flows through the diode and back into the inductor
We switch the switch (MOSFET) at a certain frequency and duty cycle in order to keep the average current relatively stable over one period
The capacitor is assumed to have a steady voltage over one period, so it just keeps the voltage drop across RL the same
Watch the Buck Converter 2 video for more explanation and the derivation for the following equation:
Vout = Duty Cycle x Vin (typically)
Datasheet will have more specific calculations for things such as voltage dividers which will ultimately set the duty cycle
A synchronous buck converter replaces the diode with another MOSFET so that there is less power loss since the MOSFET will have lower power loss while current is flowing thru it
Luckily for us, these buck converters come in convenient little ICs that will do all this switching for us
We need two of these, one for 12V and one for 5V
Integrated FET packages (the mosfet comes inside the IC)
Nothing on here that can do more than 6V output
TI TPS56A37
$2.87 on Mouser
4.5V to 28V input
0.6 to 13V output
Supports 10A continuous output current
Seems most appropriate for our 20V->12V use-case especially since other ICs can't supply as much current
QFN package
$0.99 on Mouser
3.8 - 30V input
5V output
3A
12 uA quiescent current
Champers Fu approved!
This one is really good, perhaps we should use it for more designs
External FET Buck Controller packages also exist and were looked into briefly (mosfet is outside the IC, might be more cost-effective and able to provide enough current)
Input Voltage Range
Originally the decision was made to have two buck converters both bucking from the source voltage of 5-20V. The reason this decision was made early on was because a heavy emphasis was being placed on this board working with a wide range of USB PD chargers for a larger applicability.
If your source charger doesn’t support anything from 12-20V, and only supports something 9V or lower, you could still originally operate on the 5V output.
However, this decision needs some reconsideration. First, an argument could be made for not supporting anything other than 20V.
12V isn’t typical on these laptop chargers and is usually considered an “optional” voltage
While it would be cool to run on 5V/9V chargers, perhaps the design considerations necessary for them (such as a 5V buck bypass mosfet in case the voltage input is 5V to prevent voltage dropout, or a similar design on the 12V buck for an input 12V) isn’t worth it.
Most common is the 65W USB-C laptop charger, which usually is 20V at 3.25A (bucks down to approx. 12VV at 5.41666667A).
We could even buy a few of these Anker 100W USB PD chargers for people to use with the device.
Also, we don’t need that much current for the 5V bus since it’s mainly for CAN, so we can safely fail negotiation and then just use SAFE_5V from the USB-PD chip
Additionally, supporting a wider range of voltage inputs is making development slightly more difficult for not all that much gain.
Supporting 5V and 12V requires us to have a bypass MOSFET around the buck converter in order to not lose a lot of power (12V into the 12V buck converter will not output 12V, and similarly with 5V) because if you put Vout into Vin of a buck converter there will be a voltage drop.
All in all, a larger variety of chargers supported may just make our lives harder. Thus, let’s decide to make it only operate if the USB-PD charger supports 15 or 20V.
This is easily modified during testing via placement of different resistors.
Buck Converter Pipeline
15/20V → 12V → 5V, a series configuration, means we only have one unknown voltage input from the USB-PD chip, which is better than having an unknown voltage go into both the 12V and 5V converter.
Power Path & Flowchart:
Expand |
---|
A few notes on this:
|
|
Buck Converter Research:
Expand |
---|
Input Voltage Range
Buck Converter Pipeline
|
Power Path & Flowchart:
Expand |
---|
A few notes on this:
|
PMOS Power Switch Configuration:
Expand |
---|
(Infineon CYPD3177-24LQXQT) Question: What does this even do? Answer:
Let's try to understand the configuration (this is a slightly more detailed version with specific part numbers as presented in the Evaluation Board Design):
A similar configuration is used for the main output of the board as well. The reason we use a PMOSFET controlled switch for VBUS_OUT instead of just directly outputting to the sink is shown below (see pg 10 of Evaluation Board Design) |
TPS56A37RPAR Buck Converter Notes (15-20V → 12V)
...
Nexperia BUK9K52-60RAX
...
12V and 5V Outputs N-Channel MOSFET
For use with PG (power-good indicator) of 12V buck and 5V buck
...
60V Vds
...
16A drain current
...
Vgs = +-10V
...
Expand | |
---|---|
See section 7.2.2 of the datasheet linked above.
From https://github.com/lhr-solar/USBCPowerPCB/blob/v1.0/TPS56A37BuckCalcs.xlsx , the appropriate component values are as follows. Note: calculations were done with Io = 10A since this buck is designed to carry that load. 15/20V → 12V | |
Component | Value |
R1 | 55479.45205 |
R2 | 4987.684729 |
R6 | 383k |
R7 | 20k |
L1 | 5.6uH |
Component | Value |
R1 | 73698.63014 |
R2 | 8367.029549 |
R6 | 73.2k |
R7 | 10k |
L1 | 3.3uH |
ORring Diodes:
Expand |
---|
|
5V → Isolated 5V converter:
Expand |
---|
ROE-0505S is a cheap option available on DigiKey/Mouser that outputs 1W (200mA), which is the most power we can get without jumping up by like $7. It’s very simple to use (V+in, V-in → V+out, V-out). It doesn’t have output power protection though so we’ll add some. |
Power Protections on Output:
...
https://www.analog.com/en/resources/analog-dialogue/raqs/raq-issue-216.html
Now, for the output power protection, the board needs current limit protection against output overload or a short on the connector, and reverse voltage protection against an accidental short to a higher voltage rail.
Development
GITHUB LINK
Latest Components and ICs:
...
Part/Mouser Link
...
Purpose
...
Notes
...
Infineon CYPD3177-24LQXQT
...
PD Controller
...
...
TI TPS56A37RPAR
...
12-20V to 12V buck converter
...
...
Phoenix Contact 1332645
...
USB Type-C Connector
...
PD only requires a subset of the pins of USB Type-C, so a 16 contact connector is fine. (note: i believe we could have even gotten away with a 6 contact connector, but we need to support 5A and the 6p connectors on Mouser only support 3 :/)
...
Infineon IRF9358TRPBF
...
Main Power P-Channel MOSFET
...
Same as used on evaluation kit
...
Infineon BSL308PEH6327XTSA1
...
Safe 5V Power P-Channel MOSFET
...
Same as used on evaluation kit
...
Kingbright APTD2012LSURCK
...
Red Fault LED
...
Standard LHR Mouser Component
...
onsemi NVTR4503NT1G
...
Fault LED N-Channel MOSFET
...
Same as used on evaluation kit
...
Bourns SRP1265A-5R6M
...
15/20V to 12V Buck Converter Inductor
...
See above (TPS56A37 Buck Converter Calculations)
UVLO: Vstart at 14.25V, Vstop at 12.75V
Cap Selection
Output Protection
|
TPS562231DRLR Buck Converter Calculations (12V → 5V):
Expand | ||||||||
---|---|---|---|---|---|---|---|---|
Recommended component values have been provided in the datasheet: From https://github.com/lhr-solar/USBCPowerPCB/blob/v1.0/BuckCalcs.xlsx , the appropriate component values for a 5V output are as follows. R1 = 73.2kOhms R2 = 10kOhms L1 = 4.7uH Cout = 47uF Additionally, bootstrap capacitor from BST to SW of 0.1uF, and Input Capacitor of 10uF for decoupling (and a 0.1uF from VIN to GND for high frequency filtering) Inductor values
Here is an inductor that seems appropriate: https://www.mouser.com/ProductDetail/TAIYO-YUDEN/LBC3225T3R3MR?qs=PzICbMaShUcQtCYfVnc1PQ%3D%3D Self-resonant frequency is 160MHz, far more than 10x greater than switching frequency of 850kHz Maximum DC current is 820mA (greater than 400mA max 5V output, since we are limited on current draw by the 5V Isolated DC-DC converter current) |
TPS2116DRL Power Mux
Expand |
---|
A priority power mux like this one will allow me to switch between the 5V buck output and the safe 5V output from the USB Type-C PD chip all in an integrated package. It also includes reverse current blocking. |
5V → Isolated 5V converter:
Expand |
---|
ROE-0505S is a cheap option available on DigiKey/Mouser that outputs 1W (200mA), which is the most power we can get without jumping up by like $7. It’s very simple to use (V+in, V-in → V+out, V-out). |
Development
GITHUB LINK
Misc. Tips and Design Notes:
Originally I was using the downloaded symbols for the MOSFETs when creating the schematic, but then I realized KiCad has a large base of existing symbols for common device configurations. For example, Device:Q_Dual_NMOS_S1G1S2G2D2D2D1D1 models an NMOS FET similar to the 12V Output N-Channel MOSFET.
Additionally, the MOSFET symbols you might download for one of these things will just look like a rectangle:
vs the KiCAD dual mosfet symbol (far clearer in what it actually is):
So using the symbols from the Device library for a MOSFET, and then linking it later to the downloaded footprint for the desired FET, will make the schematic clearer.
This website is pretty good for resistor values: https://jansson.us/resistors.html
Choose E24 for most commonly available values
Originally I calculated inductors for max input of 20V, but in order to overspec it (as a safety measure) I’m going to redo the calculations for 25V and pick new inductors & ensure that the buck converters will still work as intended
According to this presentation, the voltage tolerance on USB PD is +-5%. The undervoltage lockout points have been set at exactly these values so that we can ensure proper operation.
Use wolfram alpha for conversions and calculations, it works pretty well.
Murata (and many other manufacturers) caps may not provide the DC bias curves for a capacitor on the datasheet directly, but have external design tools linked on the Mouser or Digikey page that will have the specific curve for the selected cap.
Digikey will often have more resources than Mouser, so make sure to check there.
See this reddit comment:
That's just an example graph to show that ferroelectric dielectrics are shit. You need to look at the curves for the specific part number capacitor, which is not always available.
For specific capacitor Vbias curves, I tend to look on the Digikey product page, where it will often be linked.
For Samsung caps, look for "Datasheets: LONG-MFG-PART-NO Characteristics". Example digikey page.Example characteristics datasheet.
For TDK, look for "Datasheets: Character Sheet". Example.
For Murata, look for "Design Resources: SimSurfing Design Tool". Example.
For KEMET, look for "Design Resources: K-SIM Simulation". Example. There's a drop-down menu on the upper left to select "Capacitance vs. Vbias" plot.
I'm pretty sure AVX has something similar, but not seeing an easy example, so no link. I guess they have crap coverage.
I've never found a good link for Taiyo Yuden, though I haven't searched much.
Wurth has a link that looks suspiciously like simulation results, but require you to signup and login, so fuck them. I'm not making an account to learn about your commodity passives.
So the data is out there for like 25-50% of the ceramic caps on digikey. I just assume the rest are garbage and ignore them, but then again I don't have BOM price pressure forcing me to look for cheaper passives. It really should be a column on digikey's parametric sort: delta C @ 75% WV. But I think they have the same problem with data availability that we do.
Adding onto this, Taiyo Yuden has a product searcher that will give you similar characteristic sheets. Given that these are on the cheaper end of caps, having this sort of data on caps we use often is valuable.
If you figure out certain specs for a component but you don’t know others, sometimes it is useful for me to just sort by price and pick the cheapest thing, then see if there’s anything that would bar it from working with your application.
Capacitor selection
Higher capacitor voltage ratings typically exhibit less effective capacitance losses
https://dubiouscreations.com/2021/04/06/designing-with-usb-c-lessons-learned/
Archive:
These are sections that I’ve archived after some review/redesign step. They are preserved here to view along with an explanation of the design decision(s).
- Current monitoring with a 7seg display and MCU was cut because:
- after PSOM transitioned to 12V and 5V became only an isolated supply for CAN testing, there was really no need to monitor current on both 12V and 5V (only 12V)
- felt the need to make development faster and easier
- not really super useful if you have a multimeter and some header pins, more just for the cool factormore just for the cool factor
I suppose one thing I try to keep in mind is to not be too married to a specific idea, and also that something that works and is streamlined in application is often better than the more complicated option.
Current Monitoring
Expand | ||||||||
---|---|---|---|---|---|---|---|---|
Initial Research
Shunt and Amplifier Selection
5V Current Sense Selection
5V Current Sense Selection
12V Current Sense Selection
Note: I changed this decision to just the one-channel variant after deciding that we don’t need 5V current sense. The new part number is INA180A1QDBVRQ1. A Few More OptionsIt’s actually not settled at all.
|
Microcontroller
Expand |
---|
|
- Using TPS562231DRLR buck converter (from the PSOM) w/out power protections; since we need to add a separate power protection chip for the isolated 5V anyways. Plus it’s far easier to use and is cheaper.
TPS62933PDRLR Buck Converter Calculations (12V → 5V):
Expand |
---|
See datasheet linked above, as well as the section above this one.
Inductor selection (starting pg 30 of the datasheet):
Input Capacitor Selection
Output Capacitor Selection
|
- This buck is good and easy to use, but the one we already have (TPS56A37) can already do both 20->12 and 12->5, so I’ll just use that and do two separate configurations
TPS562231DRLR Buck Converter Calculations (12V → 5V):
Expand | ||||||||
---|---|---|---|---|---|---|---|---|
Recommended component values have been provided in the datasheet: Since output voltage = 5V, we’ll be using: R1 = 73.2kOhms R2 = 10kOhms L1 = 4.7uH Cout = 47uF Additionally, bootstrap capacitor from BST to SW of 0.1uF, and Input Capacitor of 10uF for decoupling (and a 0.1uF from VIN to GND for high frequency filtering)
12V Current Sense Selection
Note: I changed this decision to just the one-channel variant after deciding that we don’t need 5V current sense. The new part number is INA180A1QDBVRQ1. A Few More Options
|
Microcontroller
Expand |
---|
|
- Using TPS562231DRLR buck converter (from the PSOM) w/out power protections; since we need to add a separate power protection chip for the isolated 5V anyways. Plus it’s far easier to use and is cheaper.
TPS62933PDRLR Buck Converter Calculations (12V → 5V):
Expand |
---|
See datasheet linked above, as well as the section above this one.
Inductor selection (starting pg 30 of the datasheet):
Input Capacitor Selection
Output Capacitor Selection
|
- Originally planned to use ORring diodes for the 5V and Safe 5V combo wombo but decided to use TPS2116DRL instead.
ORring Diodes:
Expand |
---|
|
- TPS56A37RPAR was the original selection for a buck converter; but did not support 9V and 12V voltages. Matthew suggested that TPS55289 may be the way to go for a buck-boosts that would fit this usecase. However, after learning that it uses I2C for voltage configuration (🤮) I decided to revert back to the TPS56A37, since I did not want to add a microcontroller to the board, nor did I want to have to configure every manufactured power supply.
TPS55289 Buck-Boost Converter Notes (9-20V → 12V)
Expand |
---|
This should allow us to boost to 12V from 9-20V, allowing a greater range of operating voltages. Also supports a 8A current limit. Switching Freq
Output Voltage
|
- These power protections were added initially but deemed as overkill in review, especially since the nice 12V buck handles a lot of this. Replaced by far simpler output protections like a PTC resettable fuse and a diode.
Power Protections:
Expand |
---|
Stole this handy-dandy circuit from the LeaderSOM for Vout protection. It essentially does overvoltage for the 12V output with two back-to-back MOSFETs as discussed previously. Need to change overvoltage lockout point to 12.6V though, as USB PD has a tolerance of +-5%. As according to the MAX1691 datasheet (pg 8):
The other thing we need is current limiting for the 5V 400mA isolated output. For this, I’m using NPS4053 which works from 2.5 - 5.5V and has an adjustable current limit that we’ll set to 390mA so that we don’t fry the isolator chip. 390mA = 23600/Rlim → Rlim = 60.5128205 kOhms We’ll use a 62kOhm since it’s a standardized value which equates to a limit of 380mA. |