UP Board has any ADC Pin
Whee Min
New Member Posts: 18 ✭
Hi UP Creators,
Can I verify if there is any ADC pin in the 40 pinout( Pin 7)? Can you provide more developmental information if it is available. Example, is there any example code so that developers can know how to use it.
Thanks ,
Whee Min
Can I verify if there is any ADC pin in the 40 pinout( Pin 7)? Can you provide more developmental information if it is available. Example, is there any example code so that developers can know how to use it.
Thanks ,
Whee Min
Comments
-
Hi tanwm,
There is indeed an 8-bit ADC available on pin 7. It operates on the 0V to 3.3V range. On supported versions of Linux, digital values can be read directly through sysfs:/sys/bus/iio/devices/iio\:device0/in_voltage_raw /sys/bus/iio/devices/iio\:device0/in_voltage_scale
We'll be updating the documentation shortly with more detail. -
See the CPLD and ADC blocks in the updated diagram of the UP-Board on page 2 of the latest datasheet:
http://www.up-board.org/wp-content/uploads/2015/09/UPDatasheetV8.4.pdf
The pinout for the UP Board is also shown on page 2. The ADC is indeed indicated on pin 7.
GPIO2/ADC-input7 -
Hello
With respect to the ADC pin. Can it be read with the mraa library?
ex: self._analog=mraa.Aio(7) in python
Best regards,
Mario -
Hi Mario
The short answer is: "not yet".
However, if you want it quickly and are happy to build MRAA from source code, you might be interested in this pull request:
https://github.com/intel-iot-devkit/mraa/pull/608
Best regards,
-Dan