|
@ -28,8 +28,8 @@ You can set the frequency and duty cycle using:: |
|
|
>>> pwm12.duty(512) |
|
|
>>> pwm12.duty(512) |
|
|
|
|
|
|
|
|
Note that the duty cycle is between 0 (all off) and 1023 (all on), with 512 |
|
|
Note that the duty cycle is between 0 (all off) and 1023 (all on), with 512 |
|
|
being a 50% duty. If you print the PWM object then it will tell you its current |
|
|
being a 50% duty. Values beyond this min/max will be clipped. If you |
|
|
configuration:: |
|
|
print the PWM object then it will tell you its current configuration:: |
|
|
|
|
|
|
|
|
>>> pwm12 |
|
|
>>> pwm12 |
|
|
PWM(12, freq=500, duty=512) |
|
|
PWM(12, freq=500, duty=512) |
|
|