Skip to content
Discussion options

You must be logged in to vote

Also another reason to note the warning at the top of the latest documentation page:

This is the documentation for the latest development branch of MicroPython and may refer to features that are not available in released versions. If you are looking for the documentation for a specific release, use the drop-down menu on the left and select the desired version.

The examples in the v1.20.0 RP2 PWM docs work as expected with v1.2.0:

from machine import Pin, PWM

pwm0 = PWM(Pin(0))      # create PWM object from a pin
pwm0.freq()             # get current frequency
pwm0.freq(1000)         # set frequency
pwm0.duty_u16()         # get current duty cycle, range 0-65535
pwm0.duty_u16(200)      #…

Replies: 6 comments 3 replies

Comment options

You must be logged in to vote
3 replies
@FilipSLO
Comment options

@FilipSLO
Comment options

@robert-hh
Comment options

Comment options

You must be logged in to vote
0 replies
Answer selected by FilipSLO
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3 participants
Converted from issue

This discussion was converted from issue #12156 on August 04, 2023 06:29.