Announcement

Collapse
No announcement yet.

TTS - What am I doing wrong?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    TTS - What am I doing wrong?

    So I am trying to get TTS to work on my setup:

    HS3 on Ubuntu server, with Squeezebox Plugin connected to my LMS (on a different Ubuntu server) v 3.2.0.1.

    I have no problem controlling my Squeezbox players thru the plugin - works like a wonder :-)

    However when I create an event with "speak something" the only thing that happens is that the player is stopping the internet radio stream, speaker proxy count goes up from zero to one, and then quiet. And after a few seconds the player resumes the internet radio station playback, the speaker proxy count returns to zero. And no errors in the log. I have turned up the speaker volume for speech to 100% (this SB Touch uses 100% fixed output all the time) on the client.

    I have installed LAME on both servers, and from what I can say it works on both servers. For example LMS says it found LAME and it "appears to work".

    Any tips on what I am doing wrong here?

    #2
    Some more information:

    - I have tested to stop my internet radio streaming, so the SB Touch is in "stopped" condition however it is still "on" - no difference.

    - On my SB Touch it says "added http://ip/Squeezebox/Speakin_1.mp3" - in that directory on the LMS server there is no such file, not can I see any such file during the speech event I created (I have an event in HS3 that does a "speak something" - in my case "Welcome Home Test"). Also for every test I do, executing the event mentioned, the file count is always the same (_1) - even though I seen others have different numbers. Not sure this is importent. Anyway if the file is created at this directory I as root user can not catch it, nor it is saved. Is the speech file deleted directly? The directory on my LMS is also named "squeezeserver" with a small "s" - and has 777 (everyone can do anything).

    - Playing from my music library, FLAC files (only, I have no mp3's), will result in the same silence during speech - no difference.

    I'll keep working :-)

    Comment


      #3
      Clearification, and maybe an importent one:

      On my Squeezebox Touch, the display indicates that the speech file is on my HS3 server (xxx.xxx.1.5) and not on my LMS server (xxx.xxx.1.12).

      On my HS3 server there is no /squeezebox directory so I just created one - no difference. Nor can I find any file after I tested the event for text to speech test I use.

      Comment


        #4
        Strange thing here...

        I have found all speech files, they are on my HS3 server in directory /opt/HomeSeer/html/SqueezeBox.
        Now since web server root is /opt/HomeSeer/html, this should also mean that http://xxx.xxx.1.5/SqueezeBox/Speech..... should be there.

        So I generated a mp3 file online, verified it on my pc, and downloaded it into that folder (/opt/HomeSeer/html/SqueezeBox/WelcomeHomeTest.mp3), used the url radio http setup (as pcp wrote somehere else), and YES it works perfectly.

        Comment


          #5
          One sidenot: The plugin installation on my LMS - I have no such option "Exstention Download" (I use 7.9.1 of LMS). So I have no plugin in my LMS.

          Comment


            #6
            Okay - now I kind of got it working, but still NOT:

            Here is what I have done:

            I have increased the "Delay After Speaking" in the SqueezeBox Config to 58 seconds. Now the delay is no where near 58 seconds. However it now has enough time to speak some of the words (I have increased the test phrase to "Welcome Home and we are joining in on something else" - and it drops a few words on the end). So I increased the "Delay After Speaking" to two minutes - nothing changes. Is the delay even working?

            So I then increased the "TTS Additional Speech Duration" to 3000 ms - or 3 seconds - now every word gets spoken.

            So YES I seem to have it working, not entirely sure how I have made it work to be honest, but it does work.

            The only thing left seems to be to get a better voice or something - any ideas?

            Comment


              #7
              Glag you got it to work. FYI the MP3 file from the TTS is created and stored on the HS3 server and played by streaming it (via HS3 HTTP server) in LMS. Not sure how to get better voices on Linux; while I have a Linux Zee S2 for testing (with TTS setup) I am using a Windows server for my prod environment and have mutliple choices of voices I added, but not have not heard if available on Linux. You might want to search the forum including in threads beyond this plugin for Linux TTS voices.

              Comment


                #8
                Okay - I now know what I did to get it working:

                When an event has a "Speak something", in my configuration with no local audio on my HS3 server (it is after all a virtual server) so no "speaker client", call the speak.sh script, that on my HS3 server is located in /opt/HomeSeer directory. This script contains, originaly:
                Code:
                #!/bin/sh
                #flite -voice kal16 -t "$1"
                pico2wave -w=temp.wav "$1"
                aplay temp.wav
                Do observer two things here, the "flite" command is commented out so that is not used - however something call pico2wave is. pico2wave will create a .WAV file which in this case is the text to speech sampling file in .WAV format (microsoft). pico2wave was NOT installed on my server by default, so after installation of this package I got it working.

                So apart from LAME, I also needed pico2wave installed and that is done by:
                Code:
                apt install libttspico-utils
                However after some testing, pico2wave is not the best way I guess for creating synthetic voices - so I uncommented the "flite" line and commented out "pico2wave".

                After some testing I am still not satisfied, however I have added two options on the flite call so my script now looks like this:
                Code:
                #!/bin/sh
                flite -voice kal16 --setf duration_stretch=1.5 --setf int_f0_target_mean=145 -t "$1"
                #pico2wave -w=temp.wav "$1"
                aplay temp.wav
                The funny thing is that aplay is not installed on my server so I guess that line is useless. Anyway it is clearly still a work in progress.

                I have found something else also:
                When my SB Radio, wake up radio in my bedroom, is off it is always at 4% volume. And running 20% at speech volume - well it is 20% of the volume at the players volume I guess since I will have to put that to 100% to be able to hear anything from the TTS. Not sure how to solve this. I always thinks that the volume from TTS is to low.

                Another interesting thing is that when I turn the player off it remembers that it was playing some internet radio station, so when TTS is called upon, well first I get a few seconds of internet radio, then the TTS, and then again the Internet radio - since the process seems to be "on, wait for mp3 file to be created, play mp3 file, off" - and well it is wait time I guess. I will fix this by changing my events that controls this. This I can solve by changing my events.

                Anyway, large thanks for a great plugin!

                Comment

                Working...
                X