Silicon ChipUSB-C Power Monitor, part one - August 2026 SILICON CHIP
  1. Contents
  2. Publisher's Letter: Europe needs a proactive policy on local tech & manufacturing
  3. Subscriptions: ETI Bundles
  4. Feature: How USB-C Power Delivery Works by Andrew Levido
  5. Project: USB-C Power Monitor, part one by Tim Blythman
  6. Feature: Teach-In 2026 by Mike Tooley
  7. Project: The RP2350B Computer by Geoff Graham & Peter Mather
  8. Feature: The Fox Report
  9. Feature: Circuit Surgery by Ian Bell
  10. Feature: Max’s Cool Beans by Max the Magnificent
  11. Feature: Power Electronics Part 5: power factor correction & EMI fifiltering by Andrew Levido
  12. Back Issues
  13. Feature: Audio Out by Jake Rothman
  14. Feature: Techno Talk by Max the Magnificent
  15. PartShop
  16. Market Centre
  17. Advertising Index
  18. Back Issues

This is only a preview of the August 2026 issue of Practical Electronics.

You can view 0 of the 80 pages in the full issue.

Items relevant to "USB-C Power Monitor, part one":
  • USB-C Power Monitor PCB set [04102251-3] (AUD $7.50)
  • PIC16F18146-I/SO programmed for the USB-C Power Monitor [0410225A.HEX] (Programmed Microcontroller, AUD $10.00)
  • 0.91-inch white OLED with 4-pin I²C interface (Component, AUD $7.50)
  • USB-C Power Monitor short-form kit (Component, AUD $60.00)
  • Firmware for the USB-C Power Monitor [0410225A.HEX] (Software, Free)
  • USB-C Power Monitor PCB patterns [04102251-2] (Free)
Articles in this series:
  • USB-C Power Monitor, part one (August 2026)
  • USB-C Power Monitor, part one (September 2026)
  • USB-C Power Monitor, part one (October 2026)
  • USB-C Power Monitor, part one (November 2026)
Articles in this series:
  • Teach-In 12.1 (November 2025)
  • Teach-In 2026 (December 2025)
  • Teach-In 2026 (January 2026)
  • Teach-In 2026 (February 2026)
  • Teach-In 2026 (March 2026)
  • Teach-In 2026 (April 2026)
  • Teach-In 2026 (June 2026)
  • Teach-In 2026 (July 2026)
  • Teach-In 2026 (August 2026)
  • Teach-In 2026 (September 2026)
  • Teach-In 2026 (October 2026)
  • Teach-In 2026 (November 2026)
Articles in this series:
  • Circuit Surgery (April 2024)
  • STEWART OF READING (April 2024)
  • Circuit Surgery (May 2024)
  • Circuit Surgery (June 2024)
  • Circuit Surgery (July 2024)
  • Circuit Surgery (August 2024)
  • Circuit Surgery (September 2024)
  • Circuit Surgery (October 2024)
  • Circuit Surgery (November 2024)
  • Circuit Surgery (December 2024)
  • Circuit Surgery (January 2025)
  • Circuit Surgery (February 2025)
  • Circuit Surgery (March 2025)
  • Circuit Surgery (April 2025)
  • Circuit Surgery (May 2025)
  • Circuit Surgery (June 2025)
  • Circuit Surgery (July 2025)
  • Circuit Surgery (August 2025)
  • Circuit Surgery (September 2025)
  • Circuit Surgery (October 2025)
  • Circuit Surgery (November 2025)
  • Circuit Surgery (December 2025)
  • Circuit Surgery (January 2026)
  • Circuit Surgery (February 2026)
  • Circuit Surgery (March 2026)
  • Circuit Surgery (April 2026)
  • AUDIO OUT (May 2026)
  • Circuit Surgery (June 2026)
  • Circuit Surgery (July 2026)
  • Circuit Surgery (August 2026)
  • Circuit Surgery (September 2026)
  • Circuit Surgery (October 2026)
  • Circuit Surgery (November 2026)
Articles in this series:
  • Max’s Cool Beans (January 2025)
  • Max’s Cool Beans (February 2025)
  • Max’s Cool Beans (March 2025)
  • Max’s Cool Beans (April 2025)
  • Max’s Cool Beans (May 2025)
  • Max’s Cool Beans (June 2025)
  • Max’s Cool Beans (July 2025)
  • Max’s Cool Beans (August 2025)
  • Max’s Cool Beans (September 2025)
  • Max’s Cool Beans: Weird & Wonderful Arduino Projects (October 2025)
  • Max’s Cool Beans (November 2025)
  • Max’s Cool Beans (December 2025)
  • Max’s Cool Beans (January 2026)
  • Max’s Cool Beans (February 2026)
  • Max’s Cool Beans (March 2026)
  • Max’s Cool Beans (April 2026)
  • AOShop (May 2026)
  • Max’s Cool Beans (June 2026)
  • Max’s Cool Beans (July 2026)
  • Max’s Cool Beans (August 2026)
  • Max’s Cool Beans (September 2026)
  • Max’s Cool Beans (October 2026)
  • Max’s Cool Beans (November 2026)
