mirror of
https://github.com/clockworkpi/WiringPi.git
synced 2026-03-25 05:12:48 +01:00
Updates for the Raspnerry Pi Compute Module - changes to the gpio program
to produce a nicer 'readall' output too. It also understands new pins 53,54,55 and 56 in wiringPiSetupPhys() mode to represent the pins on the P5 connector on the Rev 2 Pi's Changes to pinMode() to allow new modes SOFT_PWM and SOFT_TONE.
This commit is contained in:
@@ -79,6 +79,7 @@ char *usage = "Usage: gpio -v\n"
|
||||
" gpio gbw <channel> <value>" ; // No trailing newline needed here.
|
||||
|
||||
|
||||
#ifdef NOT_FOR_NOW
|
||||
/*
|
||||
* decodePin:
|
||||
* Decode a pin "number" which can actually be a pin name to represent
|
||||
@@ -96,6 +97,7 @@ static int decodePin (const char *str)
|
||||
|
||||
return 0 ;
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
/*
|
||||
@@ -1042,6 +1044,8 @@ static void doPwmClock (int argc, char *argv [])
|
||||
int main (int argc, char *argv [])
|
||||
{
|
||||
int i ;
|
||||
int model, rev, mem ;
|
||||
char *maker ;
|
||||
|
||||
if (getenv ("WIRINGPI_DEBUG") != NULL)
|
||||
{
|
||||
@@ -1086,7 +1090,10 @@ int main (int argc, char *argv [])
|
||||
printf ("This is free software with ABSOLUTELY NO WARRANTY.\n") ;
|
||||
printf ("For details type: %s -warranty\n", argv [0]) ;
|
||||
printf ("\n") ;
|
||||
printf ("This Raspberry Pi is a revision %d board.\n", piBoardRev ()) ;
|
||||
piBoardId (&model, &rev, &mem, &maker) ;
|
||||
printf ("Raspberry Pi Details:\n") ;
|
||||
printf (" Type: %s, Revision: %s, Memory: %dMB, Maker: %s\n",
|
||||
piModelNames [model], piRevisionNames [rev], mem, maker) ;
|
||||
return 0 ;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user