I am working on a traffic light control project using MSP430 Launchpad as the microcontroller. I’m working on prototyping the system using the MCU (3.3V), 5v relays, and 120V lights. For now, they are powered by various sources like wall warts and USB connection to the computer. Once I get this working, I’d like to move the system into a package which can be powered entirely with 120V wall power running to the traffic light unit (to be clear, this is a decorative traffic light and an excuse to learn basic electronics). What’s the typical approach to handling multiple power conversions in one project (3.3 V for the Launchpad, 5V for th relays, and 120 V to the lights) that can all be sourced from 120V wall power and contained in one package?
- Buy a 3.3v/5V power supply. Check Digikey and Mouser. 2) Another problem you have is how you are going to drive the relays. Most of the MSP430’s output pins can only handle a max of 6mA @ 3.3volts. A few pins can handle up to 20mA @ 3.3volts. The MSP can only drive a total of 100mA from its output pins. It can not drive 5 volt loads. So you will need FET driver transistors to drive the relays coils.
Hi, thanks for the reply. I’m definitely working the relay control end of things. My plan is to use a 5v power supply into a ULN2803 chip. My specific question for now is about best-practices for splitting power to be regulated to different levels. I’ll have 120V bare wire as input–at that point, what’s the safest and smartest way to route that power into 1) the lights, 2) the 5v power suppler for the relay, and 3) the 3.3 v supply to the MSP430. I assume there’s a better approach than dis-assembling wall warts and using lots of electrical tape! Thanks!
No offense, but based on the level of understanding I can assume you have, based on the questions you are asking and how you are asking them, you should definitely NOT be using any 120V bare wires, nor should you be disassembling wall warts. Stick to products like [https://www.sparkfun.com/products/10747](https://www.sparkfun.com/products/10747) for switching high voltages, and leave your wall warts assembled. Safety should be a primary concern in any project, and products like the Power Switch Tail were created to provide a convenient way to maintain safety.Scount:
Hi, thanks for the reply. I’m definitely working the relay control end of things. My plan is to use a 5v power supply into a ULN2803 chip. My specific question for now is about best-practices for splitting power to be regulated to different levels. I’ll have 120V bare wire as input–at that point, what’s the safest and smartest way to route that power into 1) the lights, 2) the 5v power suppler for the relay, and 3) the 3.3 v supply to the MSP430. I assume there’s a better approach than dis-assembling wall warts and using lots of electrical tape! Thanks!
You would be better off to keep the high voltages separate from the low voltages. Use a 5 volt wall wart to power the relays, and step that down to 3.3 volts with a DC/DC converter for the micro. I think Sparkfun sells them. At Digikey, I did find power supplies that supplied 5v and 3.3v, but at several amps they were really expensive. I’d suggest using actual 120VAC outlets to plug the lights into. The outlets should be in the same box as the relays to keep the 120 volt circuits confined. The micro and relay drivers will be in a separate box. The only connection between the two boxes will be 5 volts and relay driver outputs for the relays, plus ground.