7 years, 1 month ago.

FastPwm.h and .cpp for nordic semiconductor

I was wondering if you have the fastpwm.h and fastpwm.cpp for nordic semiconductor

Repository: FastPWM

1 Answer

7 years, 1 month ago.

Something seems to have gone wrong here. But FastPWM does not support the Nordic MCUs. Actually something I can have a look at, but no time frame I can promise :). (Since it is just whenever I feel like working on it).

I had a look at it. First of all, it is ridiculously complicated to generate a PWM signal on the NRF51822. The mbed library needs to use three different peripherals and software time (so PwmOut on an NRF51822 relies on interrupts being handled, it is somewhere halfway between software PWM and hardware PWM) just to generate a single PWM output.

Nordic's own library does manage to do it without the interrupts, so it runs independent of what the CPU is doing, which is good. But it consumes even more hardware resources.

Conclusion is that I am not going to add some kind of half software PWM to FastPWM, since that will never actually run fast. I would like to have a further look at Nordic's own solution, but it seems to be closed source. So I might be able to make the same they did, but maybe not. And if I do finish it, it might also be a standalone library since I am a bit afraid it is going to be large.

posted by Erik - 19 Feb 2017