Hello everyone I am trying to get the sensor value from Serial Monitor of Arduino IDE to PLX-DAQ software. I am getting the time value , but NOT the value of sensor reading . Here is the code I am using
int led=4;
int sensor=A0;
int threshold=90;
void setup() {
pinMode(4,OUTPUT);
pinMode(A0,INPUT);
Serial.begin(9600);
Serial.println("CLEARDATA");
Serial.println("LABEL,Time,value");
Serial.println("RESETTIMER");
}
void loop() {
int value=analogRead(sensor);
Serial.println("DATA,TIMER");
Serial.println(value);
Serial.println(',');
if (value>=threshold)
{
digitalWrite(4, HIGH);
delay(100);
}
else
digitalWrite(4, LOW);
delay(100);
}
And the output on the excel I am getting
Please help