help simplifying a circuit to trigger beeper when main battery disconnects...

Thread Starter

bigjoncoop

Joined Feb 1, 2019
167
starting up a old project of mine for a RC lost model alarm

the circuit triggers a beeper to go off when the main quadcopter battery get ejected, the way these work is, they have a small self contained battery and it monitors 5v coming from the quadcopters flight controller. when that 5v isn't present it uses its own battery to set off a beeper...

seems to be overkill to use a attiny85 to do this... couldn't it be done using just a transistor or 2 or a comparator etc...

diy-lost-model-alarm-buzzer-beeper-built-in-lipo-battery-connection-attiny85.jpg
 
Last edited:

Irving

Joined Jan 30, 2016
2,198
seems to be overkill to use a attiny85 to do this... couldn't it be done using just a transistor or 2 or a comparator etc...
On the contrary, this is a very simple solution, only 4 components if you run the attiny85 off the battery directly (it runs on 3.5v, though you'll need a 2v buzzer). To do this otherwise, monitoring the battery voltage requires the following circuit, which is as simple as I can make it - needs 5 parts and has more solder joints, so arguably more complex! Also the buzzer runs continuously whereas the attiny solution pulses it about once a second to save battery. The circuit below holds the buzzer off while the FC voltage is > 4v, if it drops below that the buzzer sounds. The buzzer is a Kingsgate KXG1203C 85dB Sounder rated for 2 - 5v operation.. This should run for 8h on a 150mAh 3.7v li-po pouch cell, or 4-5h on 3 AAA cells.

1630012199179.png

Addendum: R1 probably not needed!
 

Juhahoo

Joined Jun 3, 2019
226
Emergency battery hardly is 5V, more like 3-4V, so check if your buzzer can work with 3 Volts.
This circuit draws small amount of current from both sources every time batteries are connected, so you cant leave it on for long periods.
If you need to keep it ON without switching it off, use MOSFETS so you can bias them with higher resistor values.
Resistors depend on your transistors, but say R1=R2 = R3 = 10k is a good general value to start with.
 

Irving

Joined Jan 30, 2016
2,198
My MOSFET solution is simpler and drains <500uA in standby. You could reduce that to <50uA by removing R1 and making R2 = 100k. Total cost of parts inc buzzer exc battery and perfboard is <$1.2 each for 20 off.
 

Tonyr1084

Joined Sep 24, 2015
6,374
Emergency battery hardly is 5V, more like 3-4V, so check if your buzzer can work with 3 Volts.
This circuit draws small amount of current from both sources every time batteries are connected, so you cant leave it on for long periods.
If you need to keep it ON without switching it off, use MOSFETS so you can bias them with higher resistor values.
Resistors depend on your transistors, but say R1=R2 = R3 = 10k is a good general value to start with.
Well, I'm looking at 5V, R3 (10KΩ) and Q2. When you disconnect the battery; is 500µA sufficient to drive Q2 into conduction?

I'm wondering - and I don't know this - what if you replace the 5V emergency battery with a super-cap? A Schottky diode can keep the super-cap charged. When power is interrupted, current can back flow through the buzzer when Q2 turns on (or rather, a MOSFET). Will require a slightly modified diagram I think.
 

Tonyr1084

Joined Sep 24, 2015
6,374
Going to take a stab at this, but I suspect it won't be feasible. I'm using a Schottky diode to charge C1, a super-cap (in place of the emergency battery). When power is applied, i.e. a 5V lithium battery whose capacity is unknown at the present, so I'll assume 1200mAh, C1 is charged through R4 (33Ω 1 watt) and D1 (Schottky diode). R1 & R2 form a voltage divider that should turn Q1 on, holding the gate of M1 at ground. R3 & R4 form a voltage divider charging C1 (minus the Vf of D1) to near 5V. C1 is a super-cap of as yet unchosen value. Being that they are typically around 2V, multiple caps in series will likely be needed. The capacitance required will be determined by how long the buzzer is meant to keep buzzing, time period as yet undetermined.

When power is removed (5V lithium battery) Q1 drops out and allows C1 to conduct through R3 to apply voltage at the gate of M1. M1 conducts until C1 is depleted and the buzzer (at some as yet undetermined time period) stops buzzing.

I think it works, but the questions I can't answer is how much power will charging C1 take away from the battery; and how long the buzzer will buzz. I leave this open to tweaking by those who know much more than I know.
1630080545500.png
 

Tonyr1084

Joined Sep 24, 2015
6,374
Now that you replaced one transistor to MOSFET, replace the other one too and use 1+M resistors, you reduce the current consumption to few uA.
This isn't my thread; just my stab at a solution. Using 2 MOSFET's is just as easy. But since I don't know what the TS has by way of stockpile, I've tried to make as few changes as possible. I don't even know if my circuit would be feasible. Primarily the concern for the super-cap and charging it from the main flight battery. I suspect it will probably drain the flight battery rather significantly. But again, I don't know that.
 

Thread Starter

bigjoncoop

Joined Feb 1, 2019
167
Emergency battery hardly is 5V, more like 3-4V, so check if your buzzer can work with 3 Volts.
This circuit draws small amount of current from both sources every time batteries are connected, so you cant leave it on for long periods.
If you need to keep it ON without switching it off, use MOSFETS so you can bias them with higher resistor values.
Resistors depend on your transistors, but say R1=R2 = R3 = 10k is a good general value to start with.
most of these devices basically use the 5v from the flight controller and tp4056 or similar circuit to charge the small 1cell onboard emergency battery. and most boost the 1cell up to 5v to run the circuitry.

Im not implying we have to since im trying to find a way of making this work without the use of a IC.

*** Just to add a little more info on the type of conditions this will be used under ***

* This circuit only needs to run for no more than maybe about an hour 99% of the time....
(they will be used on racing style quadcopters. once in a great while sometimes one will crash in a field next to where we are flying in some tall grass or maybe land in a tree fairly close to us... normally we can find a lost quadcopter with in minutes. just once in a while it may take 20mns if in a tree and we cant see it etc...)
 

Irving

Joined Jan 30, 2016
2,198
It will work. The buzzer I spec'd needs 15mA @ 2v for 85-90dB output. So assuming C1 charged to 4.5v and buzzer stops at 2v then:

Q = i.t = C.dV, or t = C. dV/i = 2.5/0.015C = 100C so 100sec per Farad

i.e 50F = 1.4 hour approx.

A 50F capacitor charges via 33ohm resistor from discharged at initially 5/33A = 150mA and reaches 95% charge in 3CR secs or 3*33*50sec, about 1.4hour.

The problem is that a 50F supercap is considerably more expensive than the LiPo battery, and a typical 50F supercap is only rated at 2.5v so in practice you'll need 2 x 100F in series, 3x the price of a small LiPo.
 

Juhahoo

Joined Jun 3, 2019
226
* This circuit only needs to run for no more than maybe about an hour 99% of the time....
(they will be used on racing style quadcopters. once in a great while sometimes one will crash in a field next to where we are flying in some tall grass or maybe land in a tree fairly close to us... normally we can find a lost quadcopter with in minutes. just once in a while it may take 20mns if in a tree and we cant see it etc...)
Why this buzzer is related to battery disconnection, what if the battery is not disconnected during the crash?
If I was you and designing such system, I would make sure the main battery stays connected and all the energy is sourced from there. Just too much of hassle with extra batteries and stuff. Much more simple solution is when receiver stops receiving signals from the transmitter buzzer goes ON, like anytime you shut down the transmitter. Something like this:

1630175571816.png
 
Last edited:

Thread Starter

bigjoncoop

Joined Feb 1, 2019
167
Why this buzzer is related to battery disconnection, what if the battery is not disconnected during the crash?
If I was you and designing such system, I would make sure the main battery stays connected and all the energy is sourced from there. Just too much of hassle with extra batteries and stuff. Much more simple solution is when receiver stops receiving signals from the transmitter buzzer goes ON, like anytime you shut down the transmitter. Something like this:

View attachment 246774
Well in the event of a crash and then main battery STAYS connected, all modern flight controllers have a designated buzzer pad on the pcb that can be triggered from a switch on our transmitter/remote control

This wbole project is only being designed around in the event that the main battery becomes disconnected during a hard crash. If the battery stays connected we have multiple ways of finding the quadcopter.

And this entire circuit needs to be as cheap and small as possible. There are a bunch of mass-produced lost model alarms the same as we're trying to design here that are readily available for purchase. Some of them from as low as $10 a piece and some go all the way up to $30 a piece.

The whole purpose is to DIY my own circuit to perform the same task that will cost a fraction of the price since I myself have at least 20 quadcopters that each need one of these circuits. So as you can see the adds up quickly. And I would like to make a bunch and pass them out to my fellow fpv enthusiasts.

I already have a working circuit but like I mentioned in the beginning of this thread it utilizes a Attiny85 microprocessor. But it just seems that it could be accomplished without using a microprocessor and Save half the price.
 
Last edited:

Irving

Joined Jan 30, 2016
2,198
When I get home from work here shortly oh, I will take a look at it and mock it up on a breadboard quick and see how well it works and get back to you ASAP
The important thing is to make sure the p-channel is switched on at Vgs ~-2v. The one i spec'd is readily available

Edit. A pair of AAA batteries - Alkaline, primary Lithium, or rechargeable - will give run-times of > 30 hours!
 
Last edited:

Juhahoo

Joined Jun 3, 2019
226
And this entire circuit needs to be as cheap and small as possible. There are a bunch of mass-produced lost model alarms the same as we're trying to design here that are readily available for purchase. Some of them from as low as $10 a piece and some go all the way up to $30 a piece.

The whole purpose is to DIY my own circuit to perform the same task that will cost a fraction of the price since I myself have at least 20 quadcopters that each need one of these circuits. So as you can see the adds up quickly. And I would like to make a bunch and pass them out to my fellow fpv enthusiasts.

I already have a working circuit but like I mentioned in the beginning of this thread it utilizes a Attiny85 microprocessor. But it just seems that it could be accomplished without using a microprocessor and Save half the price.
Price, weight and size is all based on a proper designing. With 3 components you achieve none of those. Energy storage is the largest, most expensive and heaviest of all these parts, figure out first how to reduce the size of the energy storage, then the rest is easy.

The key is to lower your current consumption. This is easily done by pulsing the output instead of keeping the buzzer on all the time. Pulsing the output say every one second you get 0.1second beep, that brings down the current consumption by 90%, so comes down the energy storage requirement by 90%, as comes down the weight and price. This way 5V 3.3F supercap can hold energy close to 2 hours, and weighs 3grams. You have perfect circuit for this on my post #15, just convert it tiny bit for this purpose, like this:

Edit: super cap 3$, buzzer 1,8$, 4060 0,4$, rest of the parts <1$, total ~6$, energy storage is ~50% of your parts in this case. The mandatory expenses are buzzer and few external parts which you cant avoid. As you see, the energy storage will sky rocket your expenses if you try to multiply the capacity.. It also will blow your weight and space needed. You can source parts cheaper, these are just list prices from Mouser. Total weight ~5grams, charge cycles 500k, lasts forever without ever needing to worry about batteries. Works with 1-6 cell LiPo-batteries without any modifications.

1630229563958.png
 
Last edited:
Top