From b1537374fbe96bd853fcd7980b80cb2462d6ac5b Mon Sep 17 00:00:00 2001 From: George Oikonomou Date: Wed, 28 Feb 2018 23:03:26 +0000 Subject: [PATCH] Migrate to the new LED HAL (CC26xx/CC13xx) --- arch/platform/srf06-cc26xx/Makefile.srf06-cc26xx | 3 +-- arch/platform/srf06-cc26xx/platform.c | 4 ++-- arch/platform/srf06-cc26xx/srf06/leds-arch.c | 4 ++-- 3 files changed, 5 insertions(+), 6 deletions(-) diff --git a/arch/platform/srf06-cc26xx/Makefile.srf06-cc26xx b/arch/platform/srf06-cc26xx/Makefile.srf06-cc26xx index 9d4966fb7..7bead9fff 100644 --- a/arch/platform/srf06-cc26xx/Makefile.srf06-cc26xx +++ b/arch/platform/srf06-cc26xx/Makefile.srf06-cc26xx @@ -14,8 +14,7 @@ CONTIKI_TARGET_DIRS += . PLATFORM_ROOT_DIR = $(CONTIKI)/arch/platform/$(TARGET) -include $(PLATFORM_ROOT_DIR)/$(BOARD)/Makefile.$(notdir $(BOARD)) -CONTIKI_TARGET_SOURCEFILES += platform.c -CONTIKI_TARGET_SOURCEFILES += sensors.c leds.c +CONTIKI_TARGET_SOURCEFILES += platform.c leds-arch.c CONTIKI_TARGET_SOURCEFILES += $(BOARD_SOURCEFILES) CONTIKI_SOURCEFILES += $(CONTIKI_TARGET_SOURCEFILES) diff --git a/arch/platform/srf06-cc26xx/platform.c b/arch/platform/srf06-cc26xx/platform.c index ac44b5b0f..6737c056e 100644 --- a/arch/platform/srf06-cc26xx/platform.c +++ b/arch/platform/srf06-cc26xx/platform.c @@ -47,8 +47,8 @@ #include "ti-lib.h" #include "contiki.h" #include "contiki-net.h" -#include "leds.h" #include "lpm.h" +#include "dev/leds.h" #include "dev/gpio-hal.h" #include "dev/oscillators.h" #include "ieee-addr.h" @@ -84,7 +84,7 @@ unsigned short node_id = 0; void board_init(void); /*---------------------------------------------------------------------------*/ static void -fade(unsigned char l) +fade(leds_mask_t l) { volatile int i; int k, j; diff --git a/arch/platform/srf06-cc26xx/srf06/leds-arch.c b/arch/platform/srf06-cc26xx/srf06/leds-arch.c index 9de716b97..fba996b39 100644 --- a/arch/platform/srf06-cc26xx/srf06/leds-arch.c +++ b/arch/platform/srf06-cc26xx/srf06/leds-arch.c @@ -30,12 +30,12 @@ */ /*---------------------------------------------------------------------------*/ #include "contiki.h" -#include "dev/led.h" +#include "dev/leds.h" #include "dev/gpio-hal.h" #include /*---------------------------------------------------------------------------*/ -const led_t led_arch_leds[] = { +const leds_t leds_arch_leds[] = { { .pin = BOARD_IOID_LED_1, .negative_logic = false }, { .pin = BOARD_IOID_LED_2, .negative_logic = false }, { .pin = BOARD_IOID_LED_3, .negative_logic = false },