I think it would be sufficient to call `__CtrlReadLatch()` instead of `__CtrlPeekButtons()`.  I'm not sure if the PSP actually resets the latch (could test by reading the latch right after update/shutdown and seeing if it returns anything.)

`__CtrlReadLatch()` returns a bitfield of newly pressed buttons since last `__CtrlReadLatch()`.  If a button is held down it won't return it, but if a button is pressed again it will return it.  It uses the game's sampling frequency which is likely to be correct.

-[Unknown]