Going from repetitive bangs to on/off
Hello,
i am working on a project right now, which is a grid (matrix ctrl) that transfers to a series of bangs. The grid is an interface which will let me control a series of motors in a physical setup (probably gonna use a raspberry pi to communicate between max and the motors). I want the bangs to transfer to an on/off state, so i can control metronomes or some other loops while the corresponding cell in the matrixctrl is active.
I thought about using a bucket maybe? Idk what could work, just putting a toggle causes issues because the toggle keeps turning on and off at every bang.
Here is the patch. I don't think the presets are necessary to solve this problem, but here is one of them if you want to experiment in a coll object.
1, 0 0 1 1 0 1 2 0 1 3 0 1 4 0 1 0 1 1 1 1 0 2 1 0 3 1 0 4 1 1 0 2 1 1 2 0 2 2 0 3 2 0 4 2 1 0 3 1 1 3 0 2 3 0 3 3 0 4 3 1 0 4 1 1 4 1 2 4 1 3 4 1 4 4 1;
Each cell corresponds to 3 values: x, y, on/off. The x and y coordinates start at 0. The grid starts in the top left corner, so it goes left to right and up to down.
counter counting to 2
"I want the bangs to transfer to an on/off state"
If I understand correctly, if a cell = 1
each time it gets recalled corresponding receiver should get toggled .
Is that correct ?
And if you recall different matrix set in the meantime,
one toggle could remain ON forever, if corresponding matrix cell
remains 0.
it does not matter if you use counter or toggle or whatever else
on receiver side.
"Going from repetitive bangs to on/off/I want the bangs to transfer to an on/off state" => this is what it made me think of :-) :

Then I saw your patch and got lost ...
You may be a bit more specific ?
Heres another explanation: i want a system that will test if there is a bang sent corresponding to one cell. If, lets say after 100 ms, there is no bang sent, the toggle will switch to Off. If there is a bang sent at that time, the toggle stays on.
I hope this helps
Re. the on/off logic, I came up with this :

Wouldn't a simple monostable do?
There are too many unknown conditions here.
what means after 100ms ? who is starting that 100ms count ?
you say if no bang after 100ms toggle remains ON?
what turned it on ?
let's say you want to detect if there are bang repetitions faster than 100ms ...
and if not reverse toggle state ?
can be done in several ways, you receive a bang and measure if
more bangs get received within 100ms.
If not output a bang, if yes then cancel.
but what if you receive several fast bangs
30ms 90ms 101ms 50ms 44ms 101ms
do both 101ms bangs trigger the toggle ?
or none of them ?
do you group bangs into pairs and measure interval ?
here few examples
Thank you everyone for your multiple answers, i ended up reworking the patch in its entirety and use a grid of toggles instead of a MatrixCtrl. That being said i will keep your ideas in mind if i ever use a Matrix Ctrl in the future.