Power & Source of Big Ideas

Using WiringNP for a NanoPi Duo?

Moderators: chensy, FATechsupport

The NanoPi Duo wiki page:
http://wiki.friendlyarm.com/wiki/index. ... h_WiringNP
directs the user to the WiringNP wiki page:
http://wiki.friendlyarm.com/wiki/index. ... ing_with_C

The WiringNP page provides directions for building for the NanpPi Neo and for the NanoPi M1, but not for the NanoPi Duo.

Is this a solved problem, or should just use the Neo and/or M1 versions and ignore the pin numbers?
Followup:
The instructions on the wiki do not state this, but you shold follow the instructions for the Neo, not the M1, when you build. Then the generated code will read the file /sys/class/sunxi_info to determine the
board type. That's great, but the result from
gpio readall has the wrong physical pin numbers:

Code: Select all

pi@NanoPi-Duo:~/WiringNP/gpio$ sudo ./gpio readall
 +-----+-----+----------+------+---+-NanoPi-Duo--+------+----------+-----+-----+
 | BCM | wPi |   Name   | Mode | V | Physical | V | Mode | Name     | wPi | BCM |
 +-----+-----+----------+------+---+----++----+---+------+----------+-----+-----+
 |     |     |    MIC_N |      |   |  1 || 2  |   |      | EPhySPD  |     |     |
 |     |     |    MIC_P |      |   |  3 || 4  |   |      | EPhyLinK |     |     |
 |     |     | LineOutR |      |   |  5 || 6  |   |      | EPhyTXP  |     |     |
 |     |     | LineOutL |      |   |  7 || 8  |   |      | EPhyTXN  |     |     |
 |     |     |     CVBS |      |   |  9 || 10 |   |      | EPhyRXP  |     |     |
 | 198 |   8 |   GPIOG6 | ALT5 | 0 | 11 || 12 |   |      | EPhyRXN  |     |     |
 | 199 |   9 |   GPIOG7 | ALT5 | 0 | 13 || 14 |   |      | USB-DP2  |     |     |
 |  15 |   7 |  GPIOA15 | ALT4 | 0 | 15 || 16 |   |      | USB-DM2  |     |     |
 |  16 |   0 |  GPIOA16 | ALT4 | 0 | 17 || 18 |   |      | USB-DP3  |     |     |
 |  14 |   2 |  GPIOA14 | ALT4 | 0 | 19 || 20 |   |      | USB-DM3  |     |     |
 |  13 |   3 |  GPIOA13 | ALT4 | 0 | 21 || 22 | 0 |  OFF | GPIOG11  | 16  | 203 |
 |  12 |  12 |  GPIOA12 | ALT5 | 0 | 23 || 24 | 0 |   IN | GPIOL11  | 18  | -1  |
 |  11 |  13 |  GPIOA11 | ALT5 | 0 | 25 || 26 |   |      | 0v       |     |     |
 |     |     |       0v |      |   | 27 || 28 |   |      | 3.3v     |     |     |
 |   4 |  14 |   GPIOA4 | ALT5 | 0 | 29 || 30 |   |      | 5v       |     |     |
 |   5 |  15 |   GPIOA5 | ALT5 | 0 | 31 || 32 |   |      | 5v       |     |     |
 +-----+-----+----------+------+---+----++----+---+------+----------+-----+-----+
 | BCM | wPi |   Name   | Mode | V | Physical | V | Mode | Name     | wPi | BCM |
 +-----+-----+----------+------+---+-NanoPi-Duo--+------+----------+-----+-----+

Who is online

In total there are 0 users online :: 0 registered, 0 hidden and 0 guests (based on users active over the past 5 minutes)
Most users ever online was 102 on Mon Oct 08, 2018 12:42 pm

Users browsing this forum: No registered users and 0 guests