Space In HIndi

 


Pages

Popular

FSR sensor

 Interfacing FSR sensor with Arduino UNO

Force Sensing Resistors are also known as Force Sensitive Resistors or Force Sensors or just FSRs. 

They are low-cost and easy-to-use sensors specifically designed to detect physical pressure, squeeze, and weight.

 An FSR is nothing but a variable resistor that varies in resistance as pressure is applied to the sensing area. It is made up of several thin flexible layers. 

The more it is pressed, the more resistive carbon elements touch the conductive traces and this reduces resistance.



 FSR sensor Basics: 

When there is no pressure applied on the sensor, sensor look like an infinite resistor. When you pressed harder on the head of then sensor’s resistance will be lower. But as you remove the pressure it will return to its original value.

Notice that the graph is generally linear from 50g and up, but not below 50g. This means that whenever we put pressure on it, its resistance quickly decreases from infinity to 100K, and then becomes more linear.

Calibration of FSR sensor:

When there is no pressure applied on the sensor, sensor look like an infinite resistor. When you pressed harder on the head of then sensor’s resistance will be lower. But as you remove the pressure it will return to its original value.


Notice that the graph is generally linear from 50g and up, but not below 50g. This means that whenever we put pressure on it, its resistance quickly decreases from infinity to 100K, and then becomes more linear.

Calibration of FSR sensor: 

The simple way to read the FSR is to connect the FSR with a fixed value resistor (usually 10kΩ) to create a voltage divider. To do this, you connect one end of the FSR to Power and the other to a pull-down resistor. Then the point between the fixed value pull-down resistor and the variable FSR resistor is connected to the ADC input of an Arduino.

This way you can create a variable voltage output, which can be read by a Arduino ADC input.



Note that the output voltage you measure is the voltage drop across the pull-down resistor, not across the FSR. 

The output of the voltage divider configuration is described by the equation.

Vo = Vcc * R / (R+FSR)

In the shown configuration, the output voltage increases with increasing force. 

For example, with 5V supply and 10K pull-down resistor, when there is no pressure, the FSR resistance is very high (around 10MΩ). This results in the following output voltage.

Vo = 5V * 10KΩ / (10KΩ+10MΩ)

If you press really hard on the FSR, the resistance will go down to roughly 250 Ω. 

This results in the following output voltage.

Vo = 5V * 10KΩ / (10KΩ+250Ω) 

Vo = 4.9V

 Vo = 5V

As you can see, the output voltage varies from 0 to 5V depending on the amount of force applied to the sensor.

 Interfacing of FSR and Arduino UNO:



You need to connect a 10kΩ pull-down resistor in series with the FSR to create a voltage divider circuit. Then the point between the pull-down resistor and the FSR is connected to the A0 ADCnput of an Arduino.

Programming 

Code 1 

This code shows that, read the sensor data from the ADC pin of the Arduino and display the output on the serial monitor. 

int fsrPin = A0; // the FSR and 10K pulldown are connected to a0 

int fsrReading; // the analog reading from the FSR resistor divider 

void setup(void) 

{

    Serial.begin(9600); 

}

 void loop(void) 

{

     fsrReading = analogRead(fsrPin); 

    Serial.print("Analog reading = "); 

    Serial.print(fsrReading); // print the raw analog reading 

    if (fsrReading < 10) 

    {

         Serial.println(" - No pressure"); 

    }

     else if (fsrReading < 200)

    {

 Serial.println(" - Light touch"); 

    

else if (fsrReading < 500) 

{   

 Serial.println(" - Light squeeze"); 

}

else if (fsrReading < 800)

 {

 Serial.println(" - Medium squeeze"); 

}

 else 

{

 Serial.println("- Big squeeze"); 

}

 delay(1000); 

}

 The Output of the above code is as shown below.



No comments: