Timed routing changes using 2 ints as time values

peakssound's icon

Hi there,

This seems like it would be easy, but I'm getting pretty stumped trying to build it.

I have a counter increasing in 16th notes. I'd like to have 2 ints that dictate how many beats to wait to increase a second counter. I'd like Max to toggle between these values, like some sort of flipflop.

As an example, say my counter is increasing, and I set the 2 int divisions to 3 and 4. I'd like to route the counter like: 1,2,3 4,5,6,7, 8,9,10 11,12,13,14.

I'd attach an example, however I don't think it would be much help in the state that it's in right now.
Any help would be very appreciated... thank you.

P

broc's icon

Can be done with 2 counters and gate.

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

peakssound's icon

That does it!! Thanks Broc!