From 234c9f3688f0c875d30cee5c521fbff2e4edae27 Mon Sep 17 00:00:00 2001 From: Glenn Ruben Bakke Date: Wed, 17 May 2017 19:49:41 +0200 Subject: [PATCH] nrf5/drivers/softpwm: Renaming pwm_init to softpwm_init to not collide on symbol name with pwm_init in nrf52 machine PWM object. --- nrf5/drivers/softpwm.c | 2 +- nrf5/drivers/softpwm.h | 2 +- nrf5/modules/music/modmusic.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/nrf5/drivers/softpwm.c b/nrf5/drivers/softpwm.c index 5623c279a5..41425a6e2e 100644 --- a/nrf5/drivers/softpwm.c +++ b/nrf5/drivers/softpwm.c @@ -79,7 +79,7 @@ static const pwm_events OFF_EVENTS = { #define active_events MP_STATE_PORT(pwm_active_events) #define pending_events MP_STATE_PORT(pwm_pending_events) -void pwm_init(void) { +void softpwm_init(void) { active_events = &OFF_EVENTS; pending_events = NULL; } diff --git a/nrf5/drivers/softpwm.h b/nrf5/drivers/softpwm.h index fb8167448f..a73c15cd85 100644 --- a/nrf5/drivers/softpwm.h +++ b/nrf5/drivers/softpwm.h @@ -1,7 +1,7 @@ #ifndef __MICROPY_INCLUDED_LIB_PWM_H__ #define __MICROPY_INCLUDED_LIB_PWM_H__ -void pwm_init(void); +void softpwm_init(void); void pwm_start(void); void pwm_stop(void); diff --git a/nrf5/modules/music/modmusic.c b/nrf5/modules/music/modmusic.c index 6916ba6baa..7e8ff30dbd 100644 --- a/nrf5/modules/music/modmusic.c +++ b/nrf5/modules/music/modmusic.c @@ -77,7 +77,7 @@ extern uint32_t ticks; STATIC uint32_t start_note(const char *note_str, size_t note_len, const pin_obj_t *pin); void microbit_music_init0(void) { - pwm_init(); + softpwm_init(); ticker_init(microbit_music_tick); ticker_start(); pwm_start();