samd51 PPW capture

I tried to reply to but it says it's too old. I'm trying to get SAMD51 (adafruit m4 feather express) to capture period and pulse width (PPW) on pin A4 based on modifying the sketch in the old thread. My attempt (it just prints 0 0 for period and pulse width) with PWM test from pin 10 is at

I have an older PPW sketch that works on ZERO.

Never mind. Fix was A4 is really PORTA 4 (not PORTB). working now. git upated

Hi mantoui,

Sorry about the confusion. As you mention, in the earlier post I incorrectly said that the Itsy Bitsy M4's A4 pin is on PB04, when it's actually on PA04.