Skip to content

Commit b57b56f

Browse files
peterhinchdpgeorge
authored andcommitted
docs: Update pyb.Timer.rst to fix pulse widths that exceed the period.
1 parent cb0fc06 commit b57b56f

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

docs/library/pyb.Timer.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -110,8 +110,8 @@ Methods
110110
PWM Example::
111111
112112
timer = pyb.Timer(2, freq=1000)
113-
ch2 = timer.channel(2, pyb.Timer.PWM, pin=pyb.Pin.board.X2, pulse_width=210000)
114-
ch3 = timer.channel(3, pyb.Timer.PWM, pin=pyb.Pin.board.X3, pulse_width=420000)
113+
ch2 = timer.channel(2, pyb.Timer.PWM, pin=pyb.Pin.board.X2, pulse_width=8000)
114+
ch3 = timer.channel(3, pyb.Timer.PWM, pin=pyb.Pin.board.X3, pulse_width=16000)
115115

116116
.. method:: timer.counter([value])
117117

0 commit comments

Comments
 (0)