Searching \ for '[PIC] need circuit to monitor AC mains and switch' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: www.piclist.com/techref/power.htm?key=ac
Search entire site for: 'need circuit to monitor AC mains and switch'.

Exact match. Not showing close matches.
PICList Thread
'[PIC] need circuit to monitor AC mains and switch '
2007\06\26@145022 by Miguel Reznicek

flavicon
face
Friends:

Does someone know of a PIC chip circuit that will monitor the 220 VAC mains
and use them to run, but that can automatically switch to a battery power
when the mains fails?  I need to make an alarm for when the power fails.

Thanks in advance,

Miguel Reznicek
spam_OUTmreznicekTakeThisOuTspampretensa.com


2007\06\26@150506 by Marcel Duchamp

picon face
For a good answer you need to provide more information.

But based on what you stated, you could do this with two diodes to
switch power and another diode-R-C network to tell the PIC that AC power
has gone bye-bye.  The alarm can then be whatever you wish: LED, buzzer,
siren, etc.

If this is a one-off application, you could buy a computer
battery-backup power supply (often called UPS - Uninterruptible Power
Supply) which will do everything you want.

Miguel Reznicek wrote:
{Quote hidden}

2007\06\26@151551 by Vasile Surducan

face picon face
One diode in series from the battery to Vdd, one resistor from 220VAC
phase to INT (better with an optocoupler).

On 6/26/07, Miguel Reznicek <mreznicekspamKILLspampretensa.com> wrote:
{Quote hidden}

> -

2007\06\26@163040 by alan smith

picon face
dont forget the supercap to keep the PIC alive while the power is being switched

Vasile Surducan <EraseMEpiclist9spam_OUTspamTakeThisOuTgmail.com> wrote:  One diode in series from the battery to Vdd, one resistor from 220VAC
phase to INT (better with an optocoupler).

On 6/26/07, Miguel Reznicek wrote:
{Quote hidden}

> -

2007\06\26@172721 by engineer

face picon face
Miguel Reznicek wrote:
> Friends:
>
> Does someone know of a PIC chip circuit that will monitor the 220 VAC mains
> and use them to run, but that can automatically switch to a battery power
> when the mains fails?  I need to make an alarm for when the power fails.
>
> Thanks in advance,
>
> Miguel Reznicek
> @spam@mreznicekKILLspamspampretensa.com
>
>
>  
Monitoring of 220VAC mains is best done with an optocoupler in series
with several high-ohmage resistors.
Normally 1M ohm is enough, but in actual operation, the 220VAC will jump
over the resistive material, so
several at 470K in series will then work properly.

A simple diode can allow a battery to take over when power fails. Don't
make this more complicated than it needs to be.

--Bob A

2007\06\26@191258 by Jinx

face picon face
part 1 1081 bytes content-type:text/plain; (decoded 7bit)

> Does someone know of a PIC chip circuit that will monitor the 220
> VAC mains and use them to run, but that can automatically switch to
> a battery power when the mains fails?  I need to make an alarm for
> when the power fails

Hi Miguel, you could use this to detect mains

http://home.clear.net.nz/pages/joecolquitt/txless/zc-detect-opto.gif

or something like the attached to switch

I agree with Bob about not making it too complicated but there
are a certain number of elements you'd need to have. A FET
would substitute for a relay, depends what power requirements
you need

The attached can potentially detect the mains in two ways. Vsense
is not strictly needed, but works. The diode after the 39k isolates
the reservoir cap to speed the switching

How my circuit (part of a clock) actually works is that the PIC s/w
looks for INT0 triggered by the mains. TMR0 is also running, and
times out if a mains cycle isn't received. The PIC releases the relay
and uses TMR0 as the back-up timing reference until mains is
restored


part 2 5607 bytes content-type:image/gif; (decode)


part 3 35 bytes content-type:text/plain; charset="us-ascii"
(decoded 7bit)

2007\06\26@192817 by Jinx

face picon face
> The PIC releases the relay

PS, this is the Ver1 circuit (F84) in which the relay drops out
when the mains-derived DC runs down, Ver2 (F88) is arranged
slightly differently and includes battery monitoring to prevent SLA
battery death

