TEMPERATURE SENSOR TO CONTROL A MOTOR USING INTEL EDISON

SUMMARY:

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.

COMPONENTS NEEDED:

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
8. LED
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.
IMG_0677

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:

IMG_20160524_164251

step 3: CIRCUIT DIAGRAM

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.

IMG_20160519_134633

 
Step 7: CODING AND EXECUTION:

float temp;
int tempPin = 0;
int tempMin = 25;
int tempMax = 32;
int led = 8;
int fan = 9;
int fanSpeed = 0;
void setup()

{
pinMode(led, OUTPUT);
pinMode(tempPin, INPUT);
Serial.begin(9600);

}

void loop()

{

temp = analogRead(tempPin);

temp = temp * 0.48828125;

Serial.print(“TEMPRATURE = “);

Serial.print(temp);

Serial.print(“*C”);

Serial.println();

delay(1000);

if(temp > tempMax)
{
digitalWrite(led, HIGH);
fanSpeed = map(temp, tempMin, tempMax, 32, 255);
analogWrite(fan, fanSpeed);
}
else
{
digitalWrite(led, LOW);
fanSpeed = 0;
digitalWrite(fan, LOW);
}

}

IMG_20160524_131404

Here is the video

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s