Only output 1 Bang
I have a homemade OSC controller that occasionally outputs the same value twice. I have buttons on my controller, and I am using a route object so that a bang in max is only triggered on the up press (o) of my triggers and not the down press (1). Still though, some times two bangs are triggered, which I guess is because of some fault wiring in my controller. Is there any sort of "debouncing" that works when the controller is only putting out 1s and 0s. bangbang isn't working for me here because the controller is only putting out 1s and 0s, right after each other. Thanks
...how about the change object?
Thank you for the suggestion. The reason the change will not work is the same reason the route does not work. My controller is sometimes rapidly putting out two messages instead of one. (i.e. it bangs twice very quickly instead of once) I want to prevent that by having the second bang ignored somehow...
...how about the onebang object?
The problem I have with the onebang is that, because my controller puts out only on/off messages, it will not work.
When the switch is double triggered it "sometimes" sends out an on, than an off, than an on and off again. So the one bang couldn't selectively route things correctly for me.
see below
okay, that's important information that we didn't get the first time, hehe.
Please show us your patch along with like a [print] of your controller information.
It sounds like you need normal "debouncing", so it could be a straight up electrical problem with the controller, but we can't really tell without seeing the patch.
And if double-triggering is your problem, how about onebang combined with delay?
Ha!
There it is, I think that delay will work great. I sometime have problems coming up with creative solutions. Thank you @Christopher and @Wetterberg. Really appreciate it.
It very well could be an electrical problem, this is for an Arduino based controller and I think it is giving me double values.
ignore
I'm not a hundred percent sure but I think there is a debounce example coming with the arduino software. You might want to solve the problem at the source(or nearer to it).
Yes, there are several instances of debouncing techniques included with Arduino. Unfortunately I am using Firmata which would not make it easy to incorporate those.