# Easy Analog Sensor test using the Console

**URL:** <https://community.particle.io/t/easy-analog-sensor-test-using-the-console/27665>\
**Category:** General\
**Created:** [December 1, 2016, 5:39pm UTC](https://community.particle.io/t/easy-analog-sensor-test-using-the-console/27665 "2016-12-01T17:39:25Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![rocksetta](https://sea2.discourse-cdn.com/flex026/user_avatar/community.particle.io/rocksetta/32/5099_2.png) [@rocksetta](https://community.particle.io/u/rocksetta)\
**Post date:** [December 1, 2016, 5:39pm UTC](https://community.particle.io/t/easy-analog-sensor-test-using-the-console/27665/1 "2016-12-01T17:39:25Z")

</div>

My Class has been testing several analog sensors. The serial connection is hard to work with in a classroom setting, but the particle console is really useful. This little generic analog sensor program has become a necessity.

> // Easiest Analog Console test program  
> // By Jeremy Ellis

> // lots of sensors have these labels  
> // GND Ground  
> // VCC Normal 5Vin check board may want 3V3  
> // NC Not Connected - might be label LED  
> // Sig Connect to A0

> void setup() {

> }

> void loop() {

> int myReadA0= analogRead(A0);  
> String myA0 = String(myReadA0,DEC);

> Particle.publish("Analog Read", String("A0 = " + myA0), 60, PRIVATE);  
> delay(6000); // wait about 6 seconds  
> }

---

<div class="post-metadata">

**Author:** ![rocksetta](https://sea2.discourse-cdn.com/flex026/user_avatar/community.particle.io/rocksetta/32/5099_2.png) [@rocksetta](https://community.particle.io/u/rocksetta)\
**Post date:** [December 2, 2016, 6:28pm UTC](https://community.particle.io/t/easy-analog-sensor-test-using-the-console/27665/2 "2016-12-02T18:28:34Z")

</div>

Hey @peekay123 we have been looking at a bunch of your libraries for my massive amount of sensors. I was really pleased when I gave a student a serial sensor I had never used before and it took him a few minutes to get it working. His reply was: “Not UART or SPI it was fairly easy I2C with only one header file”

I think they actually might be learning something: 😀
