Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Need a short beep circuit

Status
Not open for further replies.
The speaker output seems okay, but if I want to boost it, would I use a transistor? I have three to choose from: 2N2222, 2N3904 and 2N4401. Is there a difference?

It depends on how much output power you want and the tone quality. You could make a simple amp with 2 transistors, but the quality may not be adequate. See below.

And, if I want the second note to fade out instead of stopping abruptly, is that difficult to add in?

It should not be too dificult. I'll put some thought into it.
Does your parts supplier sell a cheap audio amp IC?

For an example, see the one at the JayCar site **broken link removed**

Search for ZL-3600 and download the data sheet.

They have a mail order outlet in the US and their web site has a Canadian option which gives you the price in $CAD.
 

The attachment shows 2 options for the tone decay.

Do you prefer the first or the second?

I assume you want the tone to decay in volume, not in frequency. Is that correct?
 

Attachments

  • Tone options.jpg
    Tone options.jpg
    46.2 KB · Views: 54

I'll check with my supplier tomorrow for the ZL-3600, or other audio amp IC. It's too bad they don't have their inventory online so I could plan out what I want to buy.

You're correct, I'd want the second tone to decay in volume, so it has a natural fade sound to it like a bell. It's not a big deal if it don't include it, just if it was something simple to add in, it would be a neat effect. If I add too many things in, I'll forever add on to it and the next thing you know, I'll have a full blown security alarm with remote audio/video and fingerprint ID to arm and disarm it. Meanwhile, the coffee shop where it's going will just use one of those 'hotel bells' with a sign that says "Ring for Service" :)
 

The ZL-3600 is the JayCar catalogue number.

The IC number is TDA 1905. It is a 5 Watt Amplifier with mute.

JayCar also sell a LM380 amp, but it may not suitable since it needs a supply of at least 10 Volt, whereas the TDA operates on less. What voltage power supply are you going to use?

You did not answer my question re which option you prefer.

To do the fade, you will need a 74HC4052 or the 4000 series equivalent CD4052 and the Audio amp.

It is relatively easy to do. So I'll scribble out a circuit later.

You will also need a PNP transistor such as:-

BC557. BC557, BC558, BC559, BC327, BC328, 2N3906 or similar.

Virtually any small signal transistor will suffice. The ones you quoted in an earlier post are all NPN.
 
Last edited:

My apologies, I prefer the first option, with the volume fading after the 1 second tone. It can be a fairly quick fade, too. Just something to smooth out the end of it.

My wall wart outputs 12v, so I can use that for the amplifier.

Which would be preferable, the TDA 1905 or LM380? And, between the 74HC4052 and CD4052?
 

i dont see whats wrong with using a pic508 3 caps and three resistors

pwm driven tone and the res and cap used on its i/os to get sine wave...
it has 6 i/os so you can add a pair for some sort of controls as 2 bit bin select or 3bit pin select
if you add a pulse code routine you can fade the tone out by incremental redaction and intraction
of pulse width this add non linearity to the pulse dependant on a division of the frequency

so for 1000hz you would redact it by 25% {lots of small 1khz pulse leading to a big one followed by lots of small ones in a radaction }

very simple code!

you can program a 508 or any pic with ic prog and just rs232 port alone
so... and free compilers are there for this task
any comercial one will allow for small code or free use for this small vcheep ic
i think less than 7 lines of code is needed
amplify it using a standard LM386.. for 1.5watt or a single 2n2955
or some other audio ic prefered is
one that needs no external components


sorry i just dont see the point these days in 555 and bloated cmos and ttl / passive
afterall there is only one mountain in CA to get the right stuff from to make ic's
if people keep designing **** ttl cmos crap then they use ic's this uses the resorce
and it isnt avalible
these ic's should be bound in law to prohibit new design

even for personal use
its just too impactive on future needs for silicate ... quartz
8)
 
Last edited:

My apologies, I prefer the first option, with the volume fading after the 1 second tone. It can be a fairly quick fade, too. Just something to smooth out the end of it.
You will be able to select the timing yourself by changing C * and/or R.

My wall wart outputs 12v, so I can use that for the amplifier. yes, that will be adequate.

Which would be preferable, the TDA 1905 or LM380? And, between the 74HC4052 and CD4052?
There is no particular advantage in choosing one or the other in this case. Either will do. Decide upon price & availability. If they don't have either, ask about the CD4066 & 74HC4066. These are les convenient, but I can design around it.

The LM 380 is sligthly simpler, but either would do. See what your supplier has & if they don't have either, ask what they recommend. All you need is a simple low power amp. If in doubt, let me know.

I think you may have missed the edit to my last post as you have not mentioned the transistor question.

---------- Post added at 06:33 ---------- Previous post was at 06:26 ----------

i dont see whats wrong with using a pic508 3 caps and three resistors

pwm driven tone and the res and cap used on its i/os to get sine wave...
it has 6 i/os so you can add a pair for some sort of controls as 2 bit bin select or 3bit pin select

