Smallest USB-C PD Controller Using CH224K
For more info: https://www.hackster.io/sainisagar7294/smallest-usb-c-pd-controller-using-ch224k-135ff8
The smallest USB-C PD controller board
Most of the time I am away from my loved stuff, my LAB! I can not carry the big bulky adapter with me having different voltages and all, that’s why I purchased a 65W one, which has USB-C. My adapter supports a lot of changing protocols and one of them is USB-C Power Delivery (PD). My idea is to make a simple PD interfacing device as small as possible so that it can be inserted into small housings.
![]()
The CH224K
The CH224K is a USB-C PD fast-charging protocol receiver chip. It is designed to request higher voltages from a PD adapter without using a microcontroller. It supports USB PD 3.0 (up to 100W) and 5V / 9V / 12V / 15V / 20V with a simple resistor configuration, a built-in internal regulator and protection features. The CH224K handles the entire PD handshake, allowing the board to behave like a smart power jack. Just plug in a USB-C PD adapter, and the required voltage appears at the output.
The final PCB is extremely small

For a minimal design, voltage is fixed at PCB level, so no frequent switching is required. The configuration resistors are put on the bottom layer so they are easily accessible and we can change the voltage. There are no high-frequency components, making the design electrically quiet and easy to debug. The final PCB is extremely small, making it suitable for embedded use inside enclosures where traditional adapters simply don’t fit.
Testing with a 12V source
I set the configuration CFG3 to 1, shorted the back pad, plugged the USB-C into my power bank that supports the same voltage, and measured the voltage, it's 12V, pretty accurate. By plugging in a 65W adapter we are able to sweep the voltage 0–20V and then current 0–3A.

USB-C PD is no longer just for phones and laptops. With chips like CH224K, designers can finally tap into that ecosystem without complexity. My aim is to reduce the enclosure size and eliminate bulky adapters.
#usb power delivery#
Operational Amplifier as DC Amplifier
For more info: https://www.hackster.io/electroboy001/operational-amplifier-as-dc-amplifier-1041a3
Adjustable op-amp DC amplifier board
![]()
Operational amplifiers are awesome, they are used to design a lot of circuits. In a previous part we discussed the open-loop gain / comparator feature of an op-amp, and now we will see the use of an operational amplifier to amplify a very small signal with adjustable gain. In the end we will make a DC amplifier which can be tuned easily through the onboard potentiometers.
Op-amp configurations and gain
There are two types of configurations (inverting and non-inverting) while using the op-amp in closed loop. Both configurations use negative feedback because it helps to minimize the error/noise and increase the overall stability. In the non-inverting configuration the signal is given on the non-inverting terminal and the gain is 1+Rf/Rin. In the inverting configuration the signal is applied on the inverting input, so the output is 180 degrees out of phase and the gain is −Rf/Rin.

In closed loop the op-amp tries to minimize the error of the applied input signal, the virtual ground concept. If the inverting terminal is held at ground potential, then the non-inverting terminal is also assumed at ground.
A basic DC amplifier working concept
Let's take an example where we have a signal of 10mA and we want to amplify it to 1 volt, so a gain factor of 100 is required.
Step 1: choose the configuration, here I am choosing non-inverting, which gives 1+Rf/Rin.
Step 2: choose Rf and Rin assume Rin = 1k, so we require Rf = 99k for a gain of 100.
Step 3: because the op-amp tries to minimize the difference between both input terminals, we give a reference from the non-inverting terminal to ground. This sets a reference line and the input is amplified by the same factor.
Adjustable amplifier with selectable gains

