Created by: Richard Laborde
This PIC IoT project turns a fan on and off based on a temperature sensor. Here it is in action:
To use the Relay Click you have to enable the 5Vdc supply to the mikroBUS connector. There are pads next to the connector at R204- an unpopulated 0 ohm resistor. You need to connect those two pads to enable the 5Vdc supply to the Click. My soldering skills are poor enough that it was easy to get a little blob of solder to bridge the pads.
Next, we can solder wires onto the output of the fan on/off switch. By doing this we can bypass the power switch on the fan and run the power to the fan through the terminals on the Relay Click. Now with the switch on the fan off, the fan will be off when the relay is off and will turn on when the relay turns on.
We want the setpoint of the temperature to be adjustable from the Cloud. This way we don’t have to change the code on the PIC itself once it is deployed if we decide we need to modify the setpoint.
This project also features cloud functions to display data on a dashboard:
Here is the project file, which you can import in Atmosphere studio to try out yourself: Click here to download the .atmo zip