Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/mustapha7018/police-siren
A simple police siren simulation with arduino microcontroller
https://github.com/mustapha7018/police-siren
Last synced: about 2 months ago
JSON representation
A simple police siren simulation with arduino microcontroller
- Host: GitHub
- URL: https://github.com/mustapha7018/police-siren
- Owner: Mustapha7018
- Created: 2023-10-18T00:31:54.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2023-10-18T00:49:16.000Z (about 1 year ago)
- Last Synced: 2023-10-18T01:29:17.366Z (about 1 year ago)
- Language: C++
- Size: 0 Bytes
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Arduino Police Siren Project
This is a simple Arduino project that simulates a police siren using an Arduino board. The project uses three components: a red LED, a blue LED, and a piezo buzzer. When the code is uploaded to the Arduino, it creates a siren effect by alternating between the red and blue LEDs while generating a siren sound with the piezo buzzer.
## Components Used
- Red LED: Connected to digital pin 8 (redLED).
- Blue LED: Connected to digital pin 7 (blueLED).
- Piezo Buzzer: Connected to digital pin 6 (buzzerPin).## Installation and Setup
1. Make sure you have the Arduino IDE installed on your computer.
2. Open the Arduino IDE and create a new sketch.
3. Copy and paste the provided Arduino code into your sketch.
4. Connect the components to the specified digital pins on your Arduino board.
5. Verify and upload the sketch to your Arduino board.## Wiring Instructions
- Red LED: Connect the longer leg (anode) to pin 8 and the shorter leg (cathode) to ground through a current-limiting resistor.
- Blue LED: Connect the longer leg (anode) to pin 7 and the shorter leg (cathode) to ground through a current-limiting resistor.
- Piezo Buzzer: Connect one terminal to pin 6 and the other terminal to ground.## Usage
After uploading the code and making the necessary connections, the Arduino will run the police siren simulation. The red and blue LEDs will alternate between on and off states, creating a flashing effect, while the piezo buzzer generates a siren sound.
## Thinkacad Link
https://www.tinkercad.com/things/3pet8bKboqO
## Image
![image](https://github.com/Mustapha7018/Police-Siren/assets/91817013/bdaa7555-5f69-43eb-a5ff-e69a7ad26c3e)