Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions data/mappings/info_config.hjson
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,11 @@
"RGBLIGHT_DEFAULT_VAL": {"info_key": "rgblight.default.val", "value_type": "int"},
"RGBLIGHT_DEFAULT_SPD": {"info_key": "rgblight.default.speed", "value_type": "int"},

// RP2040 Bootloader
"RP2040_BOOTLOADER_DOUBLE_TAP_RESET": {"info_key": "rp2040_bootloader.double_tap_reset", "value_type": "flag"},
"RP2040_BOOTLOADER_DOUBLE_TAP_RESET_LED": {"info_key": "rp2040_bootloader.double_tap_reset_led"},
"RP2040_BOOTLOADER_DOUBLE_TAP_RESET_TIMEOUT": {"info_key": "rp2040_bootloader.double_tap_reset_timeout", "value_type": "int"},

// Secure
"SECURE_IDLE_TIMEOUT": {"info_key": "secure.idle_timeout", "value_type": "int"},
"SECURE_UNLOCK_SEQUENCE": {"info_key": "secure.unlock_sequence", "value_type": "array.array.int", "to_json": false},
Expand Down
9 changes: 9 additions & 0 deletions data/schemas/keyboard.jsonschema
Original file line number Diff line number Diff line change
Expand Up @@ -811,6 +811,15 @@
}
}
},
"rp2040_bootloader": {
"type": "object",
"additionalProperties": false,
"properties": {
"double_tap_reset": {"type": "boolean"},
"double_tap_reset_led": {"$ref": "./definitions.jsonschema#/mcu_pin"},
"double_tap_reset_timeout": {"$ref": "./definitions.jsonschema#/unsigned_int"}
}
},
"split": {
"type": "object",
"additionalProperties": false,
Expand Down
2 changes: 1 addition & 1 deletion docs/platformdev_rp2040.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ The double-tap reset mechanism is an alternate way in QMK to enter the embedded

```c
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET // Activates the double-tap behavior
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_TIMEOUT 200U // Timeout window in ms in which the double tap can occur.
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_TIMEOUT 200 // Timeout window in ms in which the double tap can occur.
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_LED GP17 // Specify a optional status led by GPIO number which blinks when entering the bootloader
```

Expand Down
12 changes: 12 additions & 0 deletions docs/reference_info_json.md
Original file line number Diff line number Diff line change
Expand Up @@ -727,6 +727,18 @@ Configures the [RGB Matrix](features/rgb_matrix) feature.
* The value by which to increment the brightness.
* Default: `16`

## RP2040 Bootloader {#rp2040-bootloader}

* `rp2040_bootloader`
* `double_tap_reset` <Badge type="info">Boolean</Badge>
* Enable the double-tap functionality to enter bootloader.
* Default: `false`
* `double_tap_reset_led` <Badge type="info">Pin</Badge>
* The GPIO pin connected to an LED to flash.
* `double_tap_reset_timout` <Badge type="info">Number</Badge>
* The timeout value in which the reset button must be double-tapped in milliseconds.
* Default: `200`

## Secure {#secure}

Configures the [Secure](features/secure) feature.
Expand Down
5 changes: 0 additions & 5 deletions keyboards/adafruit/macropad/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,6 @@
#define SPI_MOSI_PIN GP27
#define SPI_MISO_PIN GP28

/* Double tap the side button to enter bootloader */
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_LED GP13
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_TIMEOUT 500U

/* Audio */
#define AUDIO_PIN GP16
#define AUDIO_PWM_DRIVER PWMD0
Expand Down
5 changes: 5 additions & 0 deletions keyboards/adafruit/macropad/keyboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,11 @@
{"matrix": [4, 2], "x": 224, "y": 64, "flags": 4}
]
},
"rp2040_bootloader": {
"double_tap_reset": true,
"double_tap_reset_led": "GP13",
"double_tap_reset_timeout": 500
},
"bootmagic": {
"matrix": [1, 2]
},
Expand Down
5 changes: 0 additions & 5 deletions keyboards/ai03/altair/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,3 @@

/* VBUS-routed pin for upstream detection */
#define USB_VBUS_PIN GP0

