Post Top Ad

Saturday, February 17, 2024

on video Useful Super led blinking flasher circuit, you can make it home


 Useful Super led blinking flasher circuit, you can make it home

In this Instructable, I am going to try and explain, step by step, how I designed this Ultra Low-Power LED Flasher with the following specification:.


LED flash rate 1 flash per second

LED on-time of 5ms

At least 2 years battery life

Use standard "AA" size batteries

Unfortunately, uses two "AA" batteries

Easy obtainable components

No surface mount components

No PC Board

Before I decided on a baseline, I tested several common flasher circuits. These included standard flashing LED's, the NE555 timer IC, and transistor flip-flop circuits commonly used. The first problem I experienced, is the amount of components needed to get a short output pulse of around 1 - 5ms every 1 second, or On/Off ratio of 1/1000 to 5/1000. Thus I did not investigate these designs further.


The circuit I decided to use as a starting point, is the LM3909 LED flasher IC. Although production of this very popular chip has ended, they are still freely available on eBay at a reasonable cost. Looking at the LM3909 datasheet, it states that the flasher circuit can run up to 6 months on a single alkaline cell.


So why did I not use the LM3909, you may ask? Well, in South Africa, our postal system had collapsed, and the average waiting time for an eBay order is between 3 and 6 months....


My Baseline:


Standard AA battery

12 Months minimum operation per battery

Replace the LM3909 with a micro controller

I decided to make use of an AtTiny85 micro controller, as I have some in my bins. Using the datasheet, I had two options:


AtTiny85-20

Minimum operating voltage is 2.7V


AtTiny85V-10

Minimum operating voltage is 1.8V


From above data, it is clear that I will have to use two AA size batteries to power the circuit. So the operating voltage will be taken as nominal 3V for the rest of the design.


The next step was to decide on which AtTiny to use, and for this, I had to do some research on battery capacity.

I will be basing all my calculations on the “AA” Duracell MN1500, as this is what I had on hand. This might not be the best battery for the project.


Minimum operating voltage of the AtTiny are taken, and divided by 2 to give minimum voltage per cell required.


AtTiny85-20

Vminimum = 2.7V, or 1.35V per cell


From the datasheet (lowest mW curve available), battery capacity is around 0.25Ah at 1.35V.


AtTiny85V-10

Vminimum = 1.8V, or 0.9V per cell

From the datasheet (lowest mW curve available), battery capacity is around 2.2Ah at 0.9V.


Next, we need to determine the average current consumption of our circuit. Using the Duracell MN1500 with an AtTiny85V-10, we have 2.2Ah available.


Ah = Iaverage x 24 hours x 365 days,


2.2Ah = Iaverage x 24 x 365


Iaverage = 251uA

The test circuit is per schematic, and to keep measurements comparable, I connected the circuit to a 3V regulated power supply.


The test code is straight forward, switching an output on for 5ms, and off for 995ms.


In the Arduino IDE, there are only three internal clock selections available. I will test each of them individually. To learn more about setting the configuration bits, please refer to AVRDude.


AtTiny85 at 16MHz (with DigiSpark Bootloader)

Set Fuse Low Byte = 0xE1


Set Fuse High Byte = 0xDD


Imax = 13.20mA


Imin = 4.64mA


Iavg = 8.80mA


AtTiny85 at 8MHz

Set Fuse Low Byte = 0xC2

Set Fuse High Byte = 0xDF

Imax=4.28mA


Imin = 4.04mA


Iavg = 4.13mA


AtTiny85 at 1MHz

Set Fuse Low Byte = 0x42

Set Fuse High Byte = 0xDF


Imax = 1.28mA


Imin = 1.00mA


Iavg = 1.10mA, or 1100uA

The AtTiny can be placed into a sleep mode when the LED is in the off state. This will shut down certain hardware in the chip, as well as further reducing the average current used.


For the design, I want the LED to flash once every second. By using the SLEEP commands, I will turn on the LED for 5ms, then turn off the LED. Thereafter, the chip will be placed into the SLEEP mode to reduce power.


After 1 second, the build-in watchdog timer will be used to wake up the chip from sleep, and the LED will be turned on again.


