Open Fridge Alarm

Coin Battery Powered Open Fridge Alarm.

Similar projects worth following
Project is meant but not limited to Fridges without Open Alarm. Not limited to Fridges either.
It is powered from coin battery. For the long life when closed device will be in standby mode using fractions of mA.
All Hardware design files including Schematic, PCB, Enclosure STL are published. Also software is open source.

Device have two parts. One is passive part containing earth magnet in an enclosure. Other part is Active one with microprocessor, REED sensor, LED and Sounder.

Both Enclosures are 3D Printed. STL files are available below. I've attached board design for purely Hole Trough Components and for some SMD replaced once. Note that Hole Trough sounder uses significantly more current.

Schematic and PCB is available below as well. I've attached pdf and Gerber files.

Operating Principle:

REED sensor (NO/NC contacts) reacts with magnet. When contact is met (doors are closed) device is in  Power Down mode drawing minimum amount of power.

When doors are open (contact is open) then system wakes up using Pin Change Interrupt, flash lights LED for 5 sec and after 30 second Sounder will be activated. Program pulses Sounder.

I was planning to have the LED on all the time but Martin suggested to flash it to save energy. THANK YOU for that. Did have time yet to check visibility of the LED inside the enclosure with higher resistor which would limit the power farther.

If LED will not turn on then it will indicate that there is no power ie. Battery requires changing. I know it's counter intuitive but this project is design to last as long as possible on battery. Also Resistor chosen for the LED is Higher then required so the current in the circuit is lower. It will cause LED to be dimmed but it will preserve energy. Full brightness is achieved at 20mA.

I've added Diode to protect circuit from reverse polarity. For Coin Battery it's not going to work well since the Voltage drop on Diode will affect voltage supplied to rest of the components. Since my goal is extended battery life I will use jumper in the place of a diode.

Power Calculation:

Calculation is based on SMD version. Sounder is drawing 1mA and LED with 220ohm resistor will take less than 4mA. Controller will use 0.1uA when in Power Down Mode and about 180uA when in normal operation.

Assumption Fridge is opened daily 20 times and 10 times sounder is activated

Need to double check values but for an estimate

5s x 20 /2  - 1.815 mA  = 30.25 uA/24h - LED operating for 5 seconds but only half of the time

25 s x 20 - 200 uA = 25 uA /24h - LED is off timer is counting for remaining 25 seconds

30 s x 10 / 4 - 0.3 mA =  25 uA/24h - LED is off sounder is activated for 30 seconds every 4 cycles (400 ms)

23.75h - 0.1 uA = 2.35 uA - System is in Power - Down Mode, Power Reduction Mode

Round up:

1 minute - 30.25 uA/day

9 minutes - 25 uA/day

5 minutes - 25 uA/day

15 minutes it will work 80.25 uA and 23 h and 45 minutes it will consume 2.35 uA

Daily it will consume about 83 uA

3 V Coin Battery has capacity of 240mAh. 240mAh/83uAh = 2891 days

That's about 7.9 years.


Enclosure STL file.

Standard Tesselated Geometry - 666.70 kB - 12/28/2017 at 13:39



C Code

cpp - 2.91 kB - 12/28/2017 at 10:52



Set of PDF's for PCB manufacturing. Hole Trough Solution

Zip Archive - 14.60 MB - 12/11/2017 at 12:04


Set of Gerber files for PCB manufacturing. Hole Trough Solution

Zip Archive - 19.81 kB - 12/11/2017 at 12:04


Adobe Portable Document Format - 14.64 MB - 12/11/2017 at 11:59


View all 7 files

View all 13 components

View project log

  • 1
    Making PCB

    If using universal PCB just solder all the components as per Schematic.

    Provided Gerber files can be used to get board manufactured. Alternatively PCB can be developed using home methods. PDF printout of the copper can be used.

  • 2

    Board is design to be programmed with AVR MKII programmer. Available software can be used to program micro controller.

    I'm using AVR Studio.

  • 3
    3D print enclosure

    3D print enclosures using STL files provided.

View all 7 instructions

Enjoy this project?



mariusz_nowak_eng wrote 12/11/2017 at 10:08 point

For calculation I used LED i had at home but thanks for a tip. I will look in to that.

  Are you sure? yes | no

Martin wrote 12/11/2017 at 10:02 point

Modern high efficiency GaN LEDs (blue, white or green) offer good visibility with 500µA. More power saving is possible if you blink the LED with 50 to 100ms every second.

  Are you sure? yes | no

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates