From e12675bb7b2a7f360f36b8af7937f527c5b0f924 Mon Sep 17 00:00:00 2001 From: Mark Niemann-Ross Date: Mon, 20 Nov 2023 11:59:25 -0800 Subject: [PATCH] add notes about primary and secondary PWM --- vignettes/articles/rpi_pwm.Rmd | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/vignettes/articles/rpi_pwm.Rmd b/vignettes/articles/rpi_pwm.Rmd index 32f3908..089a4bd 100644 --- a/vignettes/articles/rpi_pwm.Rmd +++ b/vignettes/articles/rpi_pwm.Rmd @@ -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)