A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://arduino-pico.readthedocs.io/en/latest/bootsel.html below:

Website Navigation


BOOTSEL Button — Arduino-Pico 4.7.1 documentation

BOOTSEL Button

The BOOTSEL button on the Pico is not connected to a standard GPIO, so it cannot be read using the usual digitalRead function. It can, however, be read using a special (relatively slow) method.

The BOOTSEL object implements a simple way of reading the BOOTSEL button. Simply use the object BOOTSEL as a boolean (as a conditional in an if or while, or assigning to a bool):

// Print "BEEP" if the BOOTSEL button is pressed
if (BOOTSEL) {
    Serial.println("BEEP!");
    // Wait until BOOTSEL is released
    while (BOOTSEL) {
        delay(1);
    }
}

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4