This week's idea is a Arduino controlled circuit with buzzer, RGB LED and temperature sensor (LM35).
The sensor reads the temperature and based on the reading the RGB LED will show specific color, green if below 25, blue if above 25 till 30 and red if above 30. Also, the buzzer will make sound if the temperature above 25 and higher sound if above 30.
I do care about this specific idea as I will use it in my final project + other components.
However this idea is my own inspiration I used this project as reference. (I wanted to add LCD to this week's project but the code was very confusing so, I decided to use it at later stage of the diploma).
I used Tinkercad to simulate the circuit. (explained in Week 5 - Journal).
male to male jumpers.
I used Arduino IDE software to compile and upload the code into the Arduino board.
I started by designing the circuit on Tinkercad.
I followed the same process to design and test the circuit like week5 .
The only difference was the blocks part to control Arduino in Tinkercad.
The code do the following:
The temperature sensor checks the current temperature and based on the result the RGB turns red or green or blue.
If above 30 RGB will be red and buzzer will be on highest sound, between 25 and 30 blue with little sound below 25 green with no sound.
In order to this I used if conditions:
If the temperature is above 30 do the following, else, I added another if to check the temperature again if it is between 25 and 30 and if not the last else to turn the green light on.
I wired all components on the breadboard since it is easier than connecting all components to the Arduino itself.
I followed the same wiring I did in Tinkercad in order to make sure it will work without any issue.
Wired the rail parts of the breadboard to the GND and 5v pins on Arduino then I wired all components accordingly exactly as Tinkercad.
I copied the code from Tinkercad and pasted it to Arduino IDE.
I connected the Arduino board to my PC via USB after wiring all components and from Arduino IDE I chose the upload button and the magic happened.
During end of week session exercise my teammate forgot the map function that helps convert from o:1023 range to 0:255 range.
I explained it to him rapidly and we started to do the exercise and we managed to finish it on time.
The initial idea was LCD showing temperature, I used Google.com to search and understand how LCD works.
I found this mini tutorial and it helped me to understand how LCD works.
I used Google to search for LM35 temperature sensor code and I used this link as reference.
While building my circuit I changed the polarity of the sensor, connected the positive with ground and the ground with positive.
The temperature reading was above 200, I wanted to check that everything is correct so, I decided to touch the sensor and yes you got it right my finger burned. (a small burn and I did the first aid so not big deal).
Also, I wired the RGB GND to the wrong slot in the breadboard and I spent like 15 minutes wondering why the RGD didn't work, I even changed it with no avail.
LM35DZ temperature sensor
My final project idea is mainly big part of this week assignment therefore, I can say that I finished part of my final project successfully :D <3.
Completing the EoW session's exercise successfully on time with all requirements met however this is my first time to do such thing.
However I started the Monday session a little bit late and the hands on minds on activity was near to end I decided to try to do the activity and I did it successfully in almost no time.