Articles in this series:
  • Power Electronics Part 1: DC-DC Converters (April 2026)
  • SSB Shortwave Receiver (May 2026)
  • Power Electronics Part 3: Isolated DC-DC Converters (June 2026)
  • Power Electronics Part 4: AC-DC Converters with Rectifiers (July 2026)
  • Power Electronics Part 5: power factor correction & EMI fifiltering (August 2026)
  • Power Electronics Part 5: power factor correction & EMI fifiltering (September 2026)
  • Power Electronics Part 5: power factor correction & EMI fifiltering (October 2026)
  • Power Electronics Part 5: power factor correction & EMI fifiltering (November 2026)
Articles in this series:
  • Audio Out (January 2024)
  • Audio Out (February 2024)
  • AUDIO OUT (April 2024)
  • Audio Out (May 2024)
  • Audio Out (June 2024)
  • Audio Out (July 2024)
  • Audio Out (August 2024)
  • Audio Out (September 2024)
  • Audio Out (October 2024)
  • Audio Out (March 2025)
  • Audio Out (April 2025)
  • Audio Out (May 2025)
  • Audio Out (June 2025)
  • Audio Out (July 2025)
  • Audio Out (August 2025)
  • Audio Out (September 2025)
  • Audio Out (October 2025)
  • Audio Out (November 2025)
  • Audio Out (December 2025)
  • Audio Out (January 2026)
  • Audio Out (February 2026)
  • Audio Out (March 2026)
  • Audio Out (April 2026)
  • Audio Out (June 2026)
  • Audio Out (July 2026)
  • Audio Out (August 2026)
  • Audio Out (September 2026)
  • Audio Out (October 2026)
  • Audio Out (November 2026)
Articles in this series:
  • Techno Talk (February 2020)
  • Techno Talk (March 2020)
  • (April 2020)
  • Techno Talk (May 2020)
  • Techno Talk (June 2020)
  • Techno Talk (July 2020)
  • Techno Talk (August 2020)
  • Techno Talk (September 2020)
  • Techno Talk (October 2020)
  • (November 2020)
  • Techno Talk (December 2020)
  • Techno Talk (January 2021)
  • Techno Talk (February 2021)
  • Techno Talk (March 2021)
  • Techno Talk (April 2021)
  • Techno Talk (May 2021)
  • Techno Talk (June 2021)
  • Techno Talk (July 2021)
  • Techno Talk (August 2021)
  • Techno Talk (September 2021)
  • Techno Talk (October 2021)
  • Techno Talk (November 2021)
  • Techno Talk (December 2021)
  • Communing with nature (January 2022)
  • Should we be worried? (February 2022)
  • How resilient is your lifeline? (March 2022)
  • Go eco, get ethical! (April 2022)
  • From nano to bio (May 2022)
  • Positivity follows the gloom (June 2022)
  • Mixed menu (July 2022)
  • Time for a total rethink? (August 2022)
  • What’s in a name? (September 2022)
  • Forget leaves on the line! (October 2022)
  • Giant Boost for Batteries (December 2022)
  • Raudive Voices Revisited (January 2023)
  • A thousand words (February 2023)
  • It’s handover time (March 2023)
  • AI, Robots, Horticulture and Agriculture (April 2023)
  • Prophecy can be perplexing (May 2023)
  • Technology comes in different shapes and sizes (June 2023)
  • AI and robots – what could possibly go wrong? (July 2023)
  • How long until we’re all out of work? (August 2023)
  • We both have truths, are mine the same as yours? (September 2023)
  • Holy Spheres, Batman! (October 2023)
  • Where’s my pneumatic car? (November 2023)
  • Good grief! (December 2023)
  • Cheeky chiplets (January 2024)
  • Cheeky chiplets (February 2024)
  • The Wibbly-Wobbly World of Quantum (March 2024)
  • Techno Talk - Wait! What? Really? (April 2024)
  • Techno Talk - One step closer to a dystopian abyss? (May 2024)
  • Techno Talk - Program that! (June 2024)
  • Techno Talk (July 2024)
  • Techno Talk - That makes so much sense! (August 2024)
  • Techno Talk - I don’t want to be a Norbert... (September 2024)
  • Techno Talk - Sticking the landing (October 2024)
  • Techno Talk (November 2024)
  • Techno Talk (December 2024)
  • Techno Talk (January 2025)
  • Techno Talk (February 2025)
  • Techno Talk (March 2025)
  • Techno Talk (April 2025)
  • Techno Talk (May 2025)
  • Techno Talk (June 2025)
  • Techno Talk (July 2025)
  • Techno Talk (August 2025)
  • Techno Talk (October 2025)
  • Techno Talk (November 2025)
  • Techno Talk (December 2025)
  • Techno Talk (January 2026)
  • Techno Talk (February 2026)
  • Techno Talk (March 2026)
  • Techno Talk (April 2026)
  • Techno Talk (May 2026)
  • Techno Talk (May 2026)
  • Techno Talk (June 2026)
  • Techno Talk (July 2026)
  • Techno Talk (August 2026)
  • Techno Talk (September 2026)
  • Techno Talk (October 2026)
  • Techno Talk (November 2026)
