Fixes that seemed necessary for Seeeduino XIAO RP2040, based on https://github.com/jjsch-dev/Encoder/ and PaulStoffregen#85
Encoder counts pulses from quadrature encoded signals, which are commonly available from rotary knobs, motor or shaft sensors and other position sensors.
http://www.pjrc.com/teensy/td_libs_Encoder.html