From 0e5e67e23de040d2c1e3e0f7f16dcb1d0516ec51 Mon Sep 17 00:00:00 2001 From: Cristian Maglie Date: Sun, 3 Nov 2013 18:07:01 +0100 Subject: Added LED_BUILTIN constant to Leonardo board --- variants/leonardo/pins_arduino.h | 1 + 1 file changed, 1 insertion(+) (limited to 'variants') diff --git a/variants/leonardo/pins_arduino.h b/variants/leonardo/pins_arduino.h index 2c7f837..571322b 100644 --- a/variants/leonardo/pins_arduino.h +++ b/variants/leonardo/pins_arduino.h @@ -101,6 +101,7 @@ static const uint8_t SDA = 2; static const uint8_t SCL = 3; +static const uint8_t LED_BUILTIN = 13; // Map SPI port to 'new' pins D14..D17 static const uint8_t SS = 17; -- cgit v1.2.3-18-g5258 From 9d48a366169d0362cfdfcd0ecfe88afa578a5bc8 Mon Sep 17 00:00:00 2001 From: Cristian Maglie Date: Sun, 3 Nov 2013 18:10:22 +0100 Subject: Changed LED_BUILTIN to a macro to better support boards that do not have a built-in LED. Fixes #758 --- variants/ethernet/pins_arduino.h | 2 +- variants/leonardo/pins_arduino.h | 2 +- variants/mega/pins_arduino.h | 4 ++-- variants/standard/pins_arduino.h | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) (limited to 'variants') diff --git a/variants/ethernet/pins_arduino.h b/variants/ethernet/pins_arduino.h index 202f854..9676698 100644 --- a/variants/ethernet/pins_arduino.h +++ b/variants/ethernet/pins_arduino.h @@ -44,7 +44,7 @@ static const uint8_t SCK = 13; static const uint8_t SDA = 18; static const uint8_t SCL = 19; -static const uint8_t LED_BUILTIN = 9; +#define LED_BUILTIN 9 static const uint8_t A0 = 14; static const uint8_t A1 = 15; diff --git a/variants/leonardo/pins_arduino.h b/variants/leonardo/pins_arduino.h index 571322b..9f3246a 100644 --- a/variants/leonardo/pins_arduino.h +++ b/variants/leonardo/pins_arduino.h @@ -101,7 +101,7 @@ static const uint8_t SDA = 2; static const uint8_t SCL = 3; -static const uint8_t LED_BUILTIN = 13; +#define LED_BUILTIN 13 // Map SPI port to 'new' pins D14..D17 static const uint8_t SS = 17; diff --git a/variants/mega/pins_arduino.h b/variants/mega/pins_arduino.h index 5a9b4cb..b0b4290 100644 --- a/variants/mega/pins_arduino.h +++ b/variants/mega/pins_arduino.h @@ -39,7 +39,7 @@ static const uint8_t SCK = 52; static const uint8_t SDA = 20; static const uint8_t SCL = 21; -static const uint8_t LED_BUILTIN = 13; +#define LED_BUILTIN 13 static const uint8_t A0 = 54; static const uint8_t A1 = 55; @@ -360,4 +360,4 @@ const uint8_t PROGMEM digital_pin_to_timer_PGM[] = { #endif -#endif \ No newline at end of file +#endif diff --git a/variants/standard/pins_arduino.h b/variants/standard/pins_arduino.h index 30b4266..b024ca1 100644 --- a/variants/standard/pins_arduino.h +++ b/variants/standard/pins_arduino.h @@ -44,7 +44,7 @@ static const uint8_t SCK = 13; static const uint8_t SDA = 18; static const uint8_t SCL = 19; -static const uint8_t LED_BUILTIN = 13; +#define LED_BUILTIN 13 static const uint8_t A0 = 14; static const uint8_t A1 = 15; -- cgit v1.2.3-18-g5258