Skip to content

Input Output: Get analog value from () () in ()

Jaume Olivé Petrus edited this page Oct 29, 2017 · 1 revision

This block is an Input / Output block and a Reporter block that reports the current analog value from an external ADC channel. The analog value can be obtained in millivolts, or in raw value.

Shape

Example

In this example a potentiometer is attached to an external ADC channel, and every 0.5 seconds the analog value is read and displayed on the console in millivolts and in raw value.

Move the potentiometer clockwise or counterclockwise and see the changes.

Instructions:

  • Connect an external ADS1115 ADC
  • Connect a potentiometer to ADS1115 channel 0

Run this example in The Whitecat IDE.

Clone this wiki locally