Generate tones of specific frequency on mac command line

后端 未结 3 1267
灰色年华
灰色年华 2021-02-04 12:38

I need to generate musical notes of a given frequency on the command line

Here is a list of the frequencies of notes http://www.phy.mtu.edu/~suits/notefreqs.html

相关标签:
3条回答
  • 2021-02-04 13:04
    $ say "do ray me fa so la te do"
    

    lols.

    0 讨论(0)
  • 2021-02-04 13:07

    SoX works really good for this purpose and it's available in brew:

    $ brew install sox
    $ play -n synth 3 sin 523.25
    

    You can also save the sound to a file:

    $ play -n out.wav synth 3 sin 523.25
    
    0 讨论(0)
  • 2021-02-04 13:16

    It's simple, old and unmaintained but take a look at https://github.com/psycotica0/tone-generator

    $ brew install sdl
    $ git clone https://github.com/psycotica0/tone-generator.git
    $ cd tone-generator && make
    $ ./generator 2600 2
    
    0 讨论(0)
提交回复
热议问题