How do I synchronize metronomes going at different speeds? (Newbie question)

Dec 14, 2006 at 11:48pm

How do I synchronize metronomes going at different speeds? (Newbie question)

I’m currently trying to have 3 different metronomes running at the same time but all controlled by some strict timing procedure so that they will be synced up when playing.

Metronome 1=n
Metronome 2=n/2
Metronome 3=n/4

The patch I have included does not work and they slowly go out of sync with each other and then back in sync again.

Any suggestions?

Thanks

#29233
Dec 15, 2006 at 12:01am

If you don’t mind using third party externals, you might want to check out my samm~ (sample accurate multiple metronomes) external. It does precisely what you described.

http://www.sarc.qub.ac.uk/~elyon/LyonSoftware/MaxMSP/

Eric

#90833
Dec 15, 2006 at 12:08am

I definitely dont mind and will give it a go!

Thanks

#90834
Dec 15, 2006 at 10:42am

In this case I’d just have one master metronome at the fastest speed,
and use counter objects to bang on every 2nd, 4th, incoming bang.
On 15-Dec-2006, at 0:48, Rhys Perkins wrote:

> Metronome 1=n
> Metronome 2=n/2
> Metronome 3=n/4
>
> The patch I have included does not work and they slowly go out of
> sync with each other and then back in sync again.

————– http://www.bek.no/~pcastine/Litter/ ————-
Peter Castine +–> Litter Power & Litter Bundle for Jitter
Universal Binaries on the way
iCE: Sequencing, Recording &
Interface Building for |home | chez nous|
Max/MSP Extremely cool |bei uns | i nostri|
http://www.dspaudio.com/ http://www.castine.de

#90835
Dec 15, 2006 at 7:16pm

On Dec 14, 2006, at 4:48 PM, Rhys Perkins wrote:
> I’m currently trying to have 3 different metronomes running at the
> same time but all controlled by some strict timing procedure so
> that they will be synced up when playing.
>
> Metronome 1=n
> Metronome 2=n/2
> Metronome 3=n/4
>

This is a straightforward way to accomplish it with one metro and a
couple of counters.

max v2;
#N vpatcher 199 297 799 697;
#P button 274 120 15 0;
#N comlet (bang) reset counters to 1 on next bang;
#P inlet 274 73 15 0;
#N comlet (int) metro speed (period) in ms;
#P inlet 228 73 15 0;
#N comlet (bang) at metro speed/4;
#P outlet 338 315 15 0;
#N comlet (bang) at metro speed/2;
#P outlet 255 315 15 0;
#N comlet (bang) at metro speed;
#P outlet 180 315 15 0;
#P window setfont “Sans Serif” 9.;
#P newex 302 120 100 196617 loadmess carrybang;
#N comlet (int) 1 or 0 – start/stop metro;
#P inlet 180 73 15 0;
#N counter 1 4;
#X flags 1 0;
#P newobj 302 225 66 196617 counter 1 4;
#N counter 1 2;
#X flags 1 0;
#P newobj 219 225 66 196617 counter 1 2;
#P number 228 120 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P toggle 180 120 15 0;
#P newex 180 150 58 196617 metro 500;
#P connect 5 0 1 0;
#P connect 1 0 0 0;
#P connect 0 0 7 0;
#P connect 6 0 3 0;
#P connect 0 0 3 0;
#P connect 10 0 2 0;
#P connect 2 0 0 1;
#P connect 12 0 3 2;
#P connect 3 2 8 0;
#P connect 11 0 12 0;
#P connect 0 0 4 0;
#P connect 6 0 4 0;
#P connect 12 0 4 2;
#P connect 4 2 9 0;
#P pop;

—-
Steven M. Miller

Associate Professor of Contemporary Music
College of Santa Fe
Contemporary Music Program
1600 St. Michaels Drive
Santa Fe NM 87505
http://pubweb.csf.edu/~smill
(505) 473-6197

SFIFEM
Atrium Sound Space
OVOS

#90836
Dec 15, 2006 at 9:22pm

Quote: Dr. Spankenstein wrote on Thu, 14 December 2006 15:48
—————————————————-
> I’m currently trying to have 3 different metronomes running at the same time but all controlled by some strict timing procedure so that they will be synced up when playing.

Like:

