File tree Expand file tree Collapse file tree 5 files changed +16
-55
lines changed Expand file tree Collapse file tree 5 files changed +16
-55
lines changed Original file line number Diff line number Diff line change 1
1
if (NOT PICO_NO_HARDWARE )
2
- add_subdirectory (double_tap_usb_boot )
3
2
add_subdirectory (narrow_io_write )
4
3
add_subdirectory (hello_double_tap )
5
4
add_subdirectory (unique_board_id )
Load Diff This file was deleted.
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -2,12 +2,19 @@ add_executable(hello_double_tap
2
2
hello_double_tap.c
3
3
)
4
4
5
- # Double tap reset into bootrom is injected by linking with the double_tap_usb_boot library
5
+ # Double tap reset into bootrom is injected by linking with the
6
+ # pico_bootsel_via_double_reset library
6
7
target_link_libraries (hello_double_tap
7
8
pico_stdlib
8
- double_tap_usb_boot
9
+ pico_bootsel_via_double_reset
9
10
)
10
11
12
+ # Entering the bootloader in this way also lets us specify a GPIO to be used
13
+ # as a bootloader activity LED:
14
+ target_compile_definitions (hello_double_tap PRIVATE
15
+ PICO_BOOTSEL_VIA_DOUBLE_RESET_ACTIVITY_LED=25
16
+ )
17
+
11
18
pico_add_extra_outputs (hello_double_tap )
12
19
13
20
# add url via pico_set_program_url
Original file line number Diff line number Diff line change 6
6
7
7
#include "pico/stdlib.h"
8
8
9
- // This is a regular old LED blinking example, however it is linked with double_tap_usb_boot
10
- // so pressing reset quickly twice, will reset into USB bootloader
9
+ // This is a regular old LED blinking example, however it is linked with the
10
+ // `pico_bootsel_via_double_reset` library, so resetting the board twice
11
+ // quickly will enter the USB bootloader. This is useful for boards which have
12
+ // a reset button but no BOOTSEL, as long as you remember to always link the
13
+ // `pico_bootsel_via_double_reset` library!
14
+
11
15
int main () {
12
- const uint LED_PIN = 21 ;
16
+ const uint LED_PIN = PICO_DEFAULT_LED_PIN ;
13
17
gpio_init (LED_PIN );
14
18
gpio_set_dir (LED_PIN , GPIO_OUT );
15
19
while (true) {
You can’t perform that action at this time.
0 commit comments