#N canvas 407 23 706 639 12;
#X obj 24 11 delay;
#X obj 25 36 del;
#X floatatom 233 462 5 0 0 0 - - - 0;
#X msg 92 271 stop;
#X text 14 602 see also:;
#X obj 138 602 timer;
#X obj 90 602 metro;
#X obj 64 270 bng 19 250 50 0 empty empty empty 17 7 0 10 #dfdfdf #000000 #000000;
#X text 491 602 updated for Pd version 0.45;
#X obj 117 491 delay 1000 1 msec;
#X text 415 510 - tempo (float) and time unit (symbol) as in "tempo" message, f 30;
#X msg 162 325 tempo 0.5 msec;
#X floatatom 117 325 5 0 0 0 - - - 0;
#X msg 117 298 1000;
#X text 273 317 set unit to 1/2 millisecond so that '1000' gives a delay of 500 msec (1/2 second)., f 42;
#X msg 175 359 tempo 2 permillisecond;
#X text 326 389 same as 1 msec \, so '1000' is a second.;
#X text 340 358 this is the same as above.;
#X text 261 203 These symbols can also be preceded by "per" (as in "permin" \, "permsec" \, etc.) In this case \, 60 permin means 1/60 min (hence \, the same as 'BPM')., f 50;
#X text 19 270 start;
#X text 132 270 cancel the delay;
#X text 156 297 set delay time and start;
#X msg 188 389 tempo 0.001 second;
#X obj 185 602 text sequence;
#X text 69 10 - send a bang message after a time delay;
#X text 206 414 Note that if the tempo is changed while the delay is in progress \, the change takes effect to the remaining fraction of the delay., f 65;
#X obj 8 62 cnv 1 690 1 empty empty empty 8 12 0 13 #000000 #000000 0;
#N canvas 727 125 573 320 reference 0;
#X obj 9 42 cnv 5 550 5 empty empty INLETS: 8 18 0 13 #202020 #000000 0;
#X obj 9 185 cnv 2 550 2 empty empty OUTLET: 8 12 0 13 #202020 #000000 0;
#X obj 9 221 cnv 2 550 2 empty empty ARGUMENTS: 8 12 0 13 #202020 #000000 0;
#X obj 8 295 cnv 5 550 5 empty empty empty 8 18 0 13 #202020 #000000 0;
#X text 140 76 float -;
#X text 147 94 bang -;
#X obj 28 12 delay;
#X text 73 11 - send a bang message after a time delay;
#X text 147 112 stop -;
#X text 197 112 stop the delay., f 46;
#X obj 8 72 cnv 1 550 1 empty empty 1st: 8 12 0 13 #9f9f9f #000000 0;
#X obj 8 154 cnv 1 550 1 empty empty 2nd: 8 12 0 13 #9f9f9f #000000 0;
#X text 140 160 float -;
#X text 197 76 set delay time and start the delay., f 46;
#X text 197 94 start the delay., f 46;
#X text 28 130 tempo <float \, symbol> -;
#X text 197 130 set tempo value (float) and time unit symbol., f 46;
#X text 146 193 bang - bang at a delayed time., f 54;
#X text 197 160 set delay time for the next tempo., f 46;
#X text 130 229 1) float - initial delay time (default 0)., f 54;
#X text 130 248 2) float - tempo value (default 1)., f 54;
#X text 123 268 3) symbol - time unit (default 'msec')., f 55;
#X restore 533 34 pd reference;
#X text 631 35 <= click;
#X text 276 460 set delay time (only takes effect at the next tempo).;
#X text 20 135 Delay times are in units of 1 millisecond by default \, but you can change this with the second and third argument or with a "tempo" message (as in [timer] \, [metro] and [text sequence]) \, which set a tempo value and a time unit symbol. Possible symbols are:, f 94;
#X obj 290 602 pipe;
#X text 93 184 - millisecond (msec for short) \; - seconds (sec) \; - minutes (min) \; - samples (samp), f 32;
#X text 401 252 'samp' depends on the sample rate the patch is running, f 28;
#X obj 8 587 cnv 1 690 1 empty empty empty 8 12 0 13 #000000 #000000 0;
#X obj 117 530 bng 25 250 50 0 empty empty empty 17 7 0 10 #dfdfdf #000000 #000000;
#X text 20 75 The [delay] object outputs a bang after a given delay time (via argument or right inlet). A bang starts the delay. A float specifies the time delay and starts it. If the delay is running and scheduled to output \, sending a bang or a float cancels the previous setting and reschedules the output., f 94;
#X text 247 491 <-- creation arguments: - delay time (float), f 54;
#X text 59 36 <-- abbreviation;
#N canvas 570 48 709 670 examples 0;
#X obj 131 169 delay 1 60 permin;
#X obj 49 328 delay 1 1 sec;
#X obj 527 172 delay 1 44100 samp;
#X obj 153 328 delay 2 2 persec;
#X obj 277 328 delay 0.0166667 1 min;
#X obj 131 116 bng 19 250 50 0 empty empty empty 17 7 0 10 #dfdfdf #000000 #000000;
#X obj 131 203 bng 19 250 50 0 empty empty empty 17 7 0 10 #dfdfdf #000000 #000000;
#X text 26 21 Here's a more traditionally musical way to set a one-second delay by using a "bpm" setting. So we have "tempo 60 permin" and "delay 1".;
#X msg 183 129 tempo \$1 permin;
#X floatatom 183 96 5 0 0 0 - - - 0;
#X text 224 96 change bpm;
#X text 55 237 Now for other ways to get a one second delay;
#X obj 153 275 bng 19 250 50 0 empty empty empty 17 7 0 10 #dfdfdf #000000 #000000;
#X obj 49 378 bng 19 250 50 0 empty empty empty 17 7 0 10 #dfdfdf #000000 #000000;
#X obj 153 378 bng 19 250 50 0 empty empty empty 17 7 0 10 #dfdfdf #000000 #000000;
#X obj 277 378 bng 19 250 50 0 empty empty empty 17 7 0 10 #dfdfdf #000000 #000000;
#X obj 527 124 bng 19 250 50 0 empty empty empty 17 7 0 10 #dfdfdf #000000 #000000;
#X text 481 22 Here we have yet another way yo set a one second delay \, but it depends on the sample-rate that Pd is running. We're then assuming a 44100 samplerate, f 31;
#X obj 527 216 bng 19 250 50 0 empty empty empty 17 7 0 10 #dfdfdf #000000 #000000;
#X obj 527 275 bng 19 250 50 0 empty empty empty 17 7 0 10 #dfdfdf #000000 #000000;
#X obj 527 378 bng 19 250 50 0 empty empty empty 17 7 0 10 #dfdfdf #000000 #000000;
#X obj 527 339 delay 44100 1 samp;
#X obj 110 444 bng 19 250 50 0 empty empty empty 17 7 0 10 #dfdfdf #000000 #000000;
#X obj 195 559 bng 19 250 50 0 empty empty empty 17 7 0 10 #dfdfdf #000000 #000000;
#X obj 195 524 delay 0;
#X obj 142 594 realtime;
#X floatatom 142 622 7 0 0 0 - - - 0;
#X obj 110 478 t b b;
#X text 289 497 When [delay] receives a message it schedules a message for the future \, even if the time delay is 0! Here we use [realtime] for a nondeterministic result of how long it actually takes., f 54;
#X text 289 564 Check the 'Scheduling' section in Pd's manual \, Chapter 2 \, for more details on how Pd operates., f 54;
#X connect 0 0 6 0;
#X connect 1 0 13 0;
#X connect 2 0 18 0;
#X connect 3 0 14 0;
#X connect 4 0 15 0;
#X connect 5 0 0 0;
#X connect 8 0 0 0;
#X connect 9 0 8 0;
#X connect 12 0 1 0;
#X connect 12 0 3 0;
#X connect 12 0 4 0;
#X connect 16 0 2 0;
#X connect 19 0 21 0;
#X connect 21 0 20 0;
#X connect 22 0 27 0;
#X connect 23 0 25 1;
#X connect 24 0 23 0;
#X connect 25 0 26 0;
#X connect 27 0 24 0;
#X connect 27 1 25 0;
#X restore 213 551 pd examples;
#X text 303 550 <- open for more;
#X connect 2 0 9 1;
#X connect 3 0 9 0;
#X connect 7 0 9 0;
#X connect 9 0 35 0;
#X connect 11 0 9 0;
#X connect 12 0 9 0;
#X connect 13 0 12 0;
#X connect 15 0 9 0;
#X connect 22 0 9 0;