#P window setfont “Sans Serif” 9.;
#P window linecount 1;
#P comment 198 253 100 196617 metro 3 = 4n;
#P button 176 251 15 0;
#P comment 156 302 100 196617 metro 2 = 2n;
#P button 136 302 15 0;
#P newex 130 65 66 196617 loadmess 60;
#P number 130 92 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 130 119 27 196617 * 4;
#P toggle 108 93 15 0;
#P button 108 341 15 0;
#P newex 108 179 66 196617 sel 0 1 2 3;
#P newex 108 151 76 196617 tempo 120 1 4;
#P comment 136 340 100 196617 metro 1 = n;
#P fasten 2 2 8 0 141 249 141 249;
#P fasten 2 2 10 0 141 223 181 223;
#P fasten 2 0 3 0 113 268 113 268;
#P fasten 2 0 8 0 113 269 141 269;
#P fasten 2 0 10 0 113 223 181 223;
#P connect 7 0 4 0;
#P connect 7 0 6 0;
#P fasten 2 3 10 0 155 223 181 223;
#P fasten 2 1 10 0 127 223 181 223;
#P connect 6 0 5 0;
#P connect 5 0 1 1;
#P connect 1 0 2 0;
#P connect 4 0 1 0;
#P window clipboard copycount 12;

?

mz

#90837
Dec 16, 2006 at 1:05am

Or even

#P user ezdac~ 264 90 308 123 0;
#P button 227 168 15 0;
#P button 173 168 15 0;
#P button 119 168 15 0;
#P window setfont “Sans Serif” 9.;
#P window linecount 1;
#P newex 227 144 36 196617 edge~;
#P newex 173 144 36 196617 edge~;
#P newex 119 144 36 196617 edge~;
#P newex 119 93 119 196617 el.samm~ 60 1 0.5 0.25;
#P comment 311 90 71 196617 < - turn me on;
#P connect 1 1 3 0;
#P connect 1 2 4 0;
#P connect 1 0 2 0;
#P connect 2 0 5 0;
#P connect 3 0 6 0;
#P connect 4 0 7 0;
#P window clipboard copycount 9;

?

Eric

#90838
Dec 16, 2006 at 1:28pm

Rhys Perkins wrote:
> I’m currently trying to have 3 different metronomes running at the
> same time but all controlled by some strict timing procedure so that
> they will be synced up when playing.
>
> Metronome 1=n Metronome 2=n/2 Metronome 3=n/4

Standard solution would be to use one master metro, the slowest one and
create subdivisions with delays…

Stefan

