#N canvas 412 100 806 586 12;
#X obj 59 197 osc~ 440;
#X obj 59 256 dac~;
#X obj 59 226 *~ 0.05;
#X msg 129 402 \; pd dsp 1;
#X msg 239 402 \; pd dsp 0;
#X text 195 409 ON;
#X text 309 409 OFF;
#X text 424 80 You should see the Pd window change to reflect whether audio is on or off. You can also turn audio on and off using the "audio" menu \, but the buttons are provided as a shortcut., f 46;
#X text 424 230 In general when you start a work session with Pd \, you will want to choose "test audio and MIDI" from the help window \, which opens a more comprehensive test patch than this one., f 46;
#X text 44 77 Audio computation in Pd is done using "tilde objects" such as the three below. They use continuous audio streams to intercommunicate \, as well as communicating with other ("control") Pd objects using messages., f 47;
#X obj 482 429 ../5.reference/set-dsp-tgl;
#X text 483 408 DSP on/off;
#X msg 482 488 \; pd dsp \$1;
#X text 52 398 click these -->, f 9;
#X obj 169 527 send pd;
#X text 62 308 Audio computation can be turned on and off by sending messages to the global "pd" object either via a message box or a [send] object as follows:, f 38;
#X msg 169 468 dsp 1;
#X msg 182 497 dsp 0;
#X text 240 481 <-- or these;
#X text 424 149 When DSP is on \, you should hear a tone whose pitch is middle A (440 Hz) and whose amplitude is 0.05. If instead you are greeted with silence \, you might want to read the HTML documentation on setting up audio., f 46;
#X text 129 196 <-- 440 Hz. sine wave at full blast;
#X text 129 225 <-- reduce amplitude to 0.05;
#X text 101 256 <-- send to the audio output device (left channel only), f 28;
#X text 423 302 These examples also use a helper abstraction with a toggle switch control from the documentation help files of Pd. Check it to the right and see how the toggle shows the DSP state., f 46;
#X obj 72 24 cnv 5 5 25 empty empty Making\ a\ Sine\ Wave 15 13 0 16 #dfdfdf #202020 0;
#X text 518 433 <-- click to turn DSP on/off. Right click to open and check abstraction, f 30;
#X connect 0 0 2 0;
#X connect 2 0 1 0;
#X connect 10 0 12 0;
#X connect 16 0 14 0;
#X connect 17 0 14 0;
