My 2 cents on the topic, command line one-liners:

  • on Win using PowerShell.exe

      PowerShell -Command "Add-Type –AssemblyName System.Speech; (New-Object System.Speech.Synthesis.SpeechSynthesizer).Speak('hello');"
  • on Win using mshta.exe

      mshta vbscript:Execute("CreateObject(""SAPI.SpVoice"").Speak(""Hello"")(window.close)")
  • on OSX using say

      say "hello"
  • Ubuntu Desktop (>=2015) using native spd-say

      spd-say "hello"
  • on any other Linux

  • on Raspberry Pi, Win, OSX (or any remote) using Node-Red

    npm i node-red-contrib-sysmessage


https://stackoverflow.com/questions/1040655/ms-speech-from-command-line


标签: none

评论已关闭

辽公网安备21010602000703号 备案号:冀ICP备2022001219号