Constructional Project USB--C USB Part 1 by Tim Blythman Power Monitor It is always handy to know what voltage and current a USB device is using. Now that USB-C is prevalent, it’s time for a USB-C Power Monitor. It can be used for all modern USB-C devices, as well as legacy USB devices, with the right adaptor. T here are many situations where it’s helpful to see how much power or current a USB device is drawing, or what voltage is being applied to it. This design makes that very easy, and it works with virtually all modern USB-C devices. Say you have a fast charger and a smartphone or tablet that’s capable of fast charging. While the situation is getting better, there are cases where they are incompatible and will not actually fast charge, or will, but only at a modest rate. With this device, you can see exactly how much power is being transferred. Another situation is if you are developing a USB device and you want to see how much power it draws when performing certain functions, or whether it’s correctly signalling the power supply to give it a certain voltage or amount of power. Ideally, you want a compact device that can just be plugged between two devices, with a screen to show the voltage, current, power, energy and more. That’s exactly what this device is. It doesn’t even matter which way around you connect it – it can monitor current and thus power flow in either direction! It doesn’t need an external power supply, either. Its controls are simple yet intuitive; it uses just three pushbuttons and an OLED screen. A bit of history Low-cost USB power monitoring devices are available but many of them will not work with the latest USB standards and devices. Many of them simply insert a shunt resistor in series with the VBUS pin and monitor the voltage across it to determine the device’s current draw. They will also measure the VBUS voltage itself. By multiplying those two values, they can calculate the power draw. More advanced devices can also accumulate the power figure over time to derive a total energy figure. We published a design along those lines in the August 2016 issue, which used an LCD screen to show the USB voltage, current draw, power and more. Critically, though, many of these devices (like the one just mentioned) are based around the assumption (that was true until recently) that VBUS will always be in the range of 4.75-5.25V. They also usually only have USB Type-A plugs and sockets. While such devices can be useful, their legacy Type-A connectors rule out the option of working with newer USB 3.x features, such as Power Delivery (PD) or SuperSpeed USB data transfer. If USB Power Delivery were somehow to be used with these devices connected, and VBUS rose to 12V or higher, they may well break, possibly in spectacular fashion! Also, keep in mind that with USB 3.x, power can flow in either direction as the cables now have the same USB-C connector at either end. Those earlier monitors usually also assumed power conuld only flow in one direction. USB-C is now very widespread. We have recently switched to using USB-C sockets on practically all projects that need a USB connection. In 2024, USB-C was legislated in the European Union as the standard charging port for mobile phones and similar gadgets. The demand for higher currents, higher voltages and the consequent higher power levels means that a USB-C Power Monitor is necessary for some scenarios. USB-PD (power delivery) is currently rated to provide up to 48V at 5A, well beyond what the older USB power monitors can tolerate or measure. Of course, legacy USB 2.0 devices with the older USB-A and USB-B connectors can work with our new USB Silicon Chip Short-form Kit (SC7489, ~£38 + P&P): this kit includes all the non-optional parts listed except the case, lithium-ion cell and glue. It also includes the FFC (flat flexible cable PCB) for joining the two PCBs. 10 Practical Electronics | August | 2026 USB-C Power Monitor, part one Features & Specifications ● Main screen reports current, voltage, power, energy (in J or Wh) & time ● Configuration channel (CC) status screen ● All 24 USB data lines pass through ● Self-contained with 400mAh rechargeable lithium battery ● Internal battery means no extra load on the USB circuit under test ● Compact case is only 80 × 40mm ● Automatic offset trimming ● Voltage measurements: up to 60V with 10mV resolution ● Current measurements: up to ±5A with 1mA resolution; 10μA resolution below ~25mA ● Power: up to 300W with 1mW resolution (limited by V and I) ● Energy: up to 999999J (1mJ resolution) or up to 999Wh (10μWh resolution) ● Battery consumption: <20mA, giving 20 hours of usage per charge ● Sleep mode: <10μA drawn from battery, less than typical self-discharge Power Monitor with simple adaptors. However, there is a lot more to the USB-C Power Monitor than just adding USB-C connectors to an older design! We’ll describe some of the technical features that apply to USB-C and how they have affected our design. If you want more background on USB Power Delivery technology, see our article on “How USB Power Delivery works”, starting on page 4 of this issue. nominal 5V, meaning that it could directly power a 5V microcontroller without even needing a regulator. In fact, all the ICs on the original USB Power Monitor run directly from the USB 5V supply. Given USB’s broad usage as a power supply and for charging, it was also useful when no USB communication takes place. For example, you could use it to check how much current a mobile phone used while charging. Early USB was simple USB-C is a 2014 design that allows all USB protocols, so far up to USB4, to be transmitted. Importantly, USB-C only specifies things like the connectors and cables; it permits many other protocols aside from USB. Some other communication technologies that can be carried over USB-C include Thunderbolt, PCIe, HDMI and DisplayPort (including digital video & audio). The USB-C connector is symmetrical and can be inserted in two ways (no The original USB 1.0 specification dates back to 1996, and uses much the same hardware and electrical arrangement as the later USB 1.1 and USB 2.0 standards. Two conductors (V bus and GND) are provided for a nominal 5V power supply. Another two conductors (D+ and D−) providing a bi-­d irectional differential signalling pair. A separate shield connection is also present. These connections are carried through the original USB Power Monitor, with only the Vbus line interrupted by a current measuring shunt. All these earlier specifications have been carried forward into the newer versions of the USB specifications, although many aspects are now considered ‘legacy’. The design of the plugs and sockets enforced upstream and downstream ends. Assuming the standards have been followed, this means that current can only flow one way, and thus the USB Power Monitor’s simple design only needed to handle current flowing in one direction. The supply voltage was fixed at a Practical Electronics | August | 2026 The USB-C standard more fumbling to figure out the right way!). It can also be used at both ends of a cable, so the cable itself does not enforce an upstream or downstream end; current and data can flow either way in a USB-C cable. In fact, USB-C allows the power source or sink role to be separate from the USB host or device function. USB-PD (USB power delivery) provides a means to negotiate voltages up to 48V and currents up to 5A. So clearly, there are many factors that need to be considered in designing a USB-C capable power monitor. Because of all these features, a USB-C receptacle can have up to 24 conductors, plus a shield. Some of these are symmetrically arranged duplicates. For example, there are four ground pins and four V bus pins to share the current load, as shown in Fig.1. The plug is mirrored relative to the socket. In the receptacle, there are two each of the D+ and D− legacy USB data pins. There are four more differential pairs, two in each direction. These are the same pairs that were introduced with USB 3.0, and the blue-coloured connectors that marked the new SuperSpeed transfer rate. The four remaining conductors are for signalling related to USB-C’s features. The two CC (configuration channel) lines are the channel over which USB-PD communication takes place. The aforementioned article on how USB Power Delivery works gets into the details of the power delivery protocol. There are now chips specifically designed to handle USB-PD communications, and these are often found in the so-called ‘trigger’ or ‘decoy’ modules that can request a specific voltage Fig.1: USB-C’s design incorporates rotational symmetry, removing the need to flip the connector like earlier USB plugs/sockets. This requires extra conductors, with many being duplicated. The configuration channel lines provide cable rotation detection for correct operation. 11 Constructional Project The main PCB of the Power Monitor connects to the USB Breakout board using a flexible PCB (FFC). A typical USB-PD trigger board has a USB-C socket, a USBPD interface IC and an output connector. This example sets the requested PD voltage by solder jumpers; some can be controlled digitally, with an I2C serial interface or similar. using USB-PD’s digital signalling. The photo above shows an example of such a module. Early versions of USB-PD supported up to six power profiles at various currents and voltages of 5V, 12V or 20V. Subsequent revisions added support for 9V, 15V, 28V, 36V and 48V. A more recent protocol, known as PPS (Programmable Power Supply), allows voltages to be requested up to 21V in 20mV steps and current limits in 50mA steps. The simplest signalling is done via pullups and pulldowns on the CC lines with specific resistor values; this can be used to offer or request the legacy 5V supply voltage. We have used this arrangement in our projects using USB-C sockets for 5V power. Fig.2 shows the basic arrangement using the resistor-based signalling, which is quite simple and elegant. Only one CC line is typically connected through in a cable; this allows both devices to determine the orientation of the conductors if the cable has been flipped. The source will only apply Vbus if it sees that a sink has connected with the correct pulldown resistance. The pulldown can be applied by a simple resistor to ground, so the signalling will work even on a device that has no power to begin with. Cleverly, V bus switching can be achieved by not much more than a logic-­l evel P-channel Mosfet. The Mosfet’s gate is pulled up until a sink 12 is connected, switching the Mosfet off. The sink’s Rd resistor pulls the gate low and turns the Mosfet on, allowing the source to provide current to the sink. The current that the source applies to the CC line also encodes a Vbus current capacity, and the sink can detect this by the voltage across the Rd resistor on the CC line. This allows sink devices to limit their current draw to what the source can provide. The second CC conductor can also supply power to the electronics embedded in an ‘e-marked’ cable. In this role, it is known as Vconn, indicated by the resistors labelled Ra in Fig.2. E-marking involves embedding a chip inside the cable. One use of such a chip is to indicate to the source that the cable can handle 5A. Any cable that is not identified as such is limited to 3A. The CC lines are also used to communicate other USB-C features, such as support for alternative modes. Finally, there are the two SBU (sideband use) lines, which are used by an audio adaptor accessory mode and the USB4 protocol. It’s also possible to use them for a specific custom purpose through USB-PD negotiation. In summary, USB-C offers a lot more variety in voltages, currents and protocols than the legacy standards and connectors. So the USB-C Power Monitor has more to do than just measure the current and voltage. We need to be able to measure voltages up to 48V and monitor currents up to 5A in either direction. There are signals, such as those on the CC lines, that we can monitor for connectivity and possibly take control of. We considered including a USB-PD chip to allow monitoring of the power delivery communications, but ultimately decided against doing so. Most of these chips are in leadless packages (eg, QFN) that are difficult to solder. We also thought it would be best to avoid a situation where multiple chips are trying to communicate over the same configuration channel bus, lest that lead to improper voltages being requested, potentially causing damage to equipment connected to the Monitor. USB-C specifications It is an unfortunate fact that the USB-C Power Monitor (or any design like it) cannot meet the USB-C specifications. As you can see from the photos, it has a USB-C socket at one end and a USB-C plug at the other. As such, it is effectively a USB-C extension cable. Such cables are simply forbidden by Fig.2: the basic signalling used on the CC lines requires sources and sinks to use specific resistor values (or current sources/sinks) to determine rotation and the current required. Before a source can apply power on Vbus, it must detect that a sink is correctly connected. Practical Electronics | August | 2026 USB-C Power Monitor, part one the specification. Consider what would happen if a 5A e-marked cable were connected to a 3A extension cable. The signalling for the 5A cable would be passed through the 3A cable, and the source would behave as though both cables are capable of 5A when they might not be. Extension cables also diminish the signal integrity due to the extra junctions between the plugs and sockets and the cable length. This means that the higher speed communications are more likely to be compromised. Providing two USB-C sockets on the Monitor (effectively turning it into a cable joiner) would be possible, but would result in much the same concerns. The specification also allows cables to omit some internal conductors, since the cable orientation sensing can deal with that scenario. Connecting two such cables with a joiner could result in some signals not being passed through at all. We performed several speed tests with different devices through our Power Monitor, comparing the performance between having the Monitor inline or not. We did not find a device for which it made a difference. It takes some powerful gear to run the high-speed (many GHz) tests needed to validate USB 3.2 communication, and we do not have access to such test equipment. However, by making the USB-C Power Monitor as short as practically possible, we minimise the possibility of introducing signal integrity problems. Still, we cannot guarantee they can’t happen. So, while the USB-C Power Monitor can’t comply with the USB-C specifications, we have worked hard and performed some thorough testing to ensure that it works with as many devices as possible. Circuit details The circuit shown in Fig.3 is split over two PCBs joined by a 7-pin header (CON4) at each end. The smaller PCB (inside the dashed box) has a USB-C plug (CON1) and a USB-C socket (CON2). All the Vbus and GND connections are joined at each end to simplify routing; this is actually required in the USB-C specification. Apart from a few, all the other lines are connected straight through, forming the forbidden USB-C extension Practical Electronics | August | 2026 Parts List – USB-C Power Monitor 1 double-sided green PCB coded 04102251, 78 × 11 × 0.8mm 1 double-sided black PCB coded 04102252, 80 × 40 × 0.8mm 1 flat flexible PCB (FFC) coded 04102253, 18 × 40mm OR 5cm of 7-way ribbon cable OR 30cm of light-duty flexible cable 1 Hammond 1551KBK 80 × 40 × 20mm enclosure 1 small lithium-ion rechargeable pouch cell with protection circuitry 1 Amphenol 12401981E412A straddle-mount 24-pin USB-C plug (CON1) [DigiKey, Mouser] 1 Würth 632723100011 24-pin SMT+through-hole USB-C socket (CON2) [DigiKey, Mouser] 1 5-pin header, 2.54mm pitch (CON3; optional, for ICSP) 1 USB-C SMD power-only socket (CON5) [GCT USB4135 or equivalent] 1 M2016/0806 size 4.7μH 1A inductor (L1) [Murata LQM2MPN4R7NG0L] 1 128×32 pixel 0.91-inch I2C OLED module (MOD1) 3 Adafruit 5410 reverse-mount SMD tactile switches (S1-S3) [DigiKey, Mouser] 1 tube of neutral-cure silicone sealant or similar flexible adhesive 1 piece of foam-cored double-sided tape (to secure BAT1) Würth 632723300011 is an alternative but it might be harder to solder 🔸 🔸 Semiconductors 1 PIC16F18146-I/SO 8-bit micro programmed with 0410225A.HEX, SOIC-20 (IC1) 1 INA296A3 or INA282 current monitor, SOIC-8 (IC2) 1 AD8541A or NCS325 rail-to-rail CMOS op amp, SOT-23-5 or SC-70-5 (IC3) 1 MCP73831T-2ACI/OT Li-ion charge regulator, SOT23-5 (IC4) 1 MCP16252T-I/CH boost regulator, SOT-23-6 (REG1) 1 3mm bi-colour red/green LED (LED1) 1 BAT54C common-cathode schottky diode, SOT-23 (D1) Capacitors (all SMD M2012/0805 size X7R ceramic) 5 10μF 16V 5 100nF 50V Resistors (all SMD M2012/0805 size ⅛W, 1% unless noted) 2 1MW 1 22kW 2 220W 1 390kW 3 10kW 1 100W 1 150kW 6 5.1kW 1 10W 1 120kW 2 1kW 1 15mW M6331/2512 size 3W Articles on USB technology If you wish to delve into the technical details of USB, the following Practical Electronics articles may be of interest: ● USB Power Injector for External Hard Drives by John Clarke (April 2010) ● USB Port Voltage Checker by Nicholas Vinen (August 2014) ● USB Power Monitor by Nicholas Vinen (August 2016) ● USB Port Protector by Nicholas Vinen (May 2019) ● USB Power Delivery Chargers by Jim Rowe (August 2022) ● USB-PD Triggers, Decoys and Testers by Jim Rowe (September 2022) ● USB Cable Tester by Tim Blythman (November & December 2022) ● USB-C Serial Adaptor by Tim Blythman (May 2025) lead. The V bus, CC1 and CC2 lines each have a resistor between CON1 and CON2. The 15mW shunt resistor in series with Vbus is for measuring the current flow. The resistors inline with CC1 and CC2 allow us to determine the source and sink nature of whatever is con- nected to CON1 and CON2. The extra resistance is about the smallest we could use to reliably detect that difference, while being low enough to not affect the CC detection thresholds according to the specifications. Typical currents in the CC lines are in the hundreds of microamps (from 13 Constructional Project source current Ip to sink resistor Rd), so the drop across the 220W resistors is in the tens of millivolts. This is the precision of the voltage thresholds in the specifications. When a CC line is allocated to a V conn role, it can supply 5V power at up to 200mA to electronics in an e-marked cable. Clearly, 220W is too high to allow 200mA to be passed successfully, although our testing didn’t find any cables that had problems with this. A typical e-marked cable will try to source Vconn from both ends of the cable using diodes or similar to prevent Vconn being carried through the cable. So if you run into problems, try reversing the Monitor; that should allow Vconn to be sourced from the other end. CON4 breaks out the important signals back to the main PCB for monitoring. There is a ground connection, and two wires for Vbus, CC1 and CC2, fed from each side of their respective resistors. CON4’s connections are arranged symmetrically so that the entire PCB can be rotated 180°. This means that if you prefer the USB-C plug on the left and the USB-C socket on the right, you can wire the boards in this fashion during the construction phase. Main circuit A microcontroller is required to make measurements and drive the display to report them. We’re using an 8-bit PIC16F18146 (IC1), since it has some useful internal peripherals, including a 4.096V reference, an 8-bit buffered digital-to-analog converter (DAC) and a 12-bit analog-to-digital converter (ADC). IC1 has the usual 100nF bypass capacitor on its power and ground pins (1 and 20 respectively). A 10kW resistor pulls up the MCLR pin (pin 4) to allow normal operation, unless a programmer is connected at ICSP header CON3. Pins 1, 4, 18, 19 and 20 are taken to CON3 for programming and debugging. Pins 11, 12 and 13 connect to tactile switches S1, S2 and S3. They are configured with internal pullups, and the micro detects the pin level changing to low when the switch is pressed, closing the circuit to ground. A pin-change interrupt allows the micro to be woken up from deep sleep by pressing any of the switches. 14 These 8-bit PICs have a good output pin drive strength and so can directly power other circuit elements, allowing them to be switched off when the Monitor needs to be in low-power sleep mode. Pin 16 powers OLED module MOD1, a 128×32 pixel monochrome display, so it can show a few lines of text or similar. IC1’s pins 14 and 15 provide a bit-banged I 2C serial interface to control the OLED. IC1’s pin 2 is used to provide power to IC2 and IC3, as well as to control the ENABLE pin on REG1. With both pin 2 and pin 16 low and the microcontroller in low-power sleep, only IC1 and REG1 draw power from BAT1. The nominal 5V rail falls slightly below the cell voltage (because of the diode and resistor). The greatest current draw is the 6μA flowing through REG1’s feedback divider, with IC1 and REG1 drawing less than 1μA each, for a total under 8μA. Analog circuitry IC2 is a current shunt monitor that amplifies the voltage across the 15mW current measuring shunt connected via CON4. It has a gain of 50, so its output voltage is 0.75V for every amp through the shunt. IC2 is equipped with two reference inputs (REF1 and REF2); the output voltage is offset against the average of the voltage at these two pins. The twopin reference feature makes it easy to set up a mid-rail reference for bidirectional current sensing, although we don’t use that here. Instead, we feed both reference pins with a voltage supplied from pin 17 of IC1. This is derived from an 8-bit DAC connected to a 4.096V internal reference. By setting the DAC, we can change the IC2 reference to be anywhere between 0V and 4.096V. This allows us to nearly double the span available for readings. For currents in one direction, we set the reference to near (but not quite) 0V and we have almost 4V of range, allowing up to 5A to be measured. If the current reverses direction, the reference is taken near 4V, allowing similar magnitudes to be measured in the opposite direction. IC3 is a single op amp configured to amplify the output from IC2 (relative to the same reference) by a factor of 100. The 100nF capacitor across the feedback resistor provides low-pass filtering of the amplified signal. IC1’s Fig.3: the circuit is split into two sections connected by CON4s; one section has a USB-C plug (CON1) and a USB receptacle (CON2), wired straight through apart from some resistors. The other section has microcontroller IC1, which measure voltages, currents and so forth and displays them on the OLED module. pin 9 is used for ADC readings of the low range (amplified) voltages from IC3, while pin 3 samples the higher range voltages directly from IC2. The ADC peripheral can perform differential readings, so the reference is simply used as the second channel for these readings. This scheme gives us more dynamic range to accurately read currents in both directions over the two ranges. The 150kW/10kW divider connected to one of the Vcc pins of CON4 is used for measuring the Vbus voltage. The 100nF capacitor on its lower leg provides a lower source impedance to charge up pin 10’s ADC sampling capacitor. With a 4.096V reference, the divider allows up to 65V to be measured, comfortably above the 48V currently allowed by the USB-C specification. Practical Electronics | August | 2026 USB-C Power Monitor, part one CC sensing The remaining resistors are used to drive and sample the two CC lines. Normally, pins 5, 6, 7 and 8 are set as analog inputs to monitor the state of the CC lines. The series 5.1kW resistors do not noticeably affect the sensed voltage when these pins are inputs. The state of the pins can determine what current the source can provide. By monitoring for the slight voltage difference across the 220W resistors, it can also determine which end is the source and which end is the sink. The 5.1kW resistors also allow the USB-C Power Monitor to behave as a power sink by driving one or more of these pins to a low logic level (0V). This allows you to check the capabilities of a source, even if a sink is not connected. It is only a very limited use of the CC signalling. But USB-C now allows Practical Electronics | August | 2026 scenarios which seem improbable; for example, a mobile phone attempting to charge a laptop computer. So we think the ability to identify such situations could be helpful. Power supply One interesting problem is that we realised a USB-C cable does not always provide power, even if it is connected to a suitable source such as a computer or power supply. Thus, we needed a way to power the USB-C Power Monitor independently. We chose to use a lithium-ion rechargeable battery (BAT1). This has the advantage that the power supply is decoupled from the USB-C circuitry, and the USB-C Power Monitor does not load the circuit under test, apart from a voltage divider totalling 160kW, which draws about 31μA at 5V. We used similar circuitry to our other recent projects that include a Li-ion cell. The most recent was the Compact OLED Clock and Timer, in the July 2025 issue. In this case, 5V power for charging comes in via CON5, a power-­only USB-C socket with the 5.1kW resistors necessary to identify it as a power sink. The MCP73831 charger, IC4, has a 10μF smoothing capacitor on its input pin and another on its output to the battery. The MCP73831 monitors the charging current and voltage of BAT1 and provides a multi-stage charging regime. It has a status output and the charging current can be programmed. All in a tiny 5-pin SOT-23 package! The charge current is set to 45mA by the 22kW resistor connected to IC4’s pin 5 (PROG). The STAT pin drives one side of bicolour LED1; it is low during charging and is high when it finishes. 15 Constructional Project The Breakout PCB is used to provide the USB connections and will be described in more detail in next month’s issue. The arrangement of 1kW resistors allows the LED to light up red during charging and green when charging is complete. Dual diode D1 is a common-­cathode schottky type. Power from the battery and CON5 are connected to its anodes, so there is no load on the battery when power is available at CON5. The remainder of the circuitry is powered from D1’s cathode, and because there is no draw on the battery while charging, IC4 can charge it fully. This arrangement also means that the USB-C Power Monitor can be powered directly from CON5 even if a battery is not fitted. The cathode of D1 is connected to MCP16252 boost regulator REG1, which also has 10μF bypass capacitors at its input (pin 6) and output (pin 5). This part has an ENABLE input at its pin 3. When this pin is low, the REG1’s input is connected directly to its output, providing a low-quiescent-­current mode with no voltage boost. When ENABLE is taken high, the boost regulator operates. It has internal N-channel and P-channel Mosfets. The SW pin (pin 1) is pulled low by the N-channel Mosfet, drawing current through inductor L1. When this Mosfet switches off, the P-channel Mosfet switches on, dumping current from the inductor into the output and boosting the voltage. Using a Mosfet as an active switch is more efficient than using a diode, since there is negligible voltage drop across the switch when it is on. The 390kW/120kW divider at the output provides feedback for the regulator and sets the output to a nominal 5.2V. After the 10μF capacitor on REG1’s output is a 10W resistor and a further 10μF capacitor to provide a degree of filtering for the rest of the circuit. At the circuit’s nominal 20mA draw, the 10W resistor drops about 0.2V, leaving close to 5V. Software As we noted, the PIC16F18146 has a handy set of peripherals, so we’ll describe those next, along with some aspects of the software operation. The capabilities of the ADC are critical to this project. The PIC provides an internal reference that can be set to a nominal 1.024V, 2.048V or 4.096V, and can be used to set the ADC scale. The 4.096V reference is used for most of the analog readings and its measured value (in millivolts) is stored in non-volatile memory at the time of manufacture. Being able to use the 4.096V range is the main reason for the boost converter (REG1). The 4.096V reference will not be functional if the supply is only 3.7V, as might be the case for a Li-ion cell that is nearly flat without this boosting. The analog peripheral is actually described as an ‘Analog-to-Digital Converter with Computation’ (ADCC) module. It can produce a 12-bit result and can also accumulate multiple results. The accumulator has 18 bits, so the software configures it to accumulate 64 12-bit results, giving a notional 18-bit result. Since the total ADCC error is around two bits, the lower two bits are discarded, and the software works with convenient 16-bit numbers. It takes about two milliseconds to perform the 64 samples, so the processor sets it running and uses an interrupt routine to store the readings, then commence the next sample while it continues with other tasks. A set of 13 samples is taken in roundrobin fashion; the two current readings are taken in differential mode using the pin 17 VREF voltage as the second channel. The voltages across the 220W resistors in the CC lines are also measured in differential mode; this allows us to note the sign and determine the direction that the current is flowing in those lines. All these differential readings are also validated by taking corresponding single-ended (absolute) readings. For example, this allows us to detect when the low-range current reading approaches the rails, an indication that we should shift the reference (by setting the DAC) to allow more headroom or use the high-current range instead. A second 8-bit DAC is internally connected to IC1’s supply. The DAC is set to code 32, or 1/8 of the supply. The ADCC sample of this channel uses the 1.024V reference, meaning that we can accurately check that the supply voltage is high enough for the 4.096V reference to work and that the other readings are correct. A timer peripheral is also used to provide an internal clock. This is set to count at an integer fraction of a second and make the calculations easy (for an 8-bit processor) without using computationally complex floating-point values. The time each sample set takes to complete is also recorded. This is necessary because the most accurate ADCC results can be achieved when the ADCC is run from its own internal oscillator and completely decoupled from the micro’s other internal clocks. The “>” button cycles through various screens, while the up/down buttons are used to adjust values and modes. 16 Practical Electronics | August | 2026 USB-C Power Monitor, part one Screen 1: the main screen reports the Vbus voltage and current (including direction). Power and accumulated energy are also calculated; a timer is available too. Another screen can be used to monitor and test the condition of the configuration channel lines. The appropriate scaling factors are applied to provide the numerical values that are needed. Derived values like power (current multiplied by voltage) and energy (power multiplied by time) are also calculated. This part of the software also sets flags indicating which of the low or high current ranges is valid and should be used. These measurements continue to run any time the micro is active and not sleeping; the results are displayed according to the screen that the user has selected. The main screen, for example, reports the same basic statistics as the older Monitor: voltage, current (now including direction), power and total energy. The energy totaliser is paired with a timer; both can be started, paused and reset together. The totaliser also runs in the background if other screens are selected, providing seamless operation. Another screen allows monitoring and control of the CC lines, while a third can be used to put the Monitor into lowpower sleep mode or check the battery voltage. You can also access the configuration screens by a long press of S3. Most of the configuration is involved with trimming the calibration factors to suit the components used in a specific build, although there are also the options to adjust the screen brightness and choose between watt-hours (Wh) or Joules (J) for the units displayed for energy. We’ll look more at the user interface later. Hardware The two PCBs fit into a compact 80 × 40 × 20mm enclosure; we used a Hammond 1551KBK, which is available from Farnell (3536439). One PCB replaces the lid, so the final unit is only 18mm high, but is slightly longer than 80mm because of the plug protruding at one end. Both PCBs require reasonably good soldering skills to build. Fully featured USB-C plugs and sockets are only available with very tight pin spacings of around 0.5mm. When the Breakout PCB is completed, it can be tested in isolation by using it as an extension for a USB-C cable. Thus, it is possible to detect problems early in the process. Practical Electronics | August | 2026 The PCB hosting CON1 and CON2 must be 0.8mm thick because the plug (CON1) is a so-called ‘straddle-mount’ that clips over the edge of the PCB. It sounds fussy, but the mounting style allows the part to be precisely placed before soldering begins, and we actually found it easier to work with than the socket (CON2). The upper PCB is populated with M2012 (imperial 0805) sized passives, which are 2mm long. This is about the minimum size we consider easy to handle. There are a couple of SOIC chips and a few SOT-23 variants with three, five and six pins. Since the top PCB is also the lid, there are a couple of unusual constructions steps. If you have built the likes of the Compact Clock and Timer (or read its article), these will be familiar. The two PCBs must be joined with wires. Our early prototypes used pluggable headers, but we found that these had enough variation in resistance to interfere with the performance of the currentmeasuring shunt. We designed a flat flexible cable (FFC) that can be soldered to the PCBs to give a simple and elegant connection. You can also use hookup wire for this, or a section of 7-way ribbon cable, if you find the FFC is too expensive or difficult to source (we’ll supply the FFC with our kits – see the panel). We had originally planned to use a 10440-sized lithiumion cell as the battery. These are the same physical size as a AAA cell, and there is just enough room to fit a AAA cell holder to allow simple and safe connection of the cell. However, we think that our final design, using a small, rectangular pouch cell like Altronics’ Cat S4723, works better. The slim shape is a better fit for the available space, and the nominal 400mAh capacity is higher than we have seen in 10440 lithium cells. This cell measures 38 × 25 × 6mm and includes protection circuitry. Many small pouch cells are available from various online sellers. So you might find an alternative with slightly different dimensions that still fits. Until next month This is a very detailed project, and we have run out of room to describe it in this issue. The second part next month will include the construction, setup, calibration and use of the USB-C PE Power Monitor. 17