For this, I will be using additional libraries


 Useful Super led blinking flasher circuit, you can make it home

In this Instructable, I am going to try and explain, step by step, how I designed this Ultra Low-Power LED Flasher with the following specification:.


LED flash rate 1 flash per second

LED on-time of 5ms

At least 2 years battery life

Use standard "AA" size batteries

Unfortunately, uses two "AA" batteries

Easy obtainable components

No surface mount components

No PC Board

Before I decided on a baseline, I tested several common flasher circuits. These included standard flashing LED's, the NE555 timer IC, and transistor flip-flop circuits commonly used. The first problem I experienced, is the amount of components needed to get a short output pulse of around 1 - 5ms every 1 second, or On/Off ratio of 1/1000 to 5/1000. Thus I did not investigate these designs further.


The circuit I decided to use as a starting point, is the LM3909 LED flasher IC. Although production of this very popular chip has ended, they are still freely available on eBay at a reasonable cost. Looking at the LM3909 datasheet, it states that the flasher circuit can run up to 6 months on a single alkaline cell.


So why did I not use the LM3909, you may ask? Well, in South Africa, our postal system had collapsed, and the average waiting time for an eBay order is between 3 and 6 months....


My Baseline:


Standard AA battery

12 Months minimum operation per battery

Replace the LM3909 with a micro controller

I decided to make use of an AtTiny85 micro controller, as I have some in my bins. Using the datasheet, I had two options:


AtTiny85-20

Minimum operating voltage is 2.7V


AtTiny85V-10

Minimum operating voltage is 1.8V


From above data, it is clear that I will have to use two AA size batteries to power the circuit. So the operating voltage will be taken as nominal 3V for the rest of the design.


The next step was to decide on which AtTiny to use, and for this, I had to do some research on battery capacity.

I will be basing all my calculations on the “AA” Duracell MN1500, as this is what I had on hand. This might not be the best battery for the project.


Minimum operating voltage of the AtTiny are taken, and divided by 2 to give minimum voltage per cell required.


AtTiny85-20

Vminimum = 2.7V, or 1.35V per cell


From the datasheet (lowest mW curve available), battery capacity is around 0.25Ah at 1.35V.


AtTiny85V-10

Vminimum = 1.8V, or 0.9V per cell

From the datasheet (lowest mW curve available), battery capacity is around 2.2Ah at 0.9V.


Next, we need to determine the average current consumption of our circuit. Using the Duracell MN1500 with an AtTiny85V-10, we have 2.2Ah available.


Ah = Iaverage x 24 hours x 365 days,


2.2Ah = Iaverage x 24 x 365


Iaverage = 251uA

The test circuit is per schematic, and to keep measurements comparable, I connected the circuit to a 3V regulated power supply.


The test code is straight forward, switching an output on for 5ms, and off for 995ms.


In the Arduino IDE, there are only three internal clock selections available. I will test each of them individually. To learn more about setting the configuration bits, please refer to AVRDude.


AtTiny85 at 16MHz (with DigiSpark Bootloader)

Set Fuse Low Byte = 0xE1


Set Fuse High Byte = 0xDD


Imax = 13.20mA


Imin = 4.64mA


Iavg = 8.80mA


AtTiny85 at 8MHz

Set Fuse Low Byte = 0xC2

Set Fuse High Byte = 0xDF

Imax=4.28mA


Imin = 4.04mA


Iavg = 4.13mA


AtTiny85 at 1MHz

Set Fuse Low Byte = 0x42

Set Fuse High Byte = 0xDF


Imax = 1.28mA


Imin = 1.00mA


Iavg = 1.10mA, or 1100uA

The AtTiny can be placed into a sleep mode when the LED is in the off state. This will shut down certain hardware in the chip, as well as further reducing the average current used.


For the design, I want the LED to flash once every second. By using the SLEEP commands, I will turn on the LED for 5ms, then turn off the LED. Thereafter, the chip will be placed into the SLEEP mode to reduce power.


After 1 second, the build-in watchdog timer will be used to wake up the chip from sleep, and the LED will be turned on again.


For this, I will be using additional libraries

No comments:

Post a Comment

Post Top Ad

Pages