fixup examples based on default pin #define-s and also support them being undefined
This commit is contained in:
committed by
Graham Sanderson
parent
9c7e31b8e7
commit
82b6dc0576
@@ -10,6 +10,9 @@
|
||||
#include "hello.pio.h"
|
||||
|
||||
int main() {
|
||||
#ifndef PICO_DEFAULT_LED_PIN
|
||||
#warning pio/hello_pio example requires a board with a regular LED
|
||||
#else
|
||||
// Choose which PIO instance to use (there are two instances)
|
||||
PIO pio = pio0;
|
||||
|
||||
@@ -35,4 +38,5 @@ int main() {
|
||||
pio_sm_put_blocking(pio, sm, 0);
|
||||
sleep_ms(500);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user