Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include "pico/stdlib.h"
- const uint LED_PIN = PICO_DEFAULT_LED_PIN;
- int main() {
- // Initialize LED pin
- gpio_init(LED_PIN);
- gpio_set_dir(LED_PIN, GPIO_OUT);
- stdio_init_all();
- // Loop forever
- while (true) {
- // Blink LED
- printf("Blinking!\r\n");
- gpio_put(LED_PIN, true);
- sleep_ms(1000);
- gpio_put(LED_PIN, false);
- sleep_ms(1000);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement