2525 limitations under the License.
2626
2727 *** NODES FOR OPENAUDIO_ARDUINOLIBRARY 1 March 2021 RSL ***
28+ Updated many times, but still valid for 28 Oct 2025.
2829-->
2930< head >
3031< title > Audio System Design Tool for Open Audio F32 Library for Teensy</ title >
@@ -399,7 +400,7 @@ <h5 id="node-help-label">Keyboard Shortcuts <span style="float: right;"><a href=
399400 { "type" :"IFFT_Overlapped_F32" , "data" :{ "defaults" :{ "name" :{ "value" :"new" } } , "shortName" :"blockwiseIFFT" , "inputs" :"NaN" , "output" :"0" , "category" :"analyze-function" , "color" :"#E6E0F8" , "icon" :"arrow-in.png" , "outputs" :"NaN" } } ,
400401 { "type" :"AudioInputI2S_F32" , "data" :{ "defaults" :{ "name" :{ "value" :"new" } } , "shortName" :"audioInI2S" , "inputs" :"0" , "output" :"0" , "category" :"input-function" , "color" :"#E6E0F8" , "icon" :"arrow-in.png" , "outputs" :"2" } } ,
401402 { "type" :"AudioOutputI2S_F32" , "data" :{ "defaults" :{ "name" :{ "value" :"new" } } , "shortName" :"audioOutI2S" , "inputs" :"2" , "output" :"0" , "category" :"output-function" , "color" :"#E6E0F8" , "icon" :"arrow-in.png" , "outputs" :"0" } } ,
402-
403+ { "type" : "AudioOutputI2SQuad_F32" , "data" : { "defaults" : { "name" : { "value" : "new" } } , "shortName" : "audioOutI2SQuad" , "inputs" : "4" , "output" : "0" , "category" : "output-function" , "color" : "#E6E0F8" , "icon" : "arrow-in.png" , "outputs" : "0" } } ,
403404 { "type" :"AudioInputSPDIF3_F32" , "data" :{ "defaults" :{ "name" :{ "value" :"new" } } , "shortName" :"spdif3" , "inputs" :0 , "outputs" :2 , "category" :"input-function" , "color" :"#E6E0F8" , "icon" :"arrow-in.png" } } ,
404405 { "type" :"AsyncAudioInputSPDIF3_F32" , "data" :{ "defaults" :{ "name" :{ "value" :"new" } } , "shortName" :"spdif_async" , "inputs" :0 , "outputs" :2 , "category" :"input-function" , "color" :"#E6E0F8" , "icon" :"arrow-in.png" } } ,
405406 { "type" :"AudioInputUSB_F32" , "data" :{ "defaults" :{ "name" :{ "value" :"new" } } , "shortName" :"audioInUSB" , "inputs" :"0" , "output" :"0" , "category" :"input-function" , "color" :"#E6E0F8" , "icon" :"arrow-in.png" , "outputs" :"2" } } ,
@@ -2325,17 +2326,7 @@ <h3>Examples</h3>
23252326 < p > Nearly all the examples use this object . Here are some of the highlights :< / p >
23262327 < p class = exam > File > Examples > Audio > HardwareTesting > PassThroughStereo
23272328 </ p >
2328- < p class = exam > File > Examples > Audio > SamplePlayer
2329- </ p >
2330- < p class = exam > File > Examples > Audio > Recorder
2331- </ p >
2332- < p class = exam > File > Examples > Audio > WavFilePlayer
2333- </ p >
2334- < p class = exam > File > Examples > Audio > Effects > Chorus
2335- </ p >
2336- < p class = exam > File > Examples > Audio > Synthesis > PlaySynthMusic
2337- </ p >
2338- -->
2329+ -->
23392330 < h3 > Notes</ h3 >
23402331 < p > Only one I2S input and one I2S output object may be used. Master
23412332 and slave modes may not be mixed (both must be of the same type).</ p >
@@ -2352,6 +2343,70 @@ <h3>Notes</h3>
23522343 </ div >
23532344</ script >
23542345
2346+ < script type ="text/x-red " data-help-name ="AudioOutputI2SQuad_F32 ">
2347+ < h3 > Summary</ h3 >
2348+ < div class = tooltipinfo >
2349+ < p > Transmits quad (4) channel floating point 32-bit audio, using I2S master mode.</ p >
2350+ < p > Transmit to the various I2S Codec boards , such as a pair of
2351+ < a href = "http://www.pjrc.com/store/teensy3_audio.html" target = "_blank" > Teensy Audio Board < / a >
2352+ or a single
2353+ < a href = "https://www.janbob.com/electron/Codec/Codec1808_5102.htm" target = "_blank" > PCM1808 and PCM5102 Audio Board.</ a > .
2354+ < / d i v >
2355+ < p > Many thanks to Greg Raven for figuring this out.</ p >
2356+ < h3 > Teensy Boards Supported < / h 3 >
2357+ < ul >
2358+ < li > Teensy 4.0
2359+ < li > Teensy 4.1
2360+ </ ul >
2361+ < h3 > Audio Connections</ h3 >
2362+ < table class = doc align = center cellpadding = 3 >
2363+ < tr class = top > < th > Port</ th > < th > Purpose</ th > </ tr >
2364+ < tr class = odd > < td align = center > In 0</ td > < td > Channel #1</ td > </ tr >
2365+ < tr class = odd > < td align = center > In 1</ td > < td > Channel #2</ td > </ tr >
2366+ < tr class = odd > < td align = center > In 2</ td > < td > Channel #3</ td > </ tr >
2367+ < tr class = odd > < td align = center > In 3</ td > < td > Channel #4</ td > </ tr >
2368+ </ table >
2369+ < h3 > Constructor</ h3 >
2370+ < p > Objects of this class can be created using the typical, minimal constructor using no arguments.
2371+ Or, to control the sample rate and block size, the constructor can be passed an AudioSettings_F32
2372+ object that has been configured with your desired settings.</ p >
2373+ < h3 > Functions</ h3 >
2374+ < p class = func > < span class = keyword > setGain</ span > (< strong > float </ strong > Gain);</ p >
2375+ < p class = desc > Sets the output gain of all four channels. Values are unconstrained, but
2376+ normally range from 0.0 to 1.0 (default 1.0). A setting of exactly 1.0 results in
2377+ no scaling. </ p >
2378+ < h3 > Hardware</ h3 >
2379+ < p > A control Codec object, such as a pair of SGTL5000 must be included.</ p >
2380+ < p > Audio from
2381+ master mode I2S may be used in the same project as ADC, DAC (not T4.x) and
2382+ PWM signals, because all remain in sync to Teensy's timing</ p >
2383+ < p > Information on using two SGTL5000 Audio Adaptor boards can be found
2384+ < a href = "https://forum.pjrc.com/index.php?threads/teensy-4-1-and-4-channel-audio-audioinputi2squad.61123/& p = 242054 & viewfull = 1 #post242054"
2385+ target = "_blank" > at this Teensy Forum post.</ a >
2386+ Information on the four channel PCM1808/PCM5102 board is at
2387+ < a href = "https://www.janbob.com/electron/Codec/Codec1808_5102.htm" target = "_blank" > this web site.</ a > .
2388+ < h3 > Software Example</ h3 >
2389+ < p class = exam > File > Examples > AudioOutputI2SQuad_F32_Example
2390+ </ p >
2391+
2392+ < h3 > Notes</ h3 >
2393+ < p > Only one I2S input and one I2S output object may be used. Master
2394+ modes only may be used for the quad output.</ p >
2395+ < p > Being an "_F32" object, audio is passed into this class using F32 memory
2396+ that was allocated using an AudioMemory_F32() call in your sketch's setup()
2397+ routine. </ p >
2398+ < p > The input data for this class is the usual 32-bit floating point used throughout the library.
2399+ The attached CODEC will be sent up to 32 bits of signed integer data, depending on the device.
2400+ The device can accept a smaller portion of the integers, such as 16 or 24-bits.
2401+ In all cases, the full scale integer value is represented by +/- 1.0 in floating point
2402+ language (minus 1 LSB on the plus side).</ p >
2403+ </ script >
2404+ < script type ="text/x-red " data-template-name ="AudioOutputI2SQuad_F32 ">
2405+ < div class = "form-row" >
2406+ < label for = "node-input-name" > < i class = "fa fa-tag" > </ i > Name</ label >
2407+ < input type = "text" id = "node-input-name" placeholder = "Name" >
2408+ </ div >
2409+ </ script >
23552410
23562411< script type ="text/x-red " data-help-name ="AudioOutputSPDIF3_F32 ">
23572412 < h3 > Summary</ h3 >
@@ -4015,8 +4070,11 @@ <h3>Functions</h3>
40154070 (< strong > char*</ strong > pStr);</ p >
40164071 < p class = desc > This places a string, pointed to by pStr, into the buffer. If successful,
40174072 meaning that the buffer is not full, a < strong > true</ strong > is returned.</ p >
4018-
4019- < p class = func > < span class = keyword > enableTransmit</ span > (< strong > bool</ strong > en);</ p >
4073+
4074+ < p class = func > < span class = keyword > < strong > uint16_t</ strong > getBufferSpace</ span > ();</ p >
4075+ < p class = desc > Returns the number of empty bytes in the 512 character buffer.</ p >
4076+
4077+ < p class = func > < span class = keyword > enableTransmit</ span > (< strong > bool</ strong > en);</ p >
40204078 < p class = desc > If en is < strong > true</ strong > and the buffer has characters available, CW is sent.
40214079 If en is < strong > false</ strong > CW is not sent and characters are left in the buffer.
40224080 This, of course, does not control PTT. No return value.</ p >
@@ -4026,6 +4084,18 @@ <h3>Functions</h3>
40264084 the getTransmitEnable() will remain true until the current character is completed.
40274085 Additionally, getTransmitEnable() will go false when all characters in the buffer have
40284086 been fully sent. This can be useful for control of Transmit/Receive.</ p >
4087+
4088+ < p class = func > < span class = keyword > enableManualCW</ span > (< strong > bool</ strong > enCW);</ p >
4089+ < p class = desc > Enables/disables (enCW = true/false) manual keying. Buffer sent keying
4090+ is disabled. The Gaussian keying shaping is continued. Buffers are left untouched
4091+ when manual CW is enabled. No return value. </ p >
4092+
4093+ < p class = func > < span class = keyword > < strong > bool</ strong > getmanualCW</ span > ();</ p >
4094+ < p class = desc > Returns the manual CW status./p>
4095+
4096+ < p class = func > < span class = keyword > manualCWKey</ span > (< strong > bool</ strong > keyDown);</ p >
4097+ < p class = desc > When keyDown is true, the CW tone output is sent until
4098+ keyDown is false. No return value. </ p >
40294099
40304100 < p class = func > < span class = keyword > < strong > getBufferSpace</ strong > </ span > ();</ p >
40314101 < p class = desc > Returns the number of places (of 512) left in the character buffer.</ p >
@@ -4036,8 +4106,7 @@ <h3>Functions</h3>
40364106
40374107 < p class = func > < span class = keyword > setFrequency</ span > (< strong > float32_t</ strong > f);</ p >
40384108 < p class = desc > Sets the frequency of the CW waveform. The default is 600 Hz. Any value up to
4039- half of the sample rate can be used.
4040- No return value.</ p >
4109+ half of the sample rate can be used. No return value.</ p >
40414110
40424111 < p class = func > < span class = keyword > setCWSpeedWPM</ span > (< strong > uint16_t</ strong > speed);</ p >
40434112 < p class = desc > Sets the speed ofCW sending. The default is 13 WPM. The speed is the highest of
@@ -4061,7 +4130,7 @@ <h3>Functions</h3>
40614130 < p class = desc > Most standard sample rates are supported. See the Notes below for details. </ p >
40624131
40634132 < h3 > Examples</ h3 >
4064- <!-- <p class=exam>File > Examples > OpenAudio_ArduinoLibrary > FT8Transmit </p> -- >
4133+ < p class = exam > File > Examples > OpenAudio_ArduinoLibrary > CWSendTest4Rate </ p >
40654134
40664135 < h3 > Notes</ h3 >
40674136
0 commit comments