aboutsummaryrefslogtreecommitdiffstats
path: root/os/hal/ports/NRF5
diff options
context:
space:
mode:
authorStephane D'Alu <sdalu@sdalu.com>2016-07-10 19:15:46 +0200
committerStephane D'Alu <sdalu@sdalu.com>2016-07-10 19:15:46 +0200
commit321ec844af3b1e7a23c94bce65bc8aa13ef1e09e (patch)
tree1eea159a7f4fd9e8cb27d41405fbd1f719c74441 /os/hal/ports/NRF5
parent5d1b4d1d776f4e32b5f238a977172800417727bf (diff)
downloadChibiOS-Contrib-321ec844af3b1e7a23c94bce65bc8aa13ef1e09e.tar.gz
ChibiOS-Contrib-321ec844af3b1e7a23c94bce65bc8aa13ef1e09e.tar.bz2
ChibiOS-Contrib-321ec844af3b1e7a23c94bce65bc8aa13ef1e09e.zip
moved GPT to LLD
Diffstat (limited to 'os/hal/ports/NRF5')
-rw-r--r--os/hal/ports/NRF5/LLD/hal_gpt_lld.c (renamed from os/hal/ports/NRF5/NRF51822/hal_gpt_lld.c)5
-rw-r--r--os/hal/ports/NRF5/LLD/hal_gpt_lld.h (renamed from os/hal/ports/NRF5/NRF51822/hal_gpt_lld.h)4
-rw-r--r--os/hal/ports/NRF5/LLD/hal_st_lld.h1
-rw-r--r--os/hal/ports/NRF5/NRF51822/platform.mk4
-rw-r--r--os/hal/ports/NRF5/NRF52832/platform.mk4
5 files changed, 12 insertions, 6 deletions
diff --git a/os/hal/ports/NRF5/NRF51822/hal_gpt_lld.c b/os/hal/ports/NRF5/LLD/hal_gpt_lld.c
index 3fb14dd..e850e31 100644
--- a/os/hal/ports/NRF5/NRF51822/hal_gpt_lld.c
+++ b/os/hal/ports/NRF5/LLD/hal_gpt_lld.c
@@ -15,8 +15,8 @@
*/
/**
- * @file NRF51x22/gpt_lld.c
- * @brief NRF51x22 GPT subsystem low level driver source.
+ * @file NRF5/LLD/hal_gpt_lld.c
+ * @brief NRF5 GPT subsystem low level driver source.
*
* @addtogroup GPT
* @{
@@ -102,6 +102,7 @@ static uint8_t prescaler(uint16_t freq)
static void gpt_lld_serve_interrupt(GPTDriver *gptp) {
gptp->tim->EVENTS_COMPARE[gptp->cc_int] = 0;
+ (void)gptp->tim->EVENTS_COMPARE[gptp->cc_int];
if (gptp->state == GPT_ONESHOT)
gptp->state = GPT_READY; /* Back in GPT_READY state. */
gptp->config->callback(gptp);
diff --git a/os/hal/ports/NRF5/NRF51822/hal_gpt_lld.h b/os/hal/ports/NRF5/LLD/hal_gpt_lld.h
index 5ce7a95..4173a3a 100644
--- a/os/hal/ports/NRF5/NRF51822/hal_gpt_lld.h
+++ b/os/hal/ports/NRF5/LLD/hal_gpt_lld.h
@@ -15,8 +15,8 @@
*/
/**
- * @file NRF51x22/gpt_lld.h
- * @brief NRF51x22 GPT subsystem low level driver header.
+ * @file NRF5/LLD/gpt_lld.h
+ * @brief NRF5 GPT subsystem low level driver header.
*
* @addtogroup GPT
* @{
diff --git a/os/hal/ports/NRF5/LLD/hal_st_lld.h b/os/hal/ports/NRF5/LLD/hal_st_lld.h
index 9d67ce9..7073e12 100644
--- a/os/hal/ports/NRF5/LLD/hal_st_lld.h
+++ b/os/hal/ports/NRF5/LLD/hal_st_lld.h
@@ -124,6 +124,7 @@
#error "Invalid IRQ priority assigned to ST driver"
#endif
+
/*===========================================================================*/
/* Driver data structures and types. */
/*===========================================================================*/
diff --git a/os/hal/ports/NRF5/NRF51822/platform.mk b/os/hal/ports/NRF5/NRF51822/platform.mk
index 9ddbeee..8631487 100644
--- a/os/hal/ports/NRF5/NRF51822/platform.mk
+++ b/os/hal/ports/NRF5/NRF51822/platform.mk
@@ -26,7 +26,7 @@ ifneq ($(findstring HAL_USE_ADC TRUE,$(HALCONF)),)
PLATFORMSRC += ${CHIBIOS_CONTRIB}/os/hal/ports/NRF5/NRF51822/hal_adc_lld.c
endif
ifneq ($(findstring HAL_USE_GPT TRUE,$(HALCONF)),)
-PLATFORMSRC += ${CHIBIOS_CONTRIB}/os/hal/ports/NRF5/NRF51822/hal_gpt_lld.c
+PLATFORMSRC += ${CHIBIOS_CONTRIB}/os/hal/ports/NRF5/LLD/hal_gpt_lld.c
endif
ifneq ($(findstring HAL_USE_WDG TRUE,$(HALCONF)),)
PLATFORMSRC += ${CHIBIOS_CONTRIB}/os/hal/ports/NRF5/LLD/hal_wdg_lld.c
@@ -51,7 +51,7 @@ PLATFORMSRC = ${CHIBIOS}/os/hal/ports/common/ARMCMx/nvic.c \
${CHIBIOS_CONTRIB}/os/hal/ports/NRF5/NRF51822/hal_ext_lld.c \
${CHIBIOS_CONTRIB}/os/hal/ports/NRF5/NRF51822/hal_i2c_lld.c \
${CHIBIOS_CONTRIB}/os/hal/ports/NRF5/NRF51822/hal_adc_lld.c \
- ${CHIBIOS_CONTRIB}/os/hal/ports/NRF5/NRF51822/hal_gpt_lld.c \
+ ${CHIBIOS_CONTRIB}/os/hal/ports/NRF5/LLD/hal_gpt_lld.c \
${CHIBIOS_CONTRIB}/os/hal/ports/NRF5/LLD/hal_wdg_lld.c \
${CHIBIOS_CONTRIB}/os/hal/ports/NRF5/LLD/hal_rng_lld.c \
${CHIBIOS_CONTRIB}/os/hal/ports/NRF5/NRF51822/hal_pwm_lld.c \
diff --git a/os/hal/ports/NRF5/NRF52832/platform.mk b/os/hal/ports/NRF5/NRF52832/platform.mk
index fd3912c..57ae88d 100644
--- a/os/hal/ports/NRF5/NRF52832/platform.mk
+++ b/os/hal/ports/NRF5/NRF52832/platform.mk
@@ -12,6 +12,9 @@ endif
ifneq ($(findstring HAL_USE_SERIAL TRUE,$(HALCONF)),)
PLATFORMSRC += ${CHIBIOS_CONTRIB}/os/hal/ports/NRF5/LLD/hal_serial_lld.c
endif
+ifneq ($(findstring HAL_USE_GPT TRUE,$(HALCONF)),)
+PLATFORMSRC += ${CHIBIOS_CONTRIB}/os/hal/ports/NRF5/LLD/hal_gpt_lld.c
+endif
ifneq ($(findstring HAL_USE_WDG TRUE,$(HALCONF)),)
PLATFORMSRC += ${CHIBIOS_CONTRIB}/os/hal/ports/NRF5/LLD/hal_wdg_lld.c
endif
@@ -24,6 +27,7 @@ PLATFORMSRC = ${CHIBIOS}/os/hal/ports/common/ARMCMx/nvic.c \
${CHIBIOS_CONTRIB}/os/hal/ports/NRF5/LLD/hal_pal_lld.c \
${CHIBIOS_CONTRIB}/os/hal/ports/NRF5/LLD/hal_serial_lld.c \
${CHIBIOS_CONTRIB}/os/hal/ports/NRF5/LLD/hal_st_lld.c \
+ ${CHIBIOS_CONTRIB}/os/hal/ports/NRF5/LLD/hal_gpt_lld.c \
${CHIBIOS_CONTRIB}/os/hal/ports/NRF5/LLD/hal_wdg_lld.c \
${CHIBIOS_CONTRIB}/os/hal/ports/NRF5/LLD/hal_rng_lld.c
endif