#P button 326 181 15 0;
#P button 309 181 15 0;
#P button 292 181 15 0;
#P button 275 181 15 0;
#P button 258 181 15 0;
#P button 241 181 15 0;
#P button 224 181 15 0;
#P button 207 181 15 0;
#P button 190 181 15 0;
#P button 173 181 15 0;
#P button 156 181 15 0;
#P button 139 181 15 0;
#P button 122 181 15 0;
#P button 105 181 15 0;
#P button 88 181 15 0;
#P window setfont “Sans Serif” 9.;
#P window linecount 1;
#N vpatcher 20 74 845 475;
#P window setfont “Sans Serif” 9.;
#P window linecount 0;
#P newex 172 127 52 196617 universal;
#P message 55 128 79 196617 send delay stop;
#P newex 55 108 36 196617 sel 0;
#P inlet 97 86 15 0;
#P outlet 616 230 15 0;
#P objectname out[15];
#P window linecount 1;
#P newex 641 153 35 196617 / 16.;
#P objectname /[15];
#P newex 616 201 13 196617 b;
#P objectname b[15];
#P newex 616 177 35 196617 delay;
#P objectname d[15];
#P outlet 578 230 15 0;
#P objectname out[14];
#P newex 603 153 35 196617 / 15.;
#P objectname /[14];
#P newex 578 201 13 196617 b;
#P objectname b[14];
#P newex 578 177 35 196617 delay;
#P objectname d[14];
#P outlet 540 230 15 0;
#P objectname out[13];
#P newex 565 153 35 196617 / 14.;
#P objectname /[13];
#P newex 540 201 13 196617 b;
#P objectname b[13];
#P newex 540 177 35 196617 delay;
#P objectname d[13];
#P outlet 502 230 15 0;
#P objectname out[12];
#P newex 527 153 35 196617 / 13.;
#P objectname /[12];
#P newex 502 201 13 196617 b;
#P objectname b[12];
#P newex 502 177 35 196617 delay;
#P objectname d[12];
#P outlet 464 230 15 0;
#P objectname out[11];
#P newex 489 153 35 196617 / 12.;
#P objectname /[11];
#P newex 464 201 13 196617 b;
#P objectname b[11];
#P newex 464 177 35 196617 delay;
#P objectname d[11];
#P outlet 426 230 15 0;
#P objectname out[10];
#P newex 451 153 35 196617 / 11.;
#P objectname /[10];
#P newex 426 201 13 196617 b;
#P objectname b[10];
#P newex 426 177 35 196617 delay;
#P objectname d[10];
#P outlet 388 230 15 0;
#P objectname out[9];
#P newex 413 153 35 196617 / 10.;
#P objectname /[9];
#P newex 388 201 13 196617 b;
#P objectname b[9];
#P newex 388 177 35 196617 delay;
#P objectname d[9];
#P outlet 350 230 15 0;
#P objectname out[8];
#P newex 375 153 35 196617 / 9.;
#P objectname /[8];
#P newex 350 201 13 196617 b;
#P objectname b[8];
#P newex 350 177 35 196617 delay;
#P objectname d[8];
#P outlet 312 230 15 0;
#P objectname out[7];
#P newex 337 153 35 196617 / 8.;
#P objectname /[7];
#P newex 312 201 13 196617 b;
#P objectname b[7];
#P newex 312 177 35 196617 delay;
#P objectname d[7];
#P outlet 274 230 15 0;
#P objectname out[6];
#P newex 299 153 35 196617 / 7.;
#P objectname /[6];
#P newex 274 201 13 196617 b;
#P objectname b[6];
#P newex 274 177 35 196617 delay;
#P objectname d[6];
#P outlet 236 230 15 0;
#P objectname out[5];
#P newex 261 153 35 196617 / 6.;
#P objectname /[5];
#P newex 236 201 13 196617 b;
#P objectname b[5];
#P newex 236 177 35 196617 delay;
#P objectname d[5];
#P outlet 198 230 15 0;
#P objectname out[4];
#P newex 223 153 35 196617 / 5.;
#P objectname /[4];
#P newex 198 201 13 196617 b;
#P objectname b[4];
#P newex 198 177 35 196617 delay;
#P objectname d[4];
#P outlet 160 230 15 0;
#P objectname out[3];
#P newex 185 153 35 196617 / 4.;
#P objectname /[3];
#P newex 160 201 13 196617 b;
#P objectname b[3];
#P newex 160 177 35 196617 delay;
#P objectname d[3];
#P outlet 122 230 15 0;
#P objectname out[2];
#P newex 147 153 35 196617 / 3.;
#P objectname /[2];
#P newex 122 201 13 196617 b;
#P objectname b[2];
#P newex 122 177 35 196617 delay;
#P objectname d[2];
#P outlet 84 230 15 0;
#P objectname out[1];
#P window linecount 0;
#P newex 109 153 35 196617 / 2.;
#P objectname /[1];
#P newex 84 201 13 196617 b;
#P objectname b[1];
#P newex 84 177 35 196617 delay;
#P objectname d[1];
#P window linecount 1;
#P newex 43 153 64 196617 metro 1000;
#P newex 97 108 64 196617 !/ 240000.;
#P inlet 43 86 15 0;
#P outlet 43 230 15 0;
#P objectname out[0];
#P connect 1 0 3 0;
#P connect 3 0 0 0;
#P connect 1 0 65 0;
#P connect 65 0 66 0;
#P fasten 3 0 4 0 48 173 89 173;
#P fasten 5 0 4 0 89 222 82 222 82 173 89 173;
#P connect 4 0 5 0;
#P fasten 3 0 7 0 48 225 89 225;
#P connect 5 0 7 0;
#P connect 64 0 2 0;
#P connect 2 0 3 1;
#P fasten 2 0 6 0 102 147 114 147;
#P connect 6 0 4 1;
#P fasten 3 0 8 0 48 173 127 173;
#P fasten 9 0 8 0 127 222 120 222 120 173 127 173;
#P connect 8 0 9 0;
#P fasten 3 0 11 0 48 225 127 225;
#P connect 9 0 11 0;
#P fasten 2 0 10 0 102 147 152 147;
#P connect 10 0 8 1;
#P fasten 3 0 12 0 48 173 165 173;
#P fasten 13 0 12 0 165 222 158 222 158 173 165 173;
#P connect 12 0 13 0;
#P fasten 3 0 15 0 48 225 165 225;
#P connect 13 0 15 0;
#P connect 66 0 67 0;
#P fasten 2 0 14 0 102 147 190 147;
#P connect 14 0 12 1;
#P fasten 3 0 16 0 48 173 203 173;
#P fasten 17 0 16 0 203 222 196 222 196 173 203 173;
#P connect 16 0 17 0;
#P fasten 3 0 19 0 48 225 203 225;
#P connect 17 0 19 0;
#P fasten 2 0 18 0 102 147 228 147;
#P connect 18 0 16 1;
#P fasten 3 0 20 0 48 173 241 173;
#P fasten 21 0 20 0 241 222 234 222 234 173 241 173;
#P connect 20 0 21 0;
#P fasten 3 0 23 0 48 225 241 225;
#P connect 21 0 23 0;
#P fasten 2 0 22 0 102 147 266 147;
#P connect 22 0 20 1;
#P fasten 3 0 24 0 48 173 279 173;
#P fasten 25 0 24 0 279 222 272 222 272 173 279 173;
#P connect 24 0 25 0;
#P fasten 3 0 27 0 48 225 279 225;
#P connect 25 0 27 0;
#P fasten 2 0 26 0 102 147 304 147;
#P connect 26 0 24 1;
#P fasten 3 0 28 0 48 173 317 173;
#P fasten 29 0 28 0 317 222 310 222 310 173 317 173;
#P connect 28 0 29 0;
#P fasten 3 0 31 0 48 225 317 225;
#P connect 29 0 31 0;
#P fasten 2 0 30 0 102 147 342 147;
#P connect 30 0 28 1;
#P fasten 3 0 32 0 48 173 355 173;
#P fasten 33 0 32 0 355 222 348 222 348 173 355 173;
#P connect 32 0 33 0;
#P fasten 3 0 35 0 48 225 355 225;
#P connect 33 0 35 0;
#P fasten 2 0 34 0 102 147 380 147;
#P connect 34 0 32 1;
#P fasten 3 0 36 0 48 173 393 173;
#P fasten 37 0 36 0 393 222 386 222 386 173 393 173;
#P connect 36 0 37 0;
#P fasten 3 0 39 0 48 225 393 225;
#P connect 37 0 39 0;
#P fasten 2 0 38 0 102 147 418 147;
#P connect 38 0 36 1;
#P fasten 3 0 40 0 48 173 431 173;
#P fasten 41 0 40 0 431 222 424 222 424 173 431 173;
#P connect 40 0 41 0;
#P fasten 3 0 43 0 48 225 431 225;
#P connect 41 0 43 0;
#P fasten 2 0 42 0 102 147 456 147;
#P connect 42 0 40 1;
#P fasten 3 0 44 0 48 173 469 173;
#P fasten 45 0 44 0 469 222 462 222 462 173 469 173;
#P connect 44 0 45 0;
#P fasten 3 0 47 0 48 225 469 225;
#P connect 45 0 47 0;
#P fasten 2 0 46 0 102 147 494 147;
#P connect 46 0 44 1;
#P fasten 3 0 48 0 48 173 507 173;
#P fasten 49 0 48 0 507 222 500 222 500 173 507 173;
#P connect 48 0 49 0;
#P fasten 3 0 51 0 48 225 507 225;
#P connect 49 0 51 0;
#P fasten 2 0 50 0 102 147 532 147;
#P connect 50 0 48 1;
#P fasten 3 0 52 0 48 173 545 173;
#P fasten 53 0 52 0 545 222 538 222 538 173 545 173;
#P connect 52 0 53 0;
#P fasten 3 0 55 0 48 225 545 225;
#P connect 53 0 55 0;
#P fasten 2 0 54 0 102 147 570 147;
#P connect 54 0 52 1;
#P fasten 3 0 56 0 48 173 583 173;
#P fasten 57 0 56 0 583 222 576 222 576 173 583 173;
#P connect 56 0 57 0;
#P fasten 3 0 59 0 48 225 583 225;
#P connect 57 0 59 0;
#P fasten 2 0 58 0 102 147 608 147;
#P connect 58 0 56 1;
#P fasten 3 0 60 0 48 173 621 173;
#P fasten 61 0 60 0 621 222 614 222 614 173 621 173;
#P connect 60 0 61 0;
#P fasten 3 0 63 0 48 225 621 225;
#P connect 61 0 63 0;
#P fasten 2 0 62 0 102 147 646 147;
#P connect 62 0 60 1;
#P pop;
#P newobj 71 154 265 196617 p divisionmetro;
#P button 71 181 15 0;
#P comment 326 84 35 196617 BPM;
#P flonum 326 105 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P toggle 71 102 15 0;
#P comment 64 81 35 196617 on/off;
#P connect 1 0 5 0;
#P connect 5 0 4 0;
#P connect 5 1 6 0;
#P connect 5 2 7 0;
#P connect 5 3 8 0;
#P connect 5 4 9 0;
#P connect 5 5 10 0;
#P connect 5 6 11 0;
#P connect 5 7 12 0;
#P connect 5 8 13 0;
#P connect 5 9 14 0;
#P connect 5 10 15 0;
#P connect 5 11 16 0;
#P connect 5 12 17 0;
#P connect 5 13 18 0;
#P connect 5 14 19 0;
#P connect 2 0 5 1;
#P connect 5 15 20 0;
#P window clipboard copycount 21;


