Emergency Light Auto switching

At this initial stage, I need some advice on how to start. There are three parts to this project:

  1. Power supply Takes 220 V and convert it to 12 Volt dc
  2. Rechragable Battery with the following spec:

6V 4.5Ah/20Hr
7.3-7.4v cycle use
6.8-6.9v standby use

Initial Current < 1.35 A

  1. a block of white leds( 50)

The controlling Arduino is suppose to do the following:

  • The block of Leds is OFF while there is an AC source.
  • Monitor Input AC source, and when the source power is off, switch automatically to Battery Source
  • While the ac source is ON, the source will CHARGE the battery, once fully charged It will suspend recharging the battery.

Any advice will be greatly appreciated

To sense the 220V often a small transformer is used. There are optocouplers for 220V, but a transformer is simple.
Do you want to use the Arduino to charge the battery ? That is dangerous, if something is wrong the battery could be overcharged.

arishy:
At this initial stage, I need some advice on how to start. There are three parts to this project:

  1. Power supply Takes 220 V and convert it to 12 Volt dc
  2. Rechragable Battery with the following spec:

6V 4.5Ah/20Hr
7.3-7.4v cycle use
6.8-6.9v standby use

Initial Current < 1.35 A

  1. a block of white leds( 50)

The controlling Arduino is suppose to do the following:

  • The block of Leds is OFF while there is an AC source.
  • Monitor Input AC source, and when the source power is off, switch automatically to Battery Source
  • While the ac source is ON, the source will CHARGE the battery, once fully charged It will suspend recharging the battery.

Any advice will be greatly appreciated

Use a relay energized by the 12 volt power supply / charger.

                       NO <---- charging circuit
battery pack <---> RELAY
                      NC ----> emergency lights

You don't need an Arduino for such a simple task.

Peter_n:

The 3 parts are already made, the power supply is using a trasnforfer, so it is isolated.
The way I see it, Power supply provides 12 volt to charge the battery while the block of leds is off
Once the power is off , the Battery provide the power for the LEDS. Through using relays and some simple logic I can control the switching.

Krupski:

You are absolutly right A relay will do the switching, but I thought if I use the Arduino I will be able to monitor the charging of the battery, so I do not over charge.

An Arduino is tooooooo much for this. Attached schematic for charger in EAGLE fomat.
Wiil attachauto switcher as soon as I find it.

Will wait for the "AutoSwitcher", in the mean time, I want to monitor the 12V, if off I use a relay to switch the battery to the LED circuit. At the same time I will monitor the battey charge if above a certail voltage I disconnect temprary the 12v supply.

I will use Voltage divider to get less that 5V to a digital pin. If LOW I will activate the realy to connect the bttery to the LED block.

I will use an analog pin to measure the Battery voltage ( I will use a voltage divider for that too)

My concern is using voltage dividers takes power, and I need to conserve it especially when power is OFF.

Let us leave the practical side for a while and consider this as a learning exercise. How can I use this approach to program say Arduino tiny to this simple circuit Manouvering??...

arishy:
Peter_n:

The 3 parts are already made, the power supply is using a trasnforfer, so it is isolated.
The way I see it, Power supply provides 12 volt to charge the battery while the block of leds is off
Once the power is off , the Battery provide the power for the LEDS. Through using relays and some simple logic I can control the switching.

Krupski:

You are absolutly right A relay will do the switching, but I thought if I use the Arduino I will be able to monitor the charging of the battery, so I do not over charge.

I assume you are using lead-acid cells? Regardless, different battery technologies require different charging methods. Look up HOW to properly charge the battery type you are using and design a charger to match.

Fortunately, lead-acid batteries are simple to charge and tolerant of overcharging. You charge lead-acid at 2.35 volts per cell. For a 6 volt battery, that's 7.05 volts.

Just make a 7.05 volt DC power supply and send it to the battery through the relay. Power the relay coil from the unregulated side of the power supply (which will probably be around 12 volts).

When the power goes off, the power supply goes away, the relay switches and disconnects the power supply from the battery (and connects the battery to the LED array).

Remember a quote from a famous man:

[b]"Anything that is complex is not useful and anything that is useful is simple. This has been my whole life's motto."[/b] --- Mikhail T. Kalashnikov

The modern version is "KISS" (Keep It Simple, Stupid).

(not calling you stupid... that's just what "kiss" stands for!)

Krupski:

I love your post....I am an Engineer and I used to say the most DIFFICULT design is the SIMPLE one.
So, I am happy to join your "club" !! I mean your motto.....

Very informative info on the charging bit...I will design the circuit accordingly. I will also try to avoid the resistive Voltage divider..If I can.

Forgot; R3=1k,R4=10k; had these on hand. LEDs lower a bit on battery, 12v.

alah:

I did not get the "Attached schematic for charger in EAGLE fomat"

arishy:
alah:

I did not get the "Attached schematic for charger in EAGLE fomat"

Nor did anyone else.

Sorry, having problems with internet connection,
Spent from Friday to this morning trying to download IDE 1.0.5,1.0.6, 1.6.0 NO LUCK.

With a 6v. battery you can only light ONE LED.
With a 12v., you can have 3 LED strings with less current comsumption.
Tested with one string and a 450A vehicle battery.
Adjust Vcap2 to 13.8v.
While AC, Q1 ON and holds Q2 OFF.
As Vbat rises, charging current lowers due to voltage difference across R5, 1 to 2Ohm/ 2w.
When charged, trickling starts avoiding over charge.
If AC loss, Q2 turns ON and LEDs light.
Q2 should handle total LEDs current.
Works for me, might have to tweak for your use.

Doc1.pdf (94.8 KB)