DIY 24V Power Supply with Solid‑State Relays – A Step‑by‑Step Build

If you’ve ever tried to run a motor, a sensor array, or a small PLC off a cheap wall wart, you know the frustration of voltage drops, noisy spikes, and a fuse that blows every other week. A clean 24 V source is the backbone of most hobby‑level automation projects, and using a solid‑state relay (SSR) to control that supply gives you silent switching, no wear‑out contacts, and a tidy footprint on a breadboard or panel. In this post I’ll walk you through the whole build – from picking parts to getting the first LED to glow – so you can add a reliable 24 V rail to any project without a trip to the hardware store.

Why a 24 V supply matters for makers

Most off‑the‑shelf modules – motor drivers, industrial I/O cards, and even some Arduino shields – expect a stable 24 V input. That voltage is high enough to drive small DC motors and solenoids, yet low enough to stay safe for handheld work. Using a linear regulator or a cheap switching brick often leaves you with a lot of ripple (the little hum you hear on a multimeter). Ripple can make a sensor misread or a motor jitter, which in turn makes debugging a nightmare. By building your own supply you control the quality of the output, the protection features, and you get a chance to learn how the pieces fit together.

Choosing the right solid‑state relay

An SSR is basically a tiny electronic switch that uses a light‑activated transistor or triac inside. For a 24 V, up‑to‑5 A load, a good choice is a MOSFET‑based SSR with a control voltage of 3‑32 V DC. Look for these specs:

  • On‑state resistance (Rds(on)) – lower is better, it means less heat.
  • Isolation voltage – at least 250 V to keep the control side safe.
  • Turn‑on/turn‑off time – a few milliseconds is fine for most hobby projects.

I like the “Omron G3MB‑202P” because it’s cheap, has a built‑in zero‑cross detection (so it switches at the nearest AC zero crossing, reducing EMI), and it fits nicely on a perf board.

Parts list

QtyPartWhy we need it
124 V AC transformer (12 V × 2)Gives us the raw voltage to rectify
1Bridge rectifier (KBPC5010)Turns AC into DC
1100 µF electrolytic capacitor (35 V)Smooths the rectified voltage
1LM2596 buck regulator moduleSteps down to stable 24 V
1Omron G3MB‑202P SSRSilent switching of the 24 V rail
11 kΩ resistorPull‑down for the SSR control pin
110 kΩ potentiometer (optional)Fine‑tune output voltage
1Heat‑shrink tubing, wire, terminal blocksFor safe connections
1Small project enclosureKeeps everything tidy

All of these parts are available on common sites like Digi‑Key, Mouser, or even eBay. The total cost stays under $30, which is a bargain compared to a pre‑built industrial supply.

Circuit diagram and layout

The basic flow is:

  1. AC transformerbridge rectifierfilter capacitorbuck regulatorSSRload.

The SSR sits on the high‑side of the 24 V rail, so when its control pin receives a 5 V logic signal from an Arduino or a Raspberry Pi, the relay closes and powers the load. The control side of the SSR is isolated, so you can drive it directly from a microcontroller pin without worrying about the high current on the output side.

When you lay out the board, keep the high‑current traces wide (at least 1 mm) and separate the low‑voltage control wiring from the 24 V lines. A simple two‑layer perf board works fine; just route the ground plane under the buck regulator to help with heat dissipation.

Building the supply

1. Assemble the rectifier stage

Solder the four leads of the bridge rectifier to the transformer’s secondary wires. The “+” and “–” markings on the rectifier tell you where the DC comes out. Connect a short piece of 22 AWG wire from the “+” terminal to the input of the buck regulator, and another from the “–” to the regulator’s ground.

2. Add the filter capacitor

Plug the 100 µF electrolytic capacitor across the rectifier’s DC output, respecting polarity (the longer lead is positive). This capacitor smooths the pulsating DC into a steadier voltage, which makes the buck regulator’s job easier.

3. Set up the buck regulator

The LM2596 module has three pins: VIN, GND, and VOUT. Feed VIN and GND from the rectifier stage. Before you connect the load, power the module and use a multimeter to adjust the tiny potentiometer on the module until you read exactly 24.0 V on VOUT. If you want a little wiggle room for different loads, you can add a 10 kΩ pot in series with the VOUT sense line for fine‑tuning.

4. Wire the SSR

Place the SSR on the board so that its load terminals (normally labeled “L” and “N”) sit on the high‑side of the 24 V rail. Connect the “L” terminal to the VOUT of the buck regulator, and the “N” terminal to the load’s positive input. The load’s negative side goes back to the regulator’s ground.

On the control side, connect the SSR’s “+” pin to a digital output pin on your microcontroller through a 1 kΩ resistor. The resistor limits any stray current when the pin is low. Tie the SSR’s “–” pin to the microcontroller’s ground. Add a 1 kΩ pull‑down resistor from the “+” pin to ground so the SSR stays off when the MCU is not driving it.

5. Enclose and label

Slide the assembled board into the project enclosure, secure the transformer and heat‑sink the buck regulator if it gets warm. Label the input (AC), the 24 V output, and the control pins – this saves a lot of head‑scratching later.

Testing and troubleshooting

  1. Power‑up without load – Turn the AC transformer on and measure the voltage at the buck regulator’s output. You should see a steady 24 V. If it’s low, check the filter capacitor polarity or the transformer’s rating.

  2. Check SSR control – With the microcontroller pin set to HIGH, the SSR should click (you’ll hear a faint “click” even though it’s solid‑state) and the load voltage should appear at the load terminals. Use a multimeter to confirm continuity.

  3. Load test – Connect a small DC motor or a bank of LEDs as a dummy load. Observe the voltage drop; it should stay within a few hundred millivolts of 24 V. If it dips a lot, you may be exceeding the buck regulator’s current rating or the SSR’s 5 A limit.

  4. Heat check – After a few minutes of continuous operation, feel the buck regulator and SSR. If they’re hot to the touch, add a small heatsink or improve airflow inside the enclosure.

  5. Noise check – If you hear buzzing from the transformer, try tightening the mounting screws or adding a rubber washer. A loose transformer can introduce hum into the DC rail.

Once everything checks out, you have a clean, silent 24 V rail that you can turn on and off with a single line of code. I’ve used this exact setup to drive a small conveyor belt, power a set of pneumatic valves, and even run a compact laser cutter controller. The best part is that you built it yourself, so you know exactly where the weak points are and can fix them without waiting for a tech support ticket.

A quick tip from my workshop

When I first tried this design I forgot to add the pull‑down resistor on the SSR control side. The result? The relay would sometimes stay on after the MCU rebooted, because the control pin floated at an undefined voltage. Adding that 1 kΩ resistor solved the mystery in minutes and saved my first prototype from a burnt motor. Small details like that are what separate a “works most of the time” circuit from a truly reliable one.

Enjoy the build, and happy tinkering!

Reactions