Display Choices

One use of an Arduino microcontroller is to collect data from sensors. Some of those
sensors are “analog”, i.e., their output ranges over a span of values, rather than
simply being LOW or HIGH. Examples of such devices are thermometers, potentiometers,
light sensors, …

The input from these sensors can only be read on certain ports of the Arduino, labelled
A0 through A5. Input on those ports is automatically scaled by the microcontroller
to a range from 0 through 512. So, if the sensor produces a 5V signal, that is interpreted
as 512 by the Arduino, and if the sensor produces a 2.5V signal, that is interpreted
as 256 by the Arduino.

These readings can be used to trigger some other event (e.g., if the temperature exceeds
some value, then turn on an LED). They can also be viewed directly; this is often
useful for debugging purposes.

The Arduino IDE provides two ways to read the output of a sensor: text and graphics.
The example below show how much more effective the graphical output is for illustrating
trends in data. They both show the input from the analog port A0 over a 10 second
time interval.

Reading analog input on the Serial Console Viewing analog input on the Serial Plotter
![](images/console.png

The packets on Simple Output to the Console and
Fancy Output to the Console showed how to display numbers on the
Serial Console. This packet shows you how to plot data from 1 or more inputs on the
Serial Plotter.

Note: you can only use the Serial Console or the Serial Plotter at any one time.

Choosing either one causes the microcontroller to RESET.