Hi there, I see we have had a few topics on this that even ended up in a due lib but not for these pins. I'm using the aruduino motor shield which uses these pins for pwm.
Firstly, does anyone know what the frequency is by default on these pins?
And secondly, des anyone know how to up it? I'm getting a very annoying whine ...
For the Due the frequency is 1000 I think. Its hard-wired in variant.h which is
not friendly - adding a setPWMFrequency() call would be a great idea.
Writing a version of analogWrite yourself is probably the way, substitute your
own frequency for TC_FREQUENCY (both 3 and 11 use TC peripherals, not PWM
peripherals, note).
On Unos/Megas etc the frequency of 3 and 11 is set by the prescaler value for
timer2.