PWM frequency
-
I'm a little confused by the documentation.
It states thatpwm = PWM(0, frequency=5000) # use PWM timer 0, with a frequency of 50KHzwill generate a PWM object with a frequency of 50 kHz. Further down the docs state that:frequency is an integer from 1 to 19455 Hz.
I need the frequency to be 25 kHz, is this possible with the Wipy or Lopy?
-
@RobTuDelft The comment in the example is wrong. Maximum is 19455. For an input value between 19456 and 19531 you'll get 19531 Hz. Generally, the precision is low at the higher frequencies. So specifying a value of 19000 give 19011 Hz, 19200 -> 19230. So it looks as if the "real" periods are multiples of a small value like 200 ns.
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login