mirror of
https://github.com/clockworkpi/WiringPi.git
synced 2026-03-24 12:52:41 +01:00
Reverted gpio readall to older version - new version is gpio nreadall
fixed the max5322 code.
This commit is contained in:
@@ -137,7 +137,7 @@ static char *physNames [64] =
|
||||
"3.3v", "GPIO5",
|
||||
"MOSI", "0v",
|
||||
"MISO", "GPIO6",
|
||||
"SCLK", "CE1",
|
||||
"SCLK", "CE0",
|
||||
"0v", "CE1",
|
||||
|
||||
NULL,NULL,NULL,NULL,NULL,
|
||||
@@ -178,7 +178,7 @@ static void readallPhys (int physPin)
|
||||
pin = physToWpi [physPin] ;
|
||||
|
||||
printf (" | %4s", alts [getAlt (pin)]) ;
|
||||
printf (" | %s", (digitalRead (pin) == 0) ? "Hi" : "Lo") ;
|
||||
printf (" | %s", (digitalRead (pin) == LOW) ? "Lo" : "Hi") ;
|
||||
}
|
||||
|
||||
// Pin numbers:
|
||||
@@ -200,7 +200,7 @@ static void readallPhys (int physPin)
|
||||
else
|
||||
pin = physToWpi [physPin] ;
|
||||
|
||||
printf (" | %s", (digitalRead (pin) == 0) ? "Hi" : "Lo") ;
|
||||
printf (" | %s", (digitalRead (pin) == LOW) ? "Lo" : "Hi") ;
|
||||
printf (" | %-4s", alts [getAlt (pin)]) ;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user