2007\06\27@125317 by Rich Satterlee

flavicon
face
Hi-

For all the good suggestions that have come up, there has been one assumption that
has been made.  If indeed, the PIC is supplied with the same power as the
application, then there is many good solutions already posted to choose from.

However, if the mains in question are NOT being supplied by the same circuit as the
PIC, or indeed, you want to monitor several power sources and switch in battery
supply for more than one, well that might just change things.

My circuit was for a PLC and to monitor several AC mains from a general purpose
input. Also, I didn't have to worry about an instantanious switchover.  More
than a cycle dropout would be o.k.

I went with a largeish (I'm doing this from memory) 0.1 500V non polarized
non-electrolyic cap that can source about 10ma or so of current when 60Hz is
passed through it.  This was in series with a few K ohm resistor to a diode
bridge.  The output of the bridge supplied enough current to illuminate the LED
in an opto-isolator (4x25 which is the worst of the bunch).  The output was
fed to a low voltage cap to smooth out the DC and not trigger the input.

You can find reference to using a cap on AC mains in the microchip app notes.
However, this is for driving an optoisolator, not powering the PIC.

I like this circuit as it has a very small number of components and is still
isolated from the mains.  It will also work with DC.  My calculations were for
110VAC, however, a bit of experimenting will allow it to work on 220V.  

You might find it worthwhile to experiment with an isolation transformer in the
circuit, properly fused.  Watch out for scope grounding problems too.

The cap choosen was to allow for the passage of 10ma through the optoisolator.
It is rather largish and might not be available cheaply.  I did find mine in
a surplus house for a few pennnies,  so you might want to investigate an alternative
like diodes and polarized electrolytics..... If you find some optoisolators that
are more sensitive than the ones I choose, then this too will cut down the
current requirements for the design.

Hope that this helps!  If you are monitoring a different power source than that
of the PIC, then this hopefully will be of use.  If you are powering from the
same, then sorry and please disregard.

 Cheers,

  Rich S.

---- Original Message ----
From:                Miguel Reznicek
Date:                Tue 6/26/07 12:11
To:                KILLspampiclistKILLspamspammit.edu
Subject:        [PIC] need circuit to monitor AC mains and switch to battery on AC loss plus
alarm

Friends:

Does someone know of a PIC chip circuit that will monitor the 220 VAC mains
and use them to run, but that can automatically switch to a battery power
when the mains fails?  I need to make an alarm for when the power fails.

Thanks in advance,

Miguel Reznicek
RemoveMEmreznicekTakeThisOuTspampretensa.com


2007\06\27@153835 by YAP

picon face
On 6/26/07, Miguel Reznicek <spamBeGonemreznicekspamBeGonespampretensa.com> wrote:
> Friends:
>
> Does someone know of a PIC chip circuit that will monitor the 220 VAC mains
> and use them to run, but that can automatically switch to a battery power
> when the mains fails?  I need to make an alarm for when the power fails.
>
> Thanks in advance,
>
> Miguel Reznicek
> TakeThisOuTmreznicekEraseMEspamspam_OUTpretensa.com

I have a design here www.vscp.org/wiki/doku.php?id=rockhampton
Here The voltage sense is used to check the status for some lamps
(really relay outputs).

For power a 12V power source and a 12V SLAB connected to a charge is
used. A standard 110V/230V switching relay is used  that switch
between battery vs. power supply as the design  can live with power
going away as long as the system goes up again.


Cheers
/Ake

--
---
Ake Hedman (YAP - Yet Another Programmer)
eurosource, Brattbergavagen 17, 820 50 LOS, Sweden
Phone: (46) 657 413430 Cellular: (46) 73 0533 146
Company home: http://www.dofscandinavia.com
Kryddor/Te/Kaffe: http://www.brattberg.com
Personal homepage: http://www.dofscandinavia.com/akhe
Automated home: http://www.vscp.org

More... (looser matching)
- Last day of these posts
- In 2007 , 2008 only
- Today
- New search...