Lot of stuff here. Mostly to prepare for v3 hardware support and to avoid more class and code bloat.
v3 foot switches are connected to ADC inputs instead of GPIO as they were for v1 and v2. Very cumbersome having different code just because of how a switch is triggered. This attempts to make that somewhat better. a gpio_input or adc_input argument given to the Footswitch constructor (likely from the config file), determines which type of class to use for detecting switch events (GpioSwitch or AnalogSwitch).
EncoderSwitch no longer needed.
SwitchState added so all code can reference a common enum for switch state.
TapTempo added to provide tap tempo calculation to either type of switch. No code consumes that yet, but could easily do so via Footswitch.get_tap_tempo()
EncoderMidiControl added for tweak knob style controllers via encoder hardware (a concept new for v3)
Lot of stuff here. Mostly to prepare for v3 hardware support and to avoid more class and code bloat.
v3 foot switches are connected to ADC inputs instead of GPIO as they were for v1 and v2. Very cumbersome having different code just because of how a switch is triggered. This attempts to make that somewhat better. a gpio_input or adc_input argument given to the Footswitch constructor (likely from the config file), determines which type of class to use for detecting switch events (GpioSwitch or AnalogSwitch).
EncoderSwitch no longer needed.
SwitchState added so all code can reference a common enum for switch state.
TapTempo added to provide tap tempo calculation to either type of switch. No code consumes that yet, but could easily do so via Footswitch.get_tap_tempo()
EncoderMidiControl added for tweak knob style controllers via encoder hardware (a concept new for v3)