Skip to content

Commit 42d4653

Browse files
committed
docs: Update analog IO guide PWM to use A1 pin.
1 parent 6eab1d7 commit 42d4653

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

docs/programming_guide/02_analog_io.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -333,18 +333,18 @@ and setup as with the DAC:
333333

334334
Connect the components to your board as follows:
335335

336-
.. image:: images/02_analog_io_figure_2.png
336+
.. image:: images/02_analog_io_figure_3.png
337337

338338
- The short leg (cathode) of the LED connects to one end of the resistor.
339339
- The other end of the resistor connects to the ground or GND pin of the board.
340-
- The long leg (anode) of the LED connects to a PWM output of your board. You might need to check your board's documentation to find these pins, but typically any digital output capable pin will work.
340+
- The long leg (anode) of the LED connects to a PWM output of your board. You might need to check your board's documentation to find these pins, but typically any digital output capable pin will work. Note that on Circuit Playground Express and Metro M0 Express you *can't* use pin A0 and need to switch to pin A1!
341341

342342
Now at the REPL import the :py:mod:`pulseio` and :py:mod:`board` module to
343343
create an instance of the :py:class:`pulseio.PWMOut` class:
344344

345345
>>> import board
346346
>>> import pulseio
347-
>>> led = pulseio.PWMOut(board.A0)
347+
>>> led = pulseio.PWMOut(board.A1)
348348

349349
Just like with using analog inputs and outputs you need to specify the board pin
350350
as a parameter to the :py:class:`pulseio.PWMOut` class initializer. However
Binary file not shown.
Loading

0 commit comments

Comments
 (0)