Stefan Tiedje————x——-
–_____———–|————–
–(_|_ —-|—–|—–()——-
– _|_)—-|—–()————–
———-()——–www.ccmix.com

#90839
Dec 16, 2006 at 3:22pm

easy. one metro. one counter. and select objects. that’s all you need.

max v2;
#N vpatcher 15 55 728 499;
#P window setfont “Sans Serif” 9.;
#P comment 194 251 49 9109513 slow;
#P comment 133 251 49 9109513 medium;
#P number 279 179 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P button 203 234 15 0;
#P button 145 234 15 0;
#P button 88 234 15 0;
#P newex 145 181 57 9109513 select 0 2;
#P newex 203 182 52 9109513 select 0;
#N counter 3;
#X flags 0 0;
#P newobj 145 149 66 9109513 counter 3;
#P toggle 145 67 15 0;
#P newex 145 119 60 9109513 metro 250;
#P comment 208 121 100 9109513 = fastest metro (n/4);
#P comment 78 251 36 9109513 fast;
#P fasten 2 0 7 0 150 143 93 143;
#P connect 3 0 2 0;
#P connect 2 0 4 0;
#P fasten 4 0 6 0 150 176 150 176;
#P connect 6 1 8 0;
#P connect 6 0 8 0;
#P fasten 4 0 5 0 150 173 208 173;
#P connect 5 0 9 0;
#P connect 4 0 10 0;
#P pop;

