Active buzzer module with TinkerPie
A second, louder beeper for alarms.
| Type | Outputs and actuators |
|---|---|
| Connect to | any accessory pin |
| Gives | a loud beep |
| Simulator | Yes: a control appears under the simulated board |
How it works
An active buzzer has its own little oscillator inside, so it beeps as soon as it gets power. The board just switches it on and off, which makes it simple and loud.
How to wire it
Signal pin to S1-S4 or P10-P13. Motors, pumps and lamps always go through the relay or a driver module, never straight to a pin.
Code
In blocks: Accessories category in TinkerPie Studio. As code:
// JavaScript
outputs.buzzerModule(Pin.S1, true)
// Arduino C++
outputs::buzzerModule(Pin::S1, true) Good to know
- It plays one fixed note; for melodies use the board buzzer or a passive buzzer.
- Short beeps are kinder to ears in a classroom.
- Any accessory pin works.
Similar modules
- Relay module
- LED module
- Traffic light module
- Laser module
- DC fan / motor module (with transistor)
- 16-channel servo driver PCA9685
More projects to try
Questions
Can I try the Active buzzer module without buying one?
Yes. In TinkerPie Studio the simulator shows a control for it under the board, so you can test your program before you build it.
Can the active buzzer play a song?
Not really: it only makes its one built-in tone. Use the TinkerPie board buzzer (Music blocks) for melodies.