This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

[bug report] low_power_pwm.c (Low-Power PWM Example)

In the Keil Pack nRF_Libraries V3.10 [SDK V10.0.0?] (Low-Power PWM Example)

Not a big Bug, but an inconvenience all the same.

low_power_pwm.c line 165


ret_code_t low_power_pwm_start(low_power_pwm_t * p_pwm_instance, uint32_t leds_pin_bit_mask)
{
ASSERT(p_pwm_instance->pwm_state == NRF_DRV_STATE_INITIALIZED);
p_pwm_instance->evt_type = LOW_POWER_PWM_EVENT_PERIOD;
pwm_timeout_handler(p_pwm_instance);
p_pwm_instance->pwm_state = NRF_DRV_STATE_POWERED_ON;
p_pwm_instance->bit_mask = leds_pin_bit_mask; //karel added
return NRF_SUCCESS;
}


There is no line to set the bit mask, so I added a line to my own code (BOLD above).
Also in the edit[(Low-Power PWM Example WRONG) (led_softblink_s110_pca10028 RIGHT)] main.c the LEDs functionality is set in/via the
static void leds_init(void) {...}
function.

Related