joystick joy in gen~

mizu's icon

Hi all

trying to solve that in gen~... for a mechanical joystick with recall at his center to vary an input in + or - ( something like a pitchbend wheel ). How to reset an accum if i need to clamp the output ? Without to wait the accum to return to a usable value and without to return to the input value ? Surely a simple way, but i turn crazy around it... nb: the goal is to use that in a Daisypatch, i need to stay in gen~ with a MIDI input.

Max Patch
Copy patch and select New From Clipboard in Max.

i'm not aware with codebox, i imagine an if then else should solve :-) i must go into that text galaxy

best

michel