Go Down

Topic: Suggestion: Make analogwrite compatible with 8,9,10-bits PWM (Read 1 time) previous topic - next topic


I stumbled upon a problem when I switched to IDE 0022:


analogWrite is now incompatible with 9 or 10-bits PWM.   

suggestion is to implement multiple PWM modes (higher bit resolution, different prescalers, perhaps even different PWM modes -fast vs phase correct) in the Arduino code.   
Default settings could be what it is today, but it shouldn't be too hard to implement a few switches for advanced users.


analogWrite is now incompatible with 9 or 10-bits PWM.   

Are you on a MEGA?  The normal arduino only has one 16-bit timer; I don't see how the 8 bit timers are supposed to support 9 or 10bit PWM.

In any case, changing timer modes and expecting the predefined functions that use those timers to continue to operate correctly seems ... overly optimistic.

Go Up

Please enter a valid email to subscribe

Confirm your email address

We need to confirm your email address.
To complete the subscription, please click the link in the email we just sent you.

Thank you for subscribing!

via Egeo 16
Torino, 10131