BPI-M3 WiringPi
install BPI-M3 WiringPi:
1,Download WiringPi from github For BPI-M3
git clone https://github.com/BPI-SINOVOIP/BPI-WiringPi.git -b BPI_M3
2,Installation:
cd BPI-WiringPi
chmod +x ./build
sudo ./build
3,test wiringPi is install success
gpio -v
gpio readall
4,create new : blink.c
1
#include <wiringPi.h>
2
int main(void)
3
{
4
wiringPiSetup() ;
5
pinMode (0, OUTPUT) ;
6
for(;;)
7
{
8
digitalWrite(0, HIGH) ; delay (500) ;
9
digitalWrite(0, LOW) ; delay (500) ;
10
}
11
}
Copied!
compile and run it:
gcc -Wall -o blink blink.c -lwiringPi
runing it:
sudo ./blink
BPI have many extend board support WiringPi. so you can free DIY by youself:
more about BPI extend board,please see:
link to forum:
youtube vodeo for how to:
Last modified 1yr ago
Copy link