Cool, low budget hack requiring almost no additional hardware! The author states that "the signal is too strong for our input and goes off-scale, making it almost impossible to reliably detect pedal press/release events". Since the two waveforms are visually quite distinct, it is probably possible to correlate the incoming signal with reference on and off waveforms to detect a state change reliably without using hand-crafted heuristics.