A Simple Way to Add a Solid State Relay to Your Project

by NotLikeALeafOnTheWind in Circuits > Arduino

2543 Views, 2 Favorites, 0 Comments

A Simple Way to Add a Solid State Relay to Your Project

061D76DD-7EFF-4742-B8A4-4442D20A0033_DxO.jpg
321D54C5-439F-4C45-ADE4-DE2108B85E3D_DxO.jpg
C49B0882-2C6D-4120-9C6C-7108E9C2BF0F_DxO.jpg

Want to add an electrically controlled switched outlet to your project? A Solid State Relay (SSR) is a great way to add one. A typically available SSR has a switching voltage between 3Vdc to ~30Vdc. This project uses a SSR that uses DC voltages to control an AC switch. It is important to select the correct type of SSR for this project.

This instructable is targeted at switching 120VAC. It is intended to control two outlets. It is using main voltages and is therefore dangerous. This project should not be undertaken unless you have a thorough understanding of what you are doing.

In my case, I'm using it to control a small fan for an element of our Halloween decorations

Supplies

Before We Start

857965F1-D6A6-4D34-827E-377A94CC0365_DxO.jpg

Some thing to keep in mind:

The National Electric Codes (for the US) use the following color system for single phase 120VAC:

BLACK = Hot ( or L for Line)

WHITE = Neutral “N”

GREEN = Ground Conductor (Protective Ground) “PG“

(I did mention that this project could be dangerous, if you don't know what this stuff means, please find someone that knows wiring to assist you.)

Because the wire in the cord is stranded, I put a drop of solder on the end of each wire. This was done only to hold the strands together when inserting them into the screw terminals or the crimp connectors. Otherwise they could fray and that could be an annoyance.

The socket and the SSR/heatsink are both mounted to a small pice of DIN rail. In my case, the final project was going to be mounted on an existing DIN rail. If you are attempting this project use the DIN Rail, It will keep the project neat and provide a way to mount the heatsink for the SSR.

The SSR must be mounted on a heat sink.

The SSR is rated at 60A. The power cord is rated at 15A. I would not attempt to run anything over 12A.

Lastly, yes, I did mount the SSR upside down. It made the wire runs shorter and it is more convenient for me.

Wire It Up

54370A97-1617-4255-9BF6-37A7F464503C_DxO.jpg

Wiring is simple. Everything uses screw terminals or crimp connectors.

On the AC side:

  1. From the power cord, attach the white wire to the "N" terminal on the outlet block.
  2. From the power cord, attach the green wire to the "G" terminal on the outlet block. Some of the newer blocks have replaced the letter "G" with a graphic for ground.
  3. From the power cord, attach the black wire to the input terminal on the AC side of the SSR. In my case it was labeled terminal 1. (I had to extend the wire from the power cable. I did this using a "Butt" crimp connector and small piece of wire that was appropriately gauged.) The wire attachment to the SSR was done using a "fork" crimp terminal.
  4. From terminal 2 on the SSR, attach a wire to the the "L" terminal on the outlet block. The L terminal is a screw terminal, and the terminal 2 attachment was with a "fork" crimp terminal.

On the DC side:

  1. Attach a red wire to the "+" terminal. ( Terminal 3 in our case.)
  2. Attach a black wire to the "-" terminal. (Terminal 4 in our case.)

In our final installation the wires were both connected with fork crimp terminals. For test, we just used small jumper wires.

Test It Out.

FE58A6E1-9359-4F23-A3C5-7FB0C5B23A0B_DxO.jpg

Testing is simple.

Do not plug in the power cord or have anything plugged into the outlets. Attach a power source to the red and black wires. Turn it on. The LED on the SSR should come on.

Quick note, The power source must be DC and between 3VDC to 60VDC. You can use a couple of batteries, a convenient Arduino or Raspberry PI or a bench supply. As long as it is DC and in the range, it will work.

Next, plug in the power cord to an outlet and repeat the test.

Lastly, plug a small lamp or some other device into one of the sockets and try the test again. The device should come on when you apply DC power.

You can now attach the black wire to ground on your project and the red wire to whatever GPIO pin you are using for control. Rasing the GPIO pin will now turn on the outlets (as long as the pin is raised above 3VDC).