This week my assignment idea is to communicate wirelessly with a Smart Circuit via a Graphical User Interface that contains at least TWO action components.
I used fritzing to design my electronic circuit,
Then I used Arduino IDE for coding.
And I made the actions with the mobile app (Arduino Bluetooth Control).
Tools:
Arduino Uno
Breadboard
Wires
Resistors 220 ohm
Bluetooth Module
Buzzer
RGB LED (common cathode)
I used fritzing to design the circuit.
I used Arduino IDE to communicate with the Arduino UNO board and give it instructions.
I started by using fritzing to design and make sure that everything was ok.
I connected Bluetooth Module with Arduino on RX & TX and the other pins with ground & 5v on breadboard.
I connected the buzzer with Arduino on pin 7 & the other terminal on GND.
I connected RGB LED with Arduino on pins 2,3&4 with resistor 220 ohm and cathode terminal on GND.
I started with defining all pins on Arduino
RGB LED on 2, 3 & 4
Buzzer on 7
Then I define all pins as output in void setup.
In void loop, I used if condition as:
if the incoming data 1; it will be Red light.
if the incoming data 2; it will be Green light.
if the incoming data 3; it will be Blue light.
if the incoming data 4; it will be White light.
else; the Buzzer works
I used the same components that I used on fritzing.
I connected Bluetooth Module with Arduino & breadboard, connected RGB LED with resistors 220 ohm & with Arduino, connected buzzer with Arduino & breadboard.
Finally I uploaded the code.
The red LED in the RGB was not working so I just modified its condition to basically do nothing. I also seeked some help from my friend Belal to check the code with me.