Author Topic: CubieTruck analog pins programming  (Read 3266 times)

Offline Eudaimonium

  • Newbie
  • *
  • Posts: 12
  • Karma: +0/-0
    • View Profile
CubieTruck analog pins programming
« on: August 18, 2015, 05:56:35 am »

Official documentation states that Cubietruck has 8 analog pins:

Is there a way to read and write to those pins in C programming?

I am using Sunxi library which works perfectly with standard digital GPIO pins via
Code: [Select]
sunxi_gpio_set_cfgpin(pinID, direction)
sunxi_gpio_output(pinID, value)

However the library's header file doesn't even declare any functions for analog operations, nor a way to get their addresses. Digital pins are found via define declaration:
Code: [Select]
* = Bank name (A-I)
X = Pin number within it's bank

How does one work with analog pins on Cubietruck, then? Are there any official Sunxi libraries, or third party libraries that can help me read and write analog values?