2

I am using Orange Pi on my project , and I searched for how to control its pin via python and i FOUND some results which suggest to install Wiring Pi .I installed WiringPi from https://github.com/WiringPi/WiringPi and also with pip but in both cases It doesn't work . I get this warning while I tried to use WiringPi: Unable to determine hardware version. I see: Hardware : sun8i '- expecting BCM2708 or BCM2709. If this is a genuino Raspberry pi then please report this to projects@drogon.net. If this not Raspberry Pi then you are on your own as WiringPi is designed to support the Raspberry PI ONLY.

t_ashrefov
  • 51
  • 1
  • 7
  • The error really says it all: the Orange Pi isn't a Raspberry Pi, and WiringPi is only meant to be used on the latter platform. There _is_ a port to Orange Pi, called [WiringOP](http://www.orangepi.org/Docs/WiringPi.html). – robertklep Oct 01 '16 at 12:10
  • Thanks for your effort, but the url that site suggested is blank when I tried to enter there is an error 404 – t_ashrefov Oct 03 '16 at 09:04
  • Can't say I've tried it myself, although I have an Orange Pi myself I kinda gave up on getting it to work with all the GPIO stuff that's meant for RaspPi's – robertklep Oct 03 '16 at 09:12

3 Answers3

2

You can find an Orange Pi Wiring Pi version through the orangepi official webpage: http://www.orangepi.org/Docs/WiringPi.html

manuti
  • 23
  • 1
  • 6
0
  1. download and extract this OPI-compatible python wrapper (eg. to /tmp/WiringPi-Python-OP-master)
  2. download the WiringPI C library and extract it inside the WiringPi subdir (eg. to /tmp/WiringPi-Python-OP-master/WiringPi)
  3. cd /tmp/WiringPi-Python-OP-master; python setup.py install

I just tested this on my OrangePI-PC and works pretty well.

(original instructions here, also check if you miss any dependency).

eadmaster
  • 1,347
  • 13
  • 23
0

you should use the pyH3 library. you can download this from : https://github.com/duxingkei33/orangepi_PC_gpio_pyH3 and then install this package

sudo apt-get install python-dev

extract the (phyh3) folder and place in '/home/pi' and

cd orangepi_PC_gpio_pyH3

and run python setup.py install

The library is now installed.

you can use test code in the folder examples https://github.com/duxingkei33/orangepi_PC_gpio_pyH3/tree/master/examples

iman ansari
  • 103
  • 8