Skip to content

Commit

Permalink
add notes about primary and secondary PWM
Browse files Browse the repository at this point in the history
  • Loading branch information
mnr committed Nov 20, 2023
1 parent a9ae0a9 commit e12675b
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions vignettes/articles/rpi_pwm.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,16 @@ The Raspberry Pi exposes two PWM channels from the Broadcom chip. These
appear on lines which also supply GPIO connections and so the Broadcom
ALT functions need to be called.

- PWM0 appears on board pins 12 (GPIO18) and 32 (GPIO12).
- PWM0 appears on board pin 32 (GPIO 12) and secondarily on board pin
12 (GPIO18).

- PWM1 appears on board pins 33 (GPIO13) and 35 (GPIO19).
- PWM1 appears on board pin 33 (GPIO13) and secondarily on board pin
35 (GPIO19).

This causes a confusing situation in two ways:

- Don't confuse board pin 12 with GPIO12 (board pin 32). Both are
connected to BCM PWM0
connected to BCM PWM0 but via different pin numbering schemes.
- If you want to use two PWM channels, there are only certain
combinations of pins that will provide the two channels. These
combinations are board pins (12,33), (32,33), (12,35), or (32,35)
Expand Down

0 comments on commit e12675b

Please sign in to comment.