Changes for version 3.1802 - 2026-07-05

  • Fixed pwm() wrongly dying on the Pi 5 / RP1. The pin-18 PWM guard compared get_alt() against PWM_OUT (2), which only matched the legacy boards by coincidence (PWM_OUT == ALT5); GPIO18 reads back as ALT3 (7) on the Pi 5. The guard now expects the board-appropriate alt function (ALT3 on the RP1, ALT5 otherwise)
  • t/15-pwm.t now calls pwm() while the pin is in PWM mode (it previously only set/read the mode), so the dist regression-guards the pin-18 guard itself; switched its magic pin-mode integers to RPi::Const names
  • pwm() POD now documents the Pi 5 / RP1 measurement note: at a given range the RP1 PWM runs slower, so RC-filtered ADC feedback carries more ripple and a single async sample can read several percent off (average samples, raise the frequency, or filter more for a stable reading)
  • Added t/10-validation.t: ungated, HW-free coverage of every argument-validation die/croak (new/mode/write/pull/pwm-root/ set_interrupt/background_interrupt/interrupt_set) plus the comment/num accessors, runnable without a Pi via NO_BOARD

Modules

Access and manipulate Raspberry Pi GPIO pins