My Inspiration Component.
I get inspired from previous assignment that I utilized in most of them buzer component. So I decided to implement a circuit with buzzer and one LED as two action components. I will use random function to generate a value between 0 and 255 for being written on buzzer and LED each time I press a button between 1 and 5 on Android App. When press 0 the buzzer and LED will turn off.
Bluetooth Module
Buzzer
Breadboard to wire all components together.
Resistor for LED to get suitable power.
LED.
Circuit mind. Arduino.
Wiring
Uploading code on Arduino.
- The circuit has 2 action component (1 Buzzer) && (1 LED).
- The circuit input component is the HC-05 Bluetooth module that controlled via Android Bluetooth Control App.
- The breadboard will connect components with Arduino.
- The circuit scenario.
* When pressing a button on App with number from 1-5 the buzzer and LED will play on analog mode with a value from 0-255.
* I am using a random function to generate a value between 0-255 to light/play LED/Buzzer every time differently.
* When pressing button a button on App with number 0 the buzzer and LED turn off.
- Making wiring for LED with both breadboard and Arduino.
- Adding buzzer and making wiring for it within breadboard and Arduino.
- Adding code to generate a random value to play a sound on buzzer and light LED with control from Android App and when 1-5 number getting pressed.
- Adding code to turn off buzzer and LED with control from Android App and when 0 number getting pressed.
- The setup part contains my declaration for used components to use it with Arduino for both input (LED & Buzzer).
-- Within logic part I read serial data received via Bluetooth connection between Bluetooth module and Android app which sen data.
- If received data in (1,2,3,4,5) I will light LEd and play buzzer with a random analog value generated using Random function from Arduino.
- If receive data is 0 I will turn off both LED and buzzer.
Android App screen.
The circuit wiring was simple but while wiring the circuit I tried to wire all components plus Arduino on a shared GND within breadboard but the circuit did not work. I tried then to using Arduino GND and wire each component to one of GND pins on Arduino. It works well.
This wiring scenario did not work,
The Working scenario.
Getting familiar with designing and programming circuits will be very useful in designing successful circuits for my project.
Over time within the diploma I feel we get more tools and control that can be utilized in many applications. I feel I have a big box full of tools and I need more practices to utilize each of box components efficiently.
Title of Media