you can program a 508 or any pic with ic prog and just rs232 port alone
so... and free compilers are there for this task
any comercial one will allow for small code or free use for this small vcheep ic
i think less than 7 lines of code is needed
amplify it using a standard LM386.. for 1.5watt or a single 2n2955
or some other audio ic prefered is
one that needs no external components


sorry i just dont see the point these days in 555 and bloated cmos and ttl / passive

8)
He answered this in a previous post. He wants to learn about logic gates, etc.

If I was doing it for myself, I would also use a PIC.

Besides, sometimes you need logic with a PIC to help it out.
 

then read a BOOK!

if you need to add logic ic's to a mcu design
you are a weak programmer
 

I think you may have missed the edit to my last post as you have not mentioned the transistor question.
I have no PNP transistors, but I can easily pick some up as well.

If I was doing it for myself, I would also use a PIC.
If I was starting this from the beginning, I would probably use a PIC as well, from what I've briefly read about them. I'm not sure where I would even start with something like that.
 

then read a BOOK!

if you need to add logic ic's to a mcu design
you are a weak programmer

You're making assumptions.

Some years ago I designed a digital oscillscope. I used PICs & hardware.

I needed the hardware because the PICs that were available then did not have sufficient speed or memory.

So I did the control and timing in hardware and used FIFOs to store the data.
 

I have been away from the board for a long time and a tickler/reminder email brought me in today. And to this thread. I have sampled the thread which started from the OP asking about a 555/556 solution and is now dithering between solutions involving CMOS logic and a uC.

The OP seems happy with discrete electronics and, though I am an embedded software guy, I will, for the most part, stay the OP.

Whether the final solution involves the original 555/556 approach, discrete CMOS/TTL logic, a uC w/software or another approach, I think a 'systems approach' may be useful. No matter which solution is used, there are some common requirements: the 1 kHz 'beep', that the 'beep' is to drive a speaker loud enough to be heard from some distance, that the OP wants three beeps within 1 second and that there is a trigger condition, which may or may not reset itself before or after the 'beeps'. These common requirements form functional blocks that can be considered independently and, together, as a 'system'.

Into the fray I will add the possibility of using a PLD/FPGA solution (admittedly with issues with supply voltages). Though I do not have an actual solution at hand I will suggest that the PLD/FPGA approach could give the OP experience with logic gates and would bring in VHDL or Verilog etc.

Back to the functional blocks: For the first, a 1 kHz relaxation oscillator can be fashioned from one or two transistors, one of which could also drive the speaker. (Has anyone mentioned the common 'sonalert' type of sounders?). A 555 can be used for the oscillator as well. (see below). And in either case, another transistor may be required as a hold-off control on this circuit. The hold-off would normally keep the oscillator from operating and sounding and when 'released' would enable the 'beep'. (see below).

