#N canvas 0 0 600 400 12;
#X text 25 12 the patchbay is a big signal router that connects every input to every output. each route can be toggled on/off individually and dynamically. the interface has a bang for each input on the left side \, and a bang for each output on the right side. to toggle a connection \, click the input bang \, then the output bang.;
#X text 25 112 there are several symbols defined for send and receive:;
#X text 25 137 - each 'input'-bang is receiving `patchbay-in-bang-N` \, where n is the number of the inlet.;
#X text 25 187 - each 'output'-bang is receiving `patchbay-out-bang-N` \, where n is the number of the inlet;
#X text 25 237 - the patchbay receives on its `:receive-symbol` (default: `patchbay-rcv`) and sends on its `:send-symbol` (default: `patchbay-snd`).;
#X text 25 312 sending a `bang` to the patchbay will output the current state of all toggles. you can send the state to the patchbay receive to restore it.;
#X text 25 362 NOTE: the patch requires the `cljpd.toggle.pd` abstraction.;
#X obj 1230 5 cljpd.example-patchbay-for-helpfile;
#X msg 1405 5  \; patchbay-rcv bang;
#X msg 1573 5  \; patchbay-rcv 1 0 1 0 1 0;
#X obj 1748 5 bng 15 250 50 0 patchbay-in-bang-sin empty sin 17 7 0 10 -262144 -1 -1;
#X obj 1783 5 bng 15 250 50 0 patchbay-out-bang-left empty left 17 7 0 10 -262144 -1 -1;
#X obj 1818 45 print;
#X obj 1818 5 r patchbay-snd;
#X obj 1923 85 throw~ patchbay-in-sin;
#X obj 1923 45 *~ 0.300000;
#X obj 1923 5 osc~ 440;
#X obj 2084 85 throw~ patchbay-in-saw;
#X obj 2084 45 *~ 0.300000;
#X obj 2084 5 phasor~ 110;
#X obj 2245 125 throw~ patchbay-in-sqr;
#X obj 2245 85 *~ 0.300000;
#X obj 2245 45 expr~ if(\$v1 > 0.5 \, 1 \, -1);
#X obj 2245 5 phasor~ 220;
#X obj 2420 45 dac~;
#X obj 2420 5 catch~ patchbay-out-left;
#X obj 2595 5 catch~ patchbay-out-right;
#X connect 13 0 12 0;
#X connect 15 0 14 0;
#X connect 16 0 15 0;
#X connect 18 0 17 0;
#X connect 19 0 18 0;
#X connect 21 0 20 0;
#X connect 22 0 21 0;
#X connect 23 0 22 0;
#X connect 25 0 24 0;
#X connect 26 0 24 1;