Step 10Wire stoplight to relay circuit
The 22 gauge wire (or the fat traces on the printed board) are the biggest potential risk of over-heating, so it's important to limit the amount of amperage they will ever be asked to carry. To be extra safe, I added a 5 amp fuse to the circuit, which is several amps under the recommended max for 22 gauge wire.
In the case of the light I used, all the lamps were already wired to a block in the housing for the yellow lamp, so I just had to run wires from the control circuit to the corresponding posts on the block. If it had not been there I would have just connected each wire via twist on connectors.
Each of the lamps swing up on hinges revealing space where wiring and other stuff can be tucked away.
DO NOT HAVE THE CORD PLUGGED IN DURING THESE STEPS!
Prepare the ac power cord:
- Create the power cord: If you do not have a power cord with bare wires already broken out, cut the female end off of a PC power cable. Strip the insulation off several inches of the bundle, and half an inch off of each of the three cables.
- Determine which wire is the ground: Use a multimeter set in continuity mode to test which wire goes to the ground pin (the longer one) and make a note of it.
- Determine which slot of the outlet will be live: The standard is that the thin slot is live and the wider one neutral, but testing it out myself gives me a greater peace of mind when wiring potentially lethal power. After setting your multimeter to AC, put one lead in the ground hole and use the other to test the two slots in turn. Whichever slot is live (should be the thin one, or your outlet is wired wrong) will send 120volts into ground when you connect them. The other one should read zero or just a few volts.
- Determine which wire is live: Now that you are SURE which slot is live, put the multimeter back in continuity mode and use it to determine which wire corresponds with the the live blade on the plug. Make a note of this wire as the "hot" one. The final wire is "neutral".
- Connect the "live" wire to the 5 amp fuse. If you reverse it and use the neutral wire, the lamp will work but it will be a trap, waiting to shock or electrocute the first person to change a bulb. So don't do it.
- Run a wire from the other pole of the fuse to the "Power AC" screw on the terminal block on the control circuit. This will be the one that connects to all four relays, the one separated from the others by one or more unused screws if you followed the printed guide.
- Run a wire from each of the terminal block screws to the corresponding lamp or outlet. If you are wiring up the optional outlet, connect to the "live" terminal on the outlet*.
- Connect each of the remaining lamp wires (and the neutral wire of the optional outlet if used)* to the neutral wire of the power cord. In the case of the light I used, all the neutral wires were already connected together, so I only had to connect one.
- Connect the ground wire to any ground wire provided by the light.
Test and power on:
- Test all your connections with the multimeter to make sure there are no shorts. With nothing plugged in, there should be NO continuity between the fuse and any of the lamp or outlet wires.
- Plug in power and ethernet to the arduino, but DO NOT PLUG IN THE LIGHT. With the multimeter you should be able to get continuity between the fuse and the neutral wires of each lamp only when that lamp is turned on via the web page. Similarly, you should get continuity between the blades of the plug when any of the lamps are on, but not when they are all off.
- Stand back and plug in the light. You now should be able to turn each lamp on and off via the web page.
Congratulations, you now have a stoplight web server!
| « Previous Step | Download PDFView All Steps | Next Step » |
![]() |
Add Comment
|



























