I made this DC gain amplifier which can be adjusted according to the input applied, and here you will find 3 different modes which set the gain 10x, 50x and 100x, so it is easy to amplify and test any DC signal out from any device. Gain can be selected by switching the jumper to a different position on the PCB.
#dc amplifier using opamp#
DIY Solid State Relay Module
For more info: https://www.hackster.io/electroboy001/diy-solid-state-relay-module-e170f3
DIY solid-state relay (SSR) module
Relays are the most useful and stable AC power switching components. The regular size of relays is big because of a mechanical moving actuator and a coil. The main problem is that it takes a lot of current and, due to the mechanical action of actuators, there are sparks between both terminals. Which may cause serious problems like tear down, terminal welding and damaging. But there is one solution to all of these problems known as SSR (solid state relays). They are electronic based switches which can be used for fast switching of AC appliances. These electronic AC switches are known as TRIAC.
![]()
TRIAC vs SCR
A TRIAC is a three-terminal electronic component that conducts current in either direction when triggered. TRIACs differ from SCRs in that they allow current flow in both directions, whereas an SCR can only conduct current in a single direction. The bidirectionality of TRIACs makes them convenient switches for alternating current. Here we use a dedicated TRIAC driver, which helps in switching the TRIAC by AC cycle feedback either zero-voltage switching or random phase shift.
Circuit diagram with the MOC3021 TRIAC driver

Components: BT136 (SMT package), MOC3021 (TRIAC driver), 10k and 1k resistors, pin headers and screw terminals, and PCB prototypes from JLCPCB. The circuit has a DIAC based optocoupler known as the TRIAC driver, which has an LED and DIAC inside and is triggered with the help of DC voltage to the LED terminal. This provides full insulation of the supply to the mains voltage.
SMT-assembled PCB:

I used SMT assembly service from JLCPCB, because I want to make the PCB clean and small. It is made for smaller loads under 50 watts per channel only, because I am not using any heatsink. I made the PCB according to the channel selection; the front header can be directly used with the microcontroller. A total of 4 channels are there which can be used separately with different GPIO pins.
Working SSR connected to an AC load:

This solid-state relay works in the same manner as mechanical sugar-cube relays, but this time we have only two terminals. When there is no trigger on the Gate pin, the TRIAC output resistance is in Mega-ohms, which switches off the appliances connected to it. This module works fine on +5 volts and consumes just 10mA of current, which is way lesser than old mechanical relays.
#solid state relay module#
1.5V Alkaline Battery SOC Measurement Technique:
For more info: https://www.hackster.io/sainisagar7294/1-5v-alkaline-battery-soc-measurement-technique-972b51
1.5V alkaline battery SoC measurement setup:
There are a lot of fuel gauges and battery chargers available for 3.7V lithium batteries, but when it comes to lower 1.5–1.2V batteries, there are very limited circuits and dedicated ICs. I want to estimate the battery life, but how is it possible with these non-rechargeable batteries? Unlike Li-ion batteries, alkaline batteries have a pretty flat voltage curve that depends on the load. The best possible and simplest one is estimation through voltage, but in combination with a load.
![]()
The two-step SoC approach:
● Voltage-based SoC (for long-term reference)
● ΔI (current difference) under two loads (for accuracy)
This approach is very low-cost and easy to implement, and suitable for all kinds of 1.5V alkaline batteries. But the cell-to-cell chemistry is not in our hands, so there may be an accuracy of 90–92% only. With only voltage measurement, we can reach an accuracy of ±70–80%, so we need more information than voltage alone. Instead of directly computing internal resistance, we observe how current collapses under different loads. I use two known load resistors, 22 Ω and 9.7 Ω; the values are not random at full swing they produce ΔI greater than 80 mA for better resolution. Fresh battery has high current difference; in weak battery currents converge then ΔI collapses.
Circuit diagram just 4 components

Components: a P-channel MOSFET, Arduino Nano, 2× 1.5V battery (one discharged to 50%), 9.7 Ω and 22 Ω resistors, and a power source. Just with 4 components you can build this circuit, and all the computations are done with the MCU. First the open-circuit voltage is measured by the Arduino's 10-bit ADC, then the 22 Ω load is turned on briefly, then the 9.7 Ω load; after that the computation is done on ΔI, and SoC is estimated.
Results
Test 1: discharged battery

Test 2: fully charged one

This project shows that you don’t need a fuel-gauge IC to estimate alkaline battery SoC accurately. By combining intelligent load switching, current measurement, and a little empirical modeling, we can build a low-cost alkaline battery SOC measurement tool. Still, if you need a proper SoC with 95–99% accuracy, then go for a fuel-gauge IC solution.
#alkaline battery SOC#