Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
NRF52 PwmOut inverted #7707
Switched from mbed-os-5.7 to mbed-os-5.9, suddenly PwmOut behaved inverted, meaning
accordingly opposite cases for
Note: LED circuit is active-high.
Issue request type
[ ] Question
If you are using other board, then please let me know about it.
No, I am using my own board where the NRF52832 serves as the main processor and there the LED is connected active high.
But I see where this inverted behavior comes from, someone implemented PwmOut based on the DK and applied the active-low logic from this specific hardware?
In my opinion, this should be changed to non-inverted, what do you think? One reason might be to use PWM not for LED, but for motor control, etc, where you can not always expect active-low logic :)
As this might not be yet specified (will be!), should follow what the rest of the boards do. They do write 0 in their init:
I can't locate this for NRF52, I can see obj->percent is set to 0 but not used anywhere during
The main issue here is the regression in the HAL, @MateuszMaz can you check which commit broke this?