But before working on the oscillator/output circuit above lets consider the other requirements as something may fall out of these that may provide another option for the oscillator. I am thinking that a discrete logic circuit that provides the three beeps in quick succession may involve a clock that can be used for the 1kHz 'beep'. Unless a uC is involved, the 'system' clock does not have to be fast and can actually be around 1 to 2 kHz. One can find many RC/inverter CMOS oscillator circuits as well as divider/counter circuits (see post #6).

The last major functional block to consider is the trigger condition, which may or may not reset itself before or after the 'beeps'. I assume that the external condition, e.g. open door/proximity sensor, that triggers the alarm may remain for a time much longer than the alarm, i.e. the three 'beeps'. This means that the the alarm should be sounded once for a given condition, resets when the condition 'goes away' and can be re-triggered if the trigger condition re-appears.

One can find in the 555/556 app notes a 'one-shot' circuit that once triggered will not re-trigger if the trigger condition remains. One can also find 'one-shot' discrete devices around, though some are hard to find compared to days of yore. A conditioning circuit, possibly a simple series capacitor, may be useful to translate the output of the input voltage comparator into a trigger pulse that starts the whole thing off.

And, as I typed the last few words of the last paragraph, I realized that the 'whole thing' is a state-machine. And, lest I venture into another essay, I should stop here and leave the 'state-machine' concept for self-study by interested readers. I will, however, add that for a self-study exercise I explored a state-machine solution in a Kit-Car / Star-Trek style LED flasher in an FPGA using Verilog and a board from Demand Peripherals.

I will also add that for a past employer I designed a circuit using a TLC555 as a 1 Hz oscillator that flashed a LED when the uC was not operating. I used a hold-off transistor and a series cap as described above.

My motivation in writing this was to suggest that systems approach with functional blocks is useful, even for a seemingly simple circuit / application.

Regards.
JVJ
 

Much of what you said doesn't make sense to me. I'm afraid I'm not very knowledgeable to know what FPGA is, other than to Google it and Field-Programmable Gate Array sounds much more complicated than what I'm looking for. In any case, my original need of a 'short beep circuit' has changed during the past couple weeks and instead of going with a beep-beep-beep circuit, I'm liking the high note, low note like a doorbell. The title of this thread isn't a very descriptive title as my needs have changed since then. But I do thank you for your input.
 

Thanks for the input, gate arrays are an interesting thought, but I don't see that they have any advantage over a PIC.

Besides, PICs are relatively cheap and easily obtainable.
 

Agreed. The PLD/FPGA approach may be a bit of an overkill and other than providing an educational aspect does not offer an advantage over a PIC or AVR. (I have worked with both as well as with FPGAs.)

Having said that, the rest of my post was about breaking the application into a series of smaller issues or functional blocks that can be solved or addressed independently.

The new high note/low note requirement changes one of the blocks from a simple oscillator to a two tone oscillator combo and changes the three 'beep' counter/logic block into a two step block, one step for the high note and one step for the low note. The trigger requirement remains the same as does the output block, i.e. a speaker driver.

With a PIC (or AVR) many functional blocks may disappear into the code but these blocks, never-the-less, remain as part of the system. (I believe that the OP wanted to explore discrete circuitry as opposed to using a uC.)

I will continue to give the application some thought and will expand on some of these ideas over the next little while.

Regards. JVJ
 

Thanks for the inputs, I'm interested to know your ideas.

However, note the the OP would like a third state where the second tone fades in volume.

As he put it, he wants a "Ding Donnnnng"
 

I will present my 'ideas' and will leave hands-on to the OP and to other interested readers.

My next contribution follows.

Lets consider the trigger condition first described as an output from a voltage comparator. At one output level (say low) there is no one in the door and at another level (high) someone is going through the door. I will assume that the OP does not want the circuit to re-trigger if a person lingers in the doorway.

The point is that it is not the state (low or high) that one is interested in but rather the change from low to high. A series cap can be used to detect the state change at the output of the comparator and pass it through to the next block as a narrow pulse. This pulse will occur once per entry and can be used as the 'trigger'.

I have used a free spice simulator (LTspice) available from Linear Technology to help determine the value of the series cap used in a similar fashion.

Regards. JVJ
 

You bring up a good point about a person lingering in the doorway. As the dining area of this sandwich shop is limited and it's not uncommon for them to have a line up at lunch time, it's possible that the line extends out the door and a person could continuously trigger the circuit.

@ljcox: Would you be able to add in something so the first note sounds only once for a predetermined length of time and doesn't re-trigger until the sensor is cleared?
 

With this post I am venturing into the realm of ljcox who seems to have the oscillators worked out and a volume decay in the works. And I admit that the following text is a bit behind some of the OP's new requirements, i.e. the volume decay.

The two step tone presents a consideration not present when the application was first discussed. The OP now wants one tone to be enabled for a time and then be replaced with a second tone for a time and then all is quiet until the next cycle. (Setting aside, for now, the volume decay.)

Two discrete oscillators could be used with their outputs connected to a summing stage. Supporting circuitry (TBD) could enable one first oscillator then the other then disable both.

Alternatively a single oscillator could be used with the R of an RC section being variable and changing the frequency as a result. A CMOS switch like the DG417/418/419 or DC4066 can be used to switch one or more resistors in or out of a parallel circuit that forms the R portion of an RC section that determines the frequency of the oscillator. Lets use the notation f0 at RC with R == R1 and f1 at RC with R == R1//R2

Here the supporting circuitry (TBD) would first enable the oscillator and select f1 (high freg tone) for a time and then select f0 (low freq tone) for a time. Then the oscillator would be silenced until the next cycle or trigger pulse.

In either case, the logic is not insignificant. Hence my PLD/FPGA suggestion. Or the uC approach suggested by others. Discrete logic would require a clock that even at frequencies around 1 kHz would require dividers to get it down to somewhere near 1 Hz that would allow stepping through the stages where all is quiet, then one tone is sounding, then the other tone is sounding, then all is quiet again.

Replace the word 'stages' in the last paragraph with the word 'states' and one will see a simple state machine emerge.

In post #12 the OP mentions that one time an Arduino was a consideration. This not a bad option as the Arduino employs a C like language and one does not have to worry about working with assembly code nor with traditional uC C as one would with the PIC and MPLAB. The Arduino could control discrete oscillators and step through the 'state machine' logic described above.

Regards: JVJ.
 

Hi there. The attached BMP belows shows a portion of an LTspice schematic I used to calculate the value of series cap used to pull the edges out of a pulse train, rectify these edges and use the resulting voltage to switch on a transistor. The transistor was used as a hold off switch to prevent a TLC555 from oscillating. The absence of the pulse train would enable the oscillator.

This cct demonstrates how a series cap can detect the edge of a transistion of the comparator. Please note that the values of the components used in the OP's app will be different and that rectifictation my not be required or desired. In the OP's app there will be no pulse train. Instead the OP will want to capture one transition.

Regards. JVJ
 

Attachments

  • 555control.png
    555control.png
    26.5 KB · Views: 59

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top