Hello world of arduino and beyond!
We are trying to use flexiforce pressure sensor but we have come into quite a pickle. Our circuit is fine. It is standard of what you would normally find online when looking it up. One pin of the flexiforce sensor goes to 5V another to a 1 mega ohm resistor that goes to GND, in parallel to pin A0. We have the circuit and it doesnt seem to be the problem. We just need a code. We went on all of the sites like parallaax and sparkfun and every code is virtually the same. When we upload the codes the serial monitor reads very odd results that are extremely random and vary (they can be anywhere from 267 to 327 without us touching it)and when pressure is placed on the sensor it doess not react. Maybe its our circuit i'm not certain but we need help. Could anyone help us with our codes and circuits?
this is a code we got from some website we're not sure of but its not working. PLEASE HELP
// Flexiforce quick start example
// Reads A0 every 100ms and sends voltage value over serial
// Start serial at 9600 baud
// Read the input on analog pin 0:
int sensorValue = analogRead(A0);
// Convert the analog reading (which goes from 0 - 1023) to a voltage (0 - 5V):
float voltage = sensorValue * (5.0 / 1023.0);
// Print out the value you read:
// Wait 100 milliseconds