AnalogReadSerial

I am using AnalogReadSerial from examples.

How do I plot a fixed lower and a fixed upper number?

A0 is the lower (GND) A1 is the analog serial output A2 is the upper voltage?

Also using the AnalogReadSerial from examples why is my plotter output so glithy? I changed the delay to 100 as in
delay(100); // delay in between reads for stability
but this does not help.

Thank you.

Welcome to the forum

You started a topic in the Uncategorised category of the forum when its description explicitly tells you not to

Your topic has been moved to a relevant category. Please be careful in future when deciding where to start new topics

So that we know exactly what code you are referring to please post your sketch, using code tags when you do

Posting your code using code tags prevents parts of it being interpreted as HTML coding and makes it easier to copy for examination

In my experience the easiest way to tidy up the code and add the code tags is as follows

Start by tidying up your code by using Tools/Auto Format in the IDE to make it easier to read. Then use Edit/Copy for Forum and paste what was copied in a new reply. Code tags will have been added to the code to make it easy to read in the forum thus making it easier to provide help.

Which Arduino board are you using and what is connected to the board ?

1 Like
void serialPlotter() {
  int Data1 = analogRead(A0);
  int Data2 = 0;
  int Data3 = 1023;

  Serial.print("Trace1:");
  Serial.print(Data1);
  Serial.print(",");
  Serial.print("Trace2:");
  Serial.println(Data2);
  Serial.print(",");
  Serial.print("Trace3:");
  Serial.println(Data3);
}
1 Like

Thank you!

1 Like

My apologies. Newbie, but I should have read the instructions "... description explicitly tells you not to" I am sorry.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.