Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [buzzer]

The tag has no usage guidance.

0
votes
3answers
48 views

Passive buzzer works with analogWrite(), but not with digitalWrite(). It also has constant static noise

I have a YL-44/MH-FMD passive piezo buzzer hooked up to an ESP8266/NodeMCU. It's connected like this: Buzzer ---> NodeMCU - GND ---> G - VCC ---> 3V - I/O ---> D2 This code makes a clear beep. ...
0
votes
2answers
27 views

Won't break out of for loop

I'm new to Arduino and I'm trying to use PWM to generate a tone through a buzzer. I've created a for loop, however, the for loop doesn't seem to break when the variable ms is < 1000000. int ...
0
votes
4answers
62 views

help with a loop

I recently got into programing and I'm making an alarm. I cant figure out how to make a buzzer loop. I have two blinking LED's and two fading ones. Now I plan to have sound and it won't work. It only ...
0
votes
1answer
108 views

Arduino - Playing WAV files with a buzzer

I have developed an Arduino program that plays a WAV file from the SD card using a speaker. This is the circuit schematic The sketch I'm using is based on TMRpcm library and PWM output #include <...
1
vote
2answers
64 views

How can you have two blinking leds and a fading one

I am trying to make a alarm and I have two blinking leds (red and blue). They work fine but I want two more that fade in and out. I have a buzzer on it too. I am very new to programming. By the way, ...
1
vote
1answer
46 views

How to detect when intercom is ringing?

For my apartment, I need to check when intercom is ringing and call an API in that case. I was thinking about using an AC input / DC output relay, since the buzzer signal is an AC signal. Is there an ...
0
votes
1answer
28 views

everything works independitly but not together. Piezo not generating a tone

My goal with the code is simple. Let the Piezo buzz when temperature reaches 25 degrees. My piezo is hooked up correctly, because It makes a buzz when the arduino boots or when I put this line of code ...
0
votes
1answer
42 views

Arduino - Push Button State Problem

My problem is I want the buzzer to stop after a certain amount of time, regardless if it is still pressed or not. I have tried to implement a boolean statement to the code but to no avail(I'm not ...
1
vote
2answers
258 views

Stop Arduino Timer after some seconds

I'm building a basic program that when a button is pressed, a buzzer comes on. I would like however to make it so that the buzzer stops after a short period of time (e.g. 5-7 seconds). Here is the ...
0
votes
3answers
1k views

Is there a way to play .mp3 files from an SD card on Arduino?

Is there a way to have mp3 files on an SD card in the SD card shield for the Arduino and play an mp3 file on that SD card with a buzzer? If possible also with something like: playmp3(thismp3.mp3); ...
0
votes
1answer
75 views

Joysitck with servo, LED array and buzzer [closed]

Does anybody know of a sketch that can turn a single servo 180 degrees clockwise/counterclockwise with the x axis of a joystick, light a bar graph LED with the Y axis, and sound a buzzer when the ...
3
votes
5answers
484 views

Emergency Vehicle - Make two LEDs flash with buttons and a passive buzzer change sound

My Dad and I are just learning how to use my new UNO. We have learned how to make leds flash at the touch of a button. We have also learned how to make a passive buzzer sound at the touch of a ...
1
vote
2answers
43 views

How do I create a constant loop with an event that only occurs once?

I am currently working in void loop() and have setup a distance meter that constantly checks the distance. Once the distance threshold is met, a function is called. Now I only need this function to ...
0
votes
3answers
417 views

How can I loop for a set amount of time when a condition is met?

I'm trying to create an Arduino project with a light sensor and a buzzer. The idea is that when the sensor detects that the lights have gone off, the buzzer will sound for 5 seconds. At some point, ...
0
votes
1answer
134 views

What is wrong with my state machines?

My goal is to make an automatic gate and garage door, and it has a servo as the lock mechanism on the gate, and alarm systems that notify when the gate or garage door is open too long, more than the ...
0
votes
1answer
168 views

Execute function until called again?

I am building a simple security system with my Arduino Uno. I have an alarm() function: void alarm() { tone(8, 3300, 200); delay(200); tone(8, 3000, 200); delay(200); } When I call it in the ...
0
votes
1answer
1k views

How do I make specific tones with a piezo buzzer?

I am using a piezo buzzer and fiddling around with it a little bit. I currently have different tones with delays in between and I have to do a lot of trial and error for the piezo buzzer to play ...
0
votes
2answers
1k views

Start/Stop/Reset the melody using buttons

I have 2 buttons. Button 1 will start/stop the melody while the button 2 will reset the melody. My melody is "Happy Birthday". How am I going to use the buttons to start/stop/reset the melody? Here'...
0
votes
1answer
184 views

Need to filter low voltage from a piezo buzzer circuit [closed]

I have a 6-28VDC piezo buzzer I'm using at 24VDC. The line has 3-4 VDC when the output is off, which has a soft but annoying buzzer constantly. What the the easiest way to filter that out so I only ...
1
vote
2answers
692 views

Adding external power supply to any arduino connected component

I have an Arduino Pro Mini 3.3v and the voltage is too small for my buzzer to ring loudly. I want to add a 9v battery to power the buzzer. This is my current circuit: Arduino (pin 9) => Buzzer +ve ...
1
vote
1answer
654 views

Controlling buzzer with assembly

I want to make a piezo buffer beeping with assembly code, but i haven't managed to yet. I have an Arduino UNO board (ATMega328p) and using avra and avrdude to build and load. The buzzer just stay ...
2
votes
3answers
4k views

Circuit with buzzer not working :(

so I have a circuit with a buzzer and a resistor: This circuit should be working, but for some reason the buzzer doesn't sound. I pushed the buzzer into the breadboard as hard as I could, I put the + ...
-1
votes
1answer
335 views

Error when using buzzer and IR sensor

I am doing code for IR sensor. My problem is when I put this code (below) for buzzer, there will be error. C:\Program Files\Arduino\hardware\arduino\avr\cores\arduino/Tone.cpp:536: multiple ...
-1
votes
2answers
416 views

What would be the code for using Arduino UNO to alert by sound or LED when it detects a certain position through GPS?

I am in grade 6. I have a very nice pet dog in my house but it often enters Mom's kitchen to spoil all the foods. So I am thinking of a device to attach with him which can locate its position. But I ...
0
votes
2answers
590 views

Signal pin of buzzer is connected with which Arduino uno pin

I bought a 3 pin buzzer. It has positive, negative and signal pin. I don't understand how this signal pin should be connected with the Arduino. Here is reported the description page of the buzzer.
-1
votes
1answer
81 views

How to use TimerOne while calculating time?

I'm trying to get warning with buzzer while I get same values on 3 seconds. But first warning doesn't wait 3 seconds. Second warning is correct. Code is attached. BlinkLED1() method is same BlinkLED2. ...
1
vote
1answer
149 views

Using Piezzo Electric buzzer 10V with an Arduino Lilypad USB

I bought a 10 V Piezzo electric buzzer and I wonder how to connect it to an Arduino (in my case a Lilypad USB, but the question stands for any Arduino I guess...). I hadn't realized this was a 10V ...
0
votes
2answers
4k views

Drive 12V Piezo Buzzer (Arduino)

I want to drive this 12V piezo buzzer: http://www.conrad.com/ce/en/product/130256/Kemo-L001-High-Freqeuncy-Piezo-Speaker-Component-12-24-V This is the circuit I am using. The Arduino is powered by a ...