.dutycycle Property
Function: |
For the currently selected PWM channel (selection is made through pwm.num), indicates the duty cycle. |
Type: |
Real |
Value Range: |
0-100, default=0. |
See Also: |
--- |
Details
The duty cycle is the proportion of "on" time for the channel, where 0 is always off and 100 is always on.
After setting or modifying the duty cycle of any given PWM channel, you need to call pwm.update or pwm.updateall for the changes to take effect.