wiringPi for Orange Pi
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

32 lines
541 B

6 years ago
#include <stdio.h>
#include <wiringPi.h>
#define NUM 17 //26pin
//#define NUM 18 //26pin
//#define NUM 20 //for Orange Pi Zero 2
//#define NUM 19 //for Orange Pi 4
//#define NUM 28 //40pin
6 years ago
int main (void)
{
int i = 0;
6 years ago
wiringPiSetup () ;
6 years ago
for (i = 0; i < NUM; i++)
pinMode (i, OUTPUT) ;
6 years ago
for ( ;; )
{
for (i = 0; i < NUM; i++)
digitalWrite (i, HIGH) ; // On
delay (2000) ; // mS
6 years ago
for (i = 0; i < NUM; i++)
digitalWrite (i, LOW) ; // Off
delay (2000) ;
}
return 0;
6 years ago
}