Skip to content

Commit 8e336d8

Browse files
committed
fix(hal): BOOT_PIN should always be defined
1 parent f163f37 commit 8e336d8

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

cores/esp32/esp32-hal.h

+3-4
Original file line numberDiff line numberDiff line change
@@ -63,17 +63,16 @@ extern "C" {
6363

6464
#if CONFIG_IDF_TARGET_ESP32 || CONFIG_IDF_TARGET_ESP32S2 || CONFIG_IDF_TARGET_ESP32S3
6565
static const uint8_t BOOT_PIN = 0;
66-
#define BOOT_PIN BOOT_PIN
6766
#elif CONFIG_IDF_TARGET_ESP32C2 || CONFIG_IDF_TARGET_ESP32C3 || CONFIG_IDF_TARGET_ESP32C6 || CONFIG_IDF_TARGET_ESP32H2 || CONFIG_IDF_TARGET_ESP32C61
6867
static const uint8_t BOOT_PIN = 9;
69-
#define BOOT_PIN BOOT_PIN
7068
#elif CONFIG_IDF_TARGET_ESP32P4
7169
static const uint8_t BOOT_PIN = 35;
72-
#define BOOT_PIN BOOT_PIN
7370
#elif CONFIG_IDF_TARGET_ESP32C5
7471
static const uint8_t BOOT_PIN = 28;
75-
#define BOOT_PIN BOOT_PIN
72+
#else
73+
#error BOOT_PIN not defined for this chip!
7674
#endif
75+
#define BOOT_PIN BOOT_PIN
7776

7877
//forward declaration from freertos/portmacro.h
7978
void vPortYield(void);

0 commit comments

Comments
 (0)