This project is simple just by using temperature sensor LM35 with arduino to control a DC fan(motor) and LED with respect to the temperature.
1. INTEL EDISON
2. Temperature Sensor LM35
3. 1K Resistor
4. Diode 1N4007
5. Dc Motor
6. NPN transistor BC547
7. A voltage source with 12Volts
9. hook up wires
10. optional : voltage source socket
STEPS TO BE FOLLOWED:
Step 1: ARDUINO BOARD WITH INTEL EDISON
Configure your arduino board with intel edison.Look at this link to configure ( https://software.intel.com/en-us/iot/library/edison-getting-started ).
Make sure your serial communiction and port are fixed. Check out your arduino board with intel edison by loading a simple program to your board.
Step 2: BREADBOARD CONNECTION
The NPN transistor BC547 here as a buffer to isolate the first circuit which is the connection to the arduino through the resistor and the other one with the fan(motor).
An inverted PN-junction parallel to the fan to prevent moving current in the opposite direction and make damage to the arduino kit.
Below image shows some of components:
step 3: CIRCUIT DIAGRAM
Step 4: VOLTAGE SOURCE
It is important to put in consideration that the input voltage for the temp sensor is 5v from the arduino.
12volt voltage given to the motor or fan must be from an external voltage source.
In this case we connect all the GND together weather the GND of the arduino and the external voltage source.
Step 5: TEMPERATURE SENSOR LM35
It’s a transducer. It converts temperature into equivalent electrical signal. Its output voltage increases linearly with increase in temperature.
The LM35 datasheet specifies that this ICs are precision integrated-circuit temperature sensors, whose output voltage is linearly proportional to the Celsius (Centigrade) temperature.
The output voltage of the sensor is fed to the A/D channel of the arduino.
Several temperature ranges was set in the code to vary the motor speed based on the level of temperature sensed.
Step 6: DC MOTOR
Take a normal dc motor and connect to pin 9 of arduino and ground it.
Step 7: CODING AND EXECUTION:
int tempPin = 0;
int tempMin = 25;
int tempMax = 32;
int led = 8;
int fan = 9;
int fanSpeed = 0;
temp = analogRead(tempPin);
temp = temp * 0.48828125;
Serial.print(“TEMPRATURE = “);
if(temp > tempMax)
fanSpeed = map(temp, tempMin, tempMax, 32, 255);
fanSpeed = 0;
Here is the video