Closed ltwin8 closed 1 year ago
Sorry, but setting arbitrary PWM frequencies is not possible. You can try setting a lower main clock frequency (something lower than the default 16 MHz) and play around with the TCA0.SPLIT.CTRLA
register to see what you can achieve.
hello, is it possible to change analogWriteFrequency(kHz) to accept Hz?
to avoid bricking existing code it could be like if value <=64 interpret as kHz, else interpret as Hz
PWM frequencys below 1 kHz would be useful in some cases like driving lighting to avoid high frequency and allow for slower edges (EMI friendlier)