bool32.risingfalling gate
bool32.pulse < short (if gate == 0)
bool32.pulse > long and < cancel
int32 current stage
spinner long hold start and short hold end,k-ticks
int tc;
outlet_short = 0;
outlet_long = 0;
if (inlet_gate) {
tc++;
if (tc < attr_long)
outlet_stage = 1;
else
outlet_stage = 2;
if (tc == attr_long)
outlet_long = 1;
} else
outlet_stage = 0;
if (!inlet_gate && tc) {
if (tc < attr_long)
outlet_short = 1;
tc = 0;
}