So I am having some trouble with this project even though it seems very simple. I have read multiple tutorials online and I cannot seem to find out what I am doing wrong. I am sure many of you have seen a topic similar to this but it says I should re-create a new topic if the current one is more than 120 days old so here I am. What I want to do is log a change in voltage over a change in time in an excel spreadsheet to be graphed. Currently I am using a photo-resistor and eventually i will being making a salinity probe. Please take a look at my code, am I doing something wrong?:
int val = 0;
int row = 0;
void setup() {
Serial.begin(9600); // the bigger number the better
Serial.println("CLEARDATA"); //clears up any data left from previous projects
Serial.println("LABEL,Time,Data"); //always write LABEL, so excel knows the next things will be the names of the columns (instead of Acolumn you could write Time for instance)
//Serial.println("RESETTIMER"); //resets timer to 0
}
void loop() {
float value = analogRead(3);
float voltage = value * (5.0 / 1023.0);
Serial.print("DATA,TIME,"); //writes the time in the first column A and the time since the measurements started in column B
Serial.print(voltage);
row++;
if(row>360){
row = 0;
Serial.println("ROW,SET,2");
}
//Serial.println(); //be sure to add println to the last command so it knows to go into the next row on the second run
delay(100); //add a delay
}
The problem is this, I load the PLX-DAQ, allow macros and all that.. it brings up some sample's. I click new and three new sheets pop up. I click connect on the macro C and T go green while R flashes red, check. However, now, from what I understand, I should just see data load into the cells but no data is loading into the cells. Can anyone help?