#90840
Dec 16, 2006 at 4:55pm

why not use setclock and have a master clock they all sync to ?

On Dec 16, 2006, at 10:22 AM, Dominic Thibault wrote:

>
> easy. one metro. one counter. and select objects. that’s all you need.
>
> max v2;
> #N vpatcher 15 55 728 499;
> #P window setfont “Sans Serif” 9.;
> #P comment 194 251 49 9109513 slow;
> #P comment 133 251 49 9109513 medium;
> #P number 279 179 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
> #P button 203 234 15 0;
> #P button 145 234 15 0;
> #P button 88 234 15 0;
> #P newex 145 181 57 9109513 select 0 2;
> #P newex 203 182 52 9109513 select 0;
> #N counter 3;
> #X flags 0 0;
> #P newobj 145 149 66 9109513 counter 3;
> #P toggle 145 67 15 0;
> #P newex 145 119 60 9109513 metro 250;
> #P comment 208 121 100 9109513 = fastest metro (n/4);
> #P comment 78 251 36 9109513 fast;
> #P fasten 2 0 7 0 150 143 93 143;
> #P connect 3 0 2 0;
> #P connect 2 0 4 0;
> #P fasten 4 0 6 0 150 176 150 176;
> #P connect 6 1 8 0;
> #P connect 6 0 8 0;
> #P fasten 4 0 5 0 150 173 208 173;
> #P connect 5 0 9 0;
> #P connect 4 0 10 0;
> #P pop;
> –
> Acouphenes.-.-.-.-.-.
>
>

v a d e //

http://www.vade.info
abstrakt.vade.info

#90841
Dec 17, 2006 at 12:06pm

Im not familiar with the set clock object in Max and wouldnt know how to go about doing this. If you care to shed some light on how to use it, I would be most grateful!

The alternatives are all great and I’m always happy to try out any new ideas to acheive syncronization as I’ve still got a lot to learn.

#90842
Dec 17, 2006 at 3:03pm

Ok so I’ve got the metronomes synced up but unfortunately this just confirmed the fact that it’s a problem with the counters. Does anybody know of a way to sync up the counters as it is their output in this case, that drives the sequencer?

I’ve included the patch, the counters dont always hit 0 at the same time, i.e. second counter should hit 0 the same time as first but after cycling thru twice.

Sometimes they are synced but if they are all reset then the chances are they wont be next time?!

#90843

You must be logged in to reply to this topic.