docs: Update pyb.Timer.rst to fix pulse widths that exceed the period.
This commit is contained in:
parent
cb0fc063ed
commit
b57b56f293
|
@ -110,8 +110,8 @@ Methods
|
|||
PWM Example::
|
||||
|
||||
timer = pyb.Timer(2, freq=1000)
|
||||
ch2 = timer.channel(2, pyb.Timer.PWM, pin=pyb.Pin.board.X2, pulse_width=210000)
|
||||
ch3 = timer.channel(3, pyb.Timer.PWM, pin=pyb.Pin.board.X3, pulse_width=420000)
|
||||
ch2 = timer.channel(2, pyb.Timer.PWM, pin=pyb.Pin.board.X2, pulse_width=8000)
|
||||
ch3 = timer.channel(3, pyb.Timer.PWM, pin=pyb.Pin.board.X3, pulse_width=16000)
|
||||
|
||||
.. method:: timer.counter([value])
|
||||
|
||||
|
|
Loading…
Reference in New Issue