Shop OBEX P1 Docs P2 Docs Learn Events
VAC to VDC — Parallax Forums

VAC to VDC

RICoderRICoder Posts: 91
edited 2009-02-05 06:07 in General Discussion
I need a sanity check before I die of Google overload...

I'm building a digital thermostat, and I need to power it. The lines out of the wall are supposedly 24VAC (I'll check before I actually hook it up, I promise) and I'm trying to figure out how the hell to deal with that.

Can I build a transformer onto the board without running the cost through the roof (say total component cost of $10 or so)?
If not, should I just use batteries? Man, the thought of that just kills me...

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2009-02-04 06:07
    You could probably dispense with the transformer by using a rectifier (like a 1N4001) followed by a filter capacitor, then a voltage regulator like the MAX5033 (www.maxim-ic.com/quick_view2.cfm/qv_pk/3990). By using a simple switching regulator, you can keep the amount of heat down.
  • Carl HayesCarl Hayes Posts: 841
    edited 2009-02-05 01:51
    Some thought is in order.· The lines coming out of the wall almost certainly are 24vac, for that is a standard way to build HVAC systems.· You'll need to rectify that to get the 5vdc you'll probably need.

    However, there are other wires coming out of the wall too.· These are the ones you'll have to connect together to turn on the compressor, the fan, possibly a heating coil, etc.·· These are not isolated from that 24vac supply!· That may or may not be a problem.· If you use small relays to make the output connections, that particular problem goes away, for the relays will provide the isolation you need.· No doubt someone will pantingly suggest optoisolators because they think they're neat, but these may be less appropriate because you're switching AC at the output, not to mention the unnecessary added cost.· Relays are cheap and reliable.

    You could rectify the 24vac directly to give about 30vdc, which you'd then regulate down to the 5v (or maybe 3.3v) you need.· You'd have to dissipate a lot of heat in the regulator.

    Or you could use a series resistor to do most of the voltage-dropping, and dissipate most of the heat in the resistor and the rest in the regulator.· Still a lot of heat in a little box on the wall.

    Or you could use an appropriately selected capacitor to drop the 24vac down to a more workable value, dissipating no heat but still reducing the drop in the regulator and thus the heat it must dissipate.

    Something like what I've attached would work OK.· The capacitors are both necessary if you don't use relays at the output for isolation.· If you do use relays for isolation, you need only one of the capacitors.

    How big a capacitor?· It depends on how much current you need.· I'd start at about 5 microfarads and experiment.· When the input to the regulator is at about 7 volts under maximum current, it'll be about right.

    Remember to use nonpolar capacitors to couple the 24vac.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    · -- Carl, nn5i@arrl.net
  • Carl HayesCarl Hayes Posts: 841
    edited 2009-02-05 03:12
    Additional thoughts:

    (1) It's possible that your controller must connect the other wires to the 24vdc rather than to each other. That's no problem as long as you maintain the isolation.

    (2) Probably the required capacitance will be a lot larger than the 5 micorfarads I suggest as a starting point for experiment. It would be no surprise to need several hundred microfarads, but still I'd start with about five and work up experimentally, perhaps a factor of five or ten at a time. You must use nonpolar capacitors.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    · -- Carl, nn5i@arrl.net
  • RICoderRICoder Posts: 91
    edited 2009-02-05 06:07
    I've pulled open every digital thermostat that I have seen in the past week, and they are all battery driven...which leads me to think I am not unique in the world for wondering how to power one. Apparently that's the way to go, so I will start there.
    There is definitely 24VAC in and out in the other wires, the point of them it to switch the heat and air conditioner on (as well as a fan only if you have forced air). A relay is apparently the best way to deal with this, so that is where I will start.
Sign In or Register to comment.