Back to Parent

Outcome


Problem Statement 

 I currently live alone in Pittsburgh, but I lived with my best friend, Ariel, for the past few years in Albuquerque. She has suffered from insomnia since she was 14. She is now 25 and has more natural sleep patters, but still can be woken up or kept awake throughout the night by quiet noises, movement, temperature change, etc. The appliance I am designing is a temperature sensor that will start a fan if the temperature rises above a specified ‘comfortable’ temperature. Ariel would greatly benefit from this appliance because temperature would be one less annoyance that would wake her up or keep her awake at night. She could ideally sleep through the night with a comfortable temperature decided by her. I choose to design this IoT appliance for Ariel because I have seen how difficult it is for her to function efficiently after having a horrible night of sleep. 

Goal

The goal for this appliance is that it will sense the temperature of Ariel’s bedroom and once it rises above a specific temperature that Ariel will decide is the threshold for when her room gets to hot to sleep comfortably, a fan will automatically turn on to cool the room down. 

Process

Description: Macintosh HD:Users:christianbaca:Downloads:IMG_4078.JPG

The basics needed for this appliance to work are a temperature sensor and a fan. Since attaching a fan would be above my current skill set, the components used are a temperature sensor, a LED, and a piezo buzzer. The LED and piezo buzzer go off when the fan would start in the real scenario.

For the code, I started with the sample code in the tutorials for the temperature sensor and the LED. In the beginning, I was completely lost on the coding aspect of this project. I went to office hours and Joseph explained to me that there can only be one void setup and one void loop for an entire code. After office hours, I was able to condense my code into one void setup and one void loop and write the simple code to have the LED and piezo buzzer turn on when the temperature was above 73 degrees.

Outcome 

The fact that the code made the breadboard do what it was supposed to do was a huge success for me. This hack is far from complete. Future steps for completion are to hook it up to a fan instead of the outputs being an LED and a buzzer. Furthermore, it would be beneficial for the temperature sensor to continue sensing the temperature in the room and once it drops below a specified temperature, the fan would turn back off. 


Bill of Materials:

Breadboard

Particle Microcontroller

Jumper Wires

DS18B20 Temperature Sensor

4.7 kOhm Resistor

10 kOhm Resistor

Piezo Buzzer 

LED


The code, circuit diagram, and link to the video of the breadboard in action are shown below.  


Show Advanced Options
Temperature sensor bb
Show Advanced Options
Show Advanced Options

Reflection

Dealing with circuits and code is far from a normal activity for me, I found myself lost for the majority of the project. It is also one of those subject where if you get stuck, there is a chance you will not be able to solve the problem on your own, which is frustrating and hinders the completion of the project in a timely manner. Once Joseph explained more about the code to me, I had a breakthrough. Having my circuit work after fixing my own code was exciting. I'm looking forward to more breakthroughs and have a goal of learning how to troubleshoot my own circuit and code problems in the future. 

Drop files here or click to select

You can upload files of up to 20MB using this form.