Narwhal

Narwhal is a command for Linux, Mac and Windows permitting SoX tone generation using preset files written in YAML, JSON or XML.

The tones may either be exported to a popular audio file format or played to an audio output device.

Example YAML preset file

#!/usr/local/bin/narwhal --format=YAML
preset                  	            :
    tty                 	            :   STDOUT
    say         	                    :   "NIN TDS Closer Sequence"
    process             	            :   play
    handle                              :   null
    synths                              :
        - synth               	        :
            length          	        :   0.20
            tones           	        :
                - sawtooth              :
                    note   		        :   C2
            effects                     :
                - overdrive             :
                    gain		        :	80
                    colour	            :	74
                - fade            	    :
                    in          	    :  	0.03125
                    form        	    :   half
                    out         	    :   0.03125
                - echos                 :
                    gain_in             :   0.800
                    gain_out            :   0.880
                    delay               :
                                        -   300
                                        -   600
                                        -   900
                    decay               :
                                        -   0.200
                                        -   0.100
                                        -   0.050
        - synth               	        :
            length          	        :   0.20
            tones           	        :
                - sawtooth              :
                    note   		        :   C2
            effects                     :
                - delay                 :
                    length              :
                                        -   1.20
                - overdrive             :
                    gain		        :	80
                    colour	            :	74
                - fade            	    :
                    in          	    :  	0.03125
                    form        	    :   half
                    out         	    :   0.03125
                - echos                 :
                    gain_in             :   0.800
                    gain_out            :   0.880
                    delay               :
                                        -   300
                                        -   600
                                        -   900
                    decay               :
                                        -   0.200
                                        -   0.100
                                        -   0.050
        - synth               	        :
            length          	        :   0.20
            tones           	        :
                - sawtooth              :
                    note   		        :   C2
            effects                     :
                - delay                 :
                    length              :
                                        -   2.40
                - overdrive             :
                    gain		        :	80
                    colour	            :	74
                - fade            	    :
                    in          	    :  	0.03125
                    form        	    :   half
                    out         	    :   0.03125
                - echos                 :
                    gain_in             :   0.800
                    gain_out            :   0.880
                    delay               :
                                        -   300
                                        -   600
                                        -   900
                    decay               :
                                        -   0.200
                                        -   0.100
                                        -   0.050
        - synth               	        :
            length          	        :   0.20
            tones           	        :
                - sawtooth              :
                    note   		        :   C2
            effects                     :
                - delay                 :
                    length              :
                                        -   3.60
                - overdrive             :
                    gain		        :	80
                    colour	            :	74
                - fade            	    :
                    in          	    :  	0.03125
                    form        	    :   half
                    out         	    :   0.03125
                - echos                 :
                    gain_in             :   0.800
                    gain_out            :   0.880
                    delay               :
                                        -   300
                                        -   600
                                        -   900
                    decay               :
                                        -   0.200
                                        -   0.100
                                        -   0.050
        - synth               	        :
            length          	        :   0.10
            tones           	        :
                - noise                 :
                    note   		        :   C4
            effects                     :
                - overdrive             :
                    gain		        :	62
                    colour	            :	74
                - delay                 :
                    length              :
                                        -   0.60
                - fade            	    :
                    in          	    :  	0.03125
                    form        	    :   half
                    out         	    :   0.03125
        - synth               	        :
            length          	        :   0.10
            tones           	        :
                - noise                 :
                    note   		        :   C4
            effects                     :
                - delay                 :
                    length              :
                                        -   1.80
                - overdrive             :
                    gain		        :	62
                    colour	            :	74
                - fade            	    :
                    in          	    :  	0.03125
                    form        	    :   half
                    out         	    :   0.03125
        - synth               	        :
            length          	        :   0.10
            tones           	        :
                - noise                 :
                    note   		        :   C4
            effects                     :
                - delay                 :
                    length              :
                                        -   3.00
                - overdrive             :
                    gain		        :	62
                    colour	            :	74
                - fade            	    :
                    in          	    :  	0.03125
                    form        	    :   half
                    out         	    :   0.03125
        - synth               	        :
            length          	        :   0.10
            tones           	        :
                - noise                 :
                    note   		        :   C4
            effects                     :
                - delay                 :
                    length              :
                                        -   4.20
                - overdrive             :
                    gain		        :	62
                    colour	            :	74
                - fade            	    :
                    in          	    :  	0.03125
                    form        	    :   half
                    out         	    :   0.03125