{"id":1856,"date":"2018-04-09T21:22:38","date_gmt":"2018-04-09T19:22:38","guid":{"rendered":"http:\/\/blog.cipworx.org\/laserman\/?p=1856"},"modified":"2018-04-09T21:54:44","modified_gmt":"2018-04-09T19:54:44","slug":"text-to-speech","status":"publish","type":"post","link":"https:\/\/blog.cipworx.org\/laserman\/2018\/04\/09\/text-to-speech\/","title":{"rendered":"text to speech"},"content":{"rendered":"<p>I have a notebook with a broken display. I removed the display and want to use TTS instead. So on boot the machine can say things like &#8220;conected to Wifi SSID &#8230;.&#8221; and &#8220;my IP adress is &#8230;&#8221;<\/p>\n<p>When I know the IP then I can connect via ssh or vnc. That might also be useful for Raspberry Pi. Another option can be a LCD connected via usb-to serial cable.<\/p>\n<p>I found 3 solutions ; one for bash and one for python:<\/p>\n<p><strong>bash 1:<\/strong><br \/>\napt-get install libttspico-utils<\/p>\n<p><code><br \/>\nA=`echo \"hello world\"` ; pico2wave --wave \/tmp\/Test.wav \"$A\" ; play \/tmp\/Test.wav; rm \/tmp\/Test.wav<br \/>\n<\/code><\/p>\n<p><strong>bash 2:<\/strong><br \/>\napt-get install festival festvox-don<\/p>\n<p><code><br \/>\n(echo \"my IP adress is \" ; hostname -I ) |festival --tts<br \/>\n<\/code><\/p>\n<p><strong>python:<\/strong><\/p>\n<p>pip install pyttsx3<br \/>\n<code><br \/>\nimport pyttsx3;<br \/>\nengine = pyttsx3.init();<br \/>\nengine.say(\"hello world\");<br \/>\nengine.runAndWait() ;<\/p>\n<p><\/code><\/p>\n","protected":false},"excerpt":{"rendered":"<p>I have a notebook with a broken display. I removed the display and want to use TTS instead. So on boot the machine can say things like &#8220;conected to Wifi SSID &#8230;.&#8221; and &#8220;my IP adress is &#8230;&#8221; When I know the IP then I can connect via ssh or vnc. That might also be [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2,11,4],"tags":[],"class_list":["post-1856","post","type-post","status-publish","format-standard","hentry","category-electronics","category-hardware","category-linux"],"_links":{"self":[{"href":"https:\/\/blog.cipworx.org\/laserman\/wp-json\/wp\/v2\/posts\/1856","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.cipworx.org\/laserman\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.cipworx.org\/laserman\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.cipworx.org\/laserman\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.cipworx.org\/laserman\/wp-json\/wp\/v2\/comments?post=1856"}],"version-history":[{"count":3,"href":"https:\/\/blog.cipworx.org\/laserman\/wp-json\/wp\/v2\/posts\/1856\/revisions"}],"predecessor-version":[{"id":1859,"href":"https:\/\/blog.cipworx.org\/laserman\/wp-json\/wp\/v2\/posts\/1856\/revisions\/1859"}],"wp:attachment":[{"href":"https:\/\/blog.cipworx.org\/laserman\/wp-json\/wp\/v2\/media?parent=1856"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.cipworx.org\/laserman\/wp-json\/wp\/v2\/categories?post=1856"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.cipworx.org\/laserman\/wp-json\/wp\/v2\/tags?post=1856"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}