This shows you the differences between two versions of the page.
iothings:proiecte:2021:alexa-system [2022/01/23 19:23] adriana.ionita2404 |
iothings:proiecte:2021:alexa-system [2022/01/27 02:35] (current) adriana.ionita2404 |
||
---|---|---|---|
Line 3: | Line 3: | ||
Adriana Ionita - AAC \\ | Adriana Ionita - AAC \\ | ||
E-mail: adriana.ionita2404@stud.acs.upb.ro | E-mail: adriana.ionita2404@stud.acs.upb.ro | ||
+ | |||
+ | {{ :iothings:proiecte:2021:alexa_intro.jpg?500 |}} | ||
+ | |||
==== Description ==== | ==== Description ==== | ||
Line 13: | Line 16: | ||
* ESP32 WROOM | * ESP32 WROOM | ||
* 12V Fan | * 12V Fan | ||
- | * 12V Power Adapter | + | * 12V Power Supply |
* 12V Power Adapter Jack | * 12V Power Adapter Jack | ||
* Relay Module | * Relay Module | ||
Line 22: | Line 25: | ||
The ESP32 represents the core of the system. It controls the other components and also enables the network connectivity for the project. Because the fan requires 12V to function, I used a 12 power adapter which can be plugged intro a socket and a dedicated jack to accommodate the other end of the adapter. The relay module is needed in order to power the fan on and off. The DHT11 module is used for its temperature sensor. The idea behind this is that the fan should go on only if the temperature goes over a certain value, hence the need to read the temperature. The LEDs and the resistors are used for the lights of the system. | The ESP32 represents the core of the system. It controls the other components and also enables the network connectivity for the project. Because the fan requires 12V to function, I used a 12 power adapter which can be plugged intro a socket and a dedicated jack to accommodate the other end of the adapter. The relay module is needed in order to power the fan on and off. The DHT11 module is used for its temperature sensor. The idea behind this is that the fan should go on only if the temperature goes over a certain value, hence the need to read the temperature. The LEDs and the resistors are used for the lights of the system. | ||
- | {{https://ocw.cs.pub.ro/courses/_media/iothings/proiecte/2021/alexa_hardware_diagram.png?800}} | + | {{https://ocw.cs.pub.ro/courses/_media/iothings/proiecte/2021/alexa_hardware_diagram.png?700}} |
It's important to note that the temperature sensor has been connected and integrated in a low-power manner. Instead of having it connected to a Vcc pin, case in which it would have provided data continuously, it has the Vcc pin connected to a digital pin. By doing this, it's possible to turn it on/off in order to save power. | It's important to note that the temperature sensor has been connected and integrated in a low-power manner. Instead of having it connected to a Vcc pin, case in which it would have provided data continuously, it has the Vcc pin connected to a digital pin. By doing this, it's possible to turn it on/off in order to save power. | ||
Line 43: | Line 46: | ||
==== Final result ==== | ==== Final result ==== | ||
+ | |||
+ | === Hardware setup === | ||
The project has been successfully implemented and set in position: | The project has been successfully implemented and set in position: | ||
- | <TODO: add images> | + | {{https://ocw.cs.pub.ro/courses/_media/iothings/proiecte/2021/alexa_hw_1.jpg?600}} |
+ | |||
+ | Some wires were hidden to try to make it look nicer: | ||
+ | |||
+ | {{https://ocw.cs.pub.ro/courses/_media/iothings/proiecte/2021/alexa_hw_2.jpg?600}} | ||
+ | |||
+ | Good thing it's all covered up :) | ||
+ | |||
+ | {{https://ocw.cs.pub.ro/courses/_media/iothings/proiecte/2021/alexa_hw_3.jpg?600}} | ||
+ | |||
+ | === WiFi Light & WiFi Fan registration === | ||
+ | |||
+ | In order to get started, the devices have to be registered using the Alexa App: | ||
+ | |||
+ | {{https://ocw.cs.pub.ro/courses/_media/iothings/proiecte/2021/alexa_setup_devices.png?600}} | ||
- | It has been tested and it works properly with both the Alexa App and the Echo Dot. | + | After the registration is complete, the 2 devices will be available in the "Lights" section of the application under the names "WiFi Light" and "WiFi Fan". From there they can be controlled with Alexa. |
- | <TODO: add images> | + | === WiFi Light usage === |
The Alexa library for Arduino is designed especially for lights. So using it to control the lights of this project was pretty straight forward because it implied to use this library as intended. Functionality for the lights include turning lights on/off, setting the brightness and setting the color: | The Alexa library for Arduino is designed especially for lights. So using it to control the lights of this project was pretty straight forward because it implied to use this library as intended. Functionality for the lights include turning lights on/off, setting the brightness and setting the color: | ||
Line 56: | Line 75: | ||
* using the Alexa App installed on my phone. | * using the Alexa App installed on my phone. | ||
- | <TODO: add images> | + | {{https://ocw.cs.pub.ro/courses/_media/iothings/proiecte/2021/alexa_light.png?600}} |
+ | |||
+ | === WiFi Fan usage === | ||
For the fan on the other hand, I had to adapt these mechanisms available for lights to obtain the functionality I needed. Also, the fan is tightly dependent on the temperature sensor. So this is the behaviour for the fan and the sensor: | For the fan on the other hand, I had to adapt these mechanisms available for lights to obtain the functionality I needed. Also, the fan is tightly dependent on the temperature sensor. So this is the behaviour for the fan and the sensor: | ||
Line 69: | Line 90: | ||
* Any other colour: always off, regardless of the temperature | * Any other colour: always off, regardless of the temperature | ||
- | <TODO: add images> | + | {{https://ocw.cs.pub.ro/courses/_media/iothings/proiecte/2021/alexa_fan.png?600}} |
+ | |||
+ | === Demo === | ||
The functionality of the project is also demonstrated in the video below: | The functionality of the project is also demonstrated in the video below: | ||
- | <TODO: add video> | + | [[https://youtu.be/dYg_C0Q1hfU|{{https://ocw.cs.pub.ro/courses/_media/iothings/proiecte/2021/alexa_thumbnail.jpg?600|}}]] |
==== Resources ==== | ==== Resources ==== |