/* RP2040- and hardware-specific config */
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_TIMEOUT 500U
#define PICO_XOSC_STARTUP_DELAY_MULTIPLIER 64
4 changes: 4 additions & 0 deletions keyboards/ai03/altair/keyboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,10 @@
"rows": ["GP11", "GP26", "GP27", "GP28", "GP10"]
},
"processor": "RP2040",
"rp2040_bootloader": {
"double_tap_reset": true,
"double_tap_reset_timeout": 500
},
"split": {
"bootmagic": {
"matrix": [5, 0]
Expand Down
5 changes: 0 additions & 5 deletions keyboards/ai03/altair_x/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,3 @@

/* VBUS-routed pin for upstream detection */
#define USB_VBUS_PIN GP0

/* RP2040- and hardware-specific config */
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_TIMEOUT 500U
#define PICO_XOSC_STARTUP_DELAY_MULTIPLIER 64
4 changes: 4 additions & 0 deletions keyboards/ai03/altair_x/keyboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,10 @@
"rows": ["GP26", "GP27", "GP28", "GP10"]
},
"processor": "RP2040",
"rp2040_bootloader": {
"double_tap_reset": true,
"double_tap_reset_timeout": 500
},
"split": {
"bootmagic": {
"matrix": [4, 0]
Expand Down
15 changes: 5 additions & 10 deletions keyboards/anavi/arrows/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,21 +3,16 @@

#pragma once

/* Double tap reset button to enter bootloader */
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_LED GP17
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_TIMEOUT 500U

#ifdef BACKLIGHT_ENABLE
# define BACKLIGHT_PWM_DRIVER PWMD5
# define BACKLIGHT_PWM_CHANNEL RP2040_PWM_CHANNEL_A
# define BACKLIGHT_PWM_DRIVER PWMD5
# define BACKLIGHT_PWM_CHANNEL RP2040_PWM_CHANNEL_A
#endif

#define I2C1_SDA_PIN GP6
#define I2C1_SCL_PIN GP7

#ifdef OLED_ENABLE
# define OLED_DISPLAY_128X64
# define OLED_TIMEOUT 60000
# define OLED_BRIGHTNESS 128
# define OLED_DISPLAY_128X64
# define OLED_TIMEOUT 60000
# define OLED_BRIGHTNESS 128
#endif
5 changes: 5 additions & 0 deletions keyboards/anavi/arrows/keyboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,11 @@
"animation": "rainbow_mood"
}
},
"rp2040_bootloader": {
"double_tap_reset": true,
"double_tap_reset_led": "GP17",
"double_tap_reset_timeout": 500
},
"ws2812": {
"pin": "GP3",
"driver": "vendor"
Expand Down
11 changes: 3 additions & 8 deletions keyboards/anavi/knob1/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,12 @@

#pragma once

/* Double tap reset button to enter bootloader */
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_LED GP17
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_TIMEOUT 500U

#define I2C_DRIVER I2CD1
#define I2C1_SDA_PIN GP6
#define I2C1_SCL_PIN GP7

#ifdef OLED_ENABLE
# define OLED_DISPLAY_128X64
# define OLED_TIMEOUT 60000
# define OLED_BRIGHTNESS 128
# define OLED_DISPLAY_128X64
# define OLED_TIMEOUT 60000
# define OLED_BRIGHTNESS 128
#endif
5 changes: 5 additions & 0 deletions keyboards/anavi/knob1/keyboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,11 @@
"animation": "rainbow_swirl"
}
},
"rp2040_bootloader": {
"double_tap_reset": true,
"double_tap_reset_led": "GP17",
"double_tap_reset_timeout": 500
},
"ws2812": {
"pin": "GP12",
"driver": "vendor"
Expand Down
10 changes: 0 additions & 10 deletions keyboards/anavi/macropad10/config.h

This file was deleted.

5 changes: 5 additions & 0 deletions keyboards/anavi/macropad10/keyboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,11 @@
"twinkle": true
}
},
"rp2040_bootloader": {
"double_tap_reset": true,
"double_tap_reset_led": "GP17",
"double_tap_reset_timeout": 500
},
"ws2812": {
"pin": "GP3",
"driver": "vendor"
Expand Down
15 changes: 5 additions & 10 deletions keyboards/anavi/macropad12/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,21 +3,16 @@

#pragma once

/* Double tap reset button to enter bootloader */
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_LED GP17
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_TIMEOUT 500U

#ifdef BACKLIGHT_ENABLE
# define BACKLIGHT_PWM_DRIVER PWMD5
# define BACKLIGHT_PWM_CHANNEL RP2040_PWM_CHANNEL_A
# define BACKLIGHT_PWM_DRIVER PWMD5
# define BACKLIGHT_PWM_CHANNEL RP2040_PWM_CHANNEL_A
#endif

#define I2C1_SDA_PIN GP6
#define I2C1_SCL_PIN GP7

#ifdef OLED_ENABLE
# define OLED_DISPLAY_128X64
# define OLED_TIMEOUT 60000
# define OLED_BRIGHTNESS 128
# define OLED_DISPLAY_128X64
# define OLED_TIMEOUT 60000
# define OLED_BRIGHTNESS 128
#endif
5 changes: 5 additions & 0 deletions keyboards/anavi/macropad12/keyboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,11 @@
"animation": "rainbow_mood"
}
},
"rp2040_bootloader": {
"double_tap_reset": true,
"double_tap_reset_led": "GP17",
"double_tap_reset_timeout": 500
},
"ws2812": {
"pin": "GP3",
"driver": "vendor"
Expand Down
4 changes: 0 additions & 4 deletions keyboards/bastardkb/dilemma/3x5_2/assembled/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,3 @@
#define SPI_MOSI_PIN GP23
#define SPI_MISO_PIN GP20
#define POINTING_DEVICE_CS_PIN GP21

#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_LED GP17
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_TIMEOUT 1000U
5 changes: 5 additions & 0 deletions keyboards/bastardkb/dilemma/3x5_2/assembled/keyboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@
"rows": ["GP4", "GP5", "GP28", "GP26"]
},
"processor": "RP2040",
"rp2040_bootloader": {
"double_tap_reset": true,
"double_tap_reset_led": "GP17",
"double_tap_reset_timeout": 1000
},
"split": {
"handedness": {
"pin": "GP29"
Expand Down
5 changes: 0 additions & 5 deletions keyboards/bastardkb/dilemma/3x5_3/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,3 @@
#define POINTING_DEVICE_CS_PIN GP21
#undef CIRQUE_PINNACLE_DIAMETER_MM
#define CIRQUE_PINNACLE_DIAMETER_MM 40

/* Reset. */
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_LED GP17
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_TIMEOUT 500U
5 changes: 5 additions & 0 deletions keyboards/bastardkb/dilemma/3x5_3/keyboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,11 @@
"rows": ["GP4", "GP5", "GP27", "GP26"]
},
"diode_direction": "ROW2COL",
"rp2040_bootloader": {
"double_tap_reset": true,
"double_tap_reset_led": "GP17",
"double_tap_reset_timeout": 500
},
"split": {
"enabled": true,
"serial": {
Expand Down
5 changes: 0 additions & 5 deletions keyboards/bastardkb/dilemma/4x6_4/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,3 @@
#define POINTING_DEVICE_CS_PIN GP21
#undef CIRQUE_PINNACLE_DIAMETER_MM
#define CIRQUE_PINNACLE_DIAMETER_MM 40

/* Reset. */
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_LED GP17
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_TIMEOUT 500U
5 changes: 5 additions & 0 deletions keyboards/bastardkb/dilemma/4x6_4/keyboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,11 @@
"rows": ["GP15", "GP4", "GP5", "GP27", "GP26"]
},
"diode_direction": "ROW2COL",
"rp2040_bootloader": {
"double_tap_reset": true,
"double_tap_reset_led": "GP17",
"double_tap_reset_timeout": 500
},
"split": {
"enabled": true,
"serial": {
Expand Down
4 changes: 0 additions & 4 deletions keyboards/beekeeb/piantor/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,6 @@

#pragma once


#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_TIMEOUT 1000U

#define SERIAL_USART_FULL_DUPLEX
#define SERIAL_USART_TX_PIN GP0
#define SERIAL_USART_RX_PIN GP1
4 changes: 4 additions & 0 deletions keyboards/beekeeb/piantor/keyboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,10 @@
["GP17", "GP18", "GP16", null, null, null]
]
},
"rp2040_bootloader": {
"double_tap_reset": true,
"double_tap_reset_timeout": 1000
},
"split": {
"enabled": true,
"matrix_pins": {
Expand Down
3 changes: 0 additions & 3 deletions keyboards/beekeeb/piantor_pro/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@

#pragma once

#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_TIMEOUT 1000U

#define SERIAL_USART_FULL_DUPLEX
#define SERIAL_USART_TX_PIN GP0
#define SERIAL_USART_RX_PIN GP1
Expand Down
4 changes: 4 additions & 0 deletions keyboards/beekeeb/piantor_pro/keyboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,10 @@
"pid": "0x0002",
"vid": "0xBEEB"
},
"rp2040_bootloader": {
"double_tap_reset": true,
"double_tap_reset_timeout": 1000
},
"split": {
"enabled": true,
"serial": {
Expand Down
4 changes: 0 additions & 4 deletions keyboards/budgy/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,6 @@

#pragma once

#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_TIMEOUT 1000U


#define SERIAL_USART_FULL_DUPLEX
#define SERIAL_USART_TX_PIN GP1
#define SERIAL_USART_RX_PIN GP0
Expand Down
4 changes: 4 additions & 0 deletions keyboards/budgy/keyboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,10 @@
["GP17", "GP18", null, null, null]
]
},
"rp2040_bootloader": {
"double_tap_reset": true,
"double_tap_reset_timeout": 1000
},
"split": {
"enabled": true,
"matrix_pins": {
Expand Down
3 changes: 0 additions & 3 deletions keyboards/cannonkeys/bastion60/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@

#pragma once

#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_TIMEOUT 500U

#define PICO_XOSC_STARTUP_DELAY_MULTIPLIER 64

#define BACKLIGHT_PWM_DRIVER PWMD3
Expand Down
Loading
Loading