-
Notifications
You must be signed in to change notification settings - Fork 19
Wrong frequency #1
Comments
Hi @americodias Thanks for testing and using the library. I'm able to duplicate the bug, which seems to happen when freq = 9000-9999Hz I'll definitely spend time to investigate and fix this interesting bug. Hopefully, the culprit is something in the library, not in the chip. In the mean time, I'd appreciate if you can make some more tests to see where else the similar issue happens. Best, |
Hi, Already found and fixed the bug, the culprit is the so-called best-fit algorithm. I don't use it now and just use my simple calculation. Will publish a new version by tomorrow, with your contribution noted. Best Regards, ===
|
Hi @khoih-prog, That was fast! Thank you for creating this library and for the quick fix! I will use this library for an ongoing project and will let you know if I find any other issues. Kind regards, |
Hi @americodias The new RP2040_PW releases v1.0.1 has just been published Your contribution has been noted in Contributions and Thanks Thanks to the contributions of users like you, the library will have good chance to be better and better, with less and less bugs. Releases v1.0.1
|
Describe the bug
I'm getting wrong results.
Steps to Reproduce
I'm running a modified version of your PWM_Multi example on a Arduino Nano RP2040 Connect.
Expected behavior
9 kHz output
Actual behavior
I get 11.81kHz according to the oscilloscope.
However if I change the code to 10kHz for instance, I get 10kHz.
Debug log
Screenshots
Oscilloscope screenshot here.
The text was updated successfully, but these errors were encountered: