Note: This no longer works, read down to find an alternate solution
The following applies to the HomeTroller Zee (S1 or S2) the SEL, or Linux HS3.
This procedure assumes that you know how to SSH to your controller and access the command prompt.
The TTS on Linux is not very good, but there is a way to have your text converted to speech using Google. The TTS is converted using a script called speak_to_file.sh in the HS folder (/usr/local/HomeSeer)
The result is the text will be spoken with the same voice that used on Android.
This requires the mpg123 medial player, so install that first with the command:
sudo apt-get install mpg123
Replace that file contents this:
The above script was modified from this one:
http://danfountain.com/2013/03/raspb...ext-to-speech/
The following applies to the HomeTroller Zee (S1 or S2) the SEL, or Linux HS3.
This procedure assumes that you know how to SSH to your controller and access the command prompt.
The TTS on Linux is not very good, but there is a way to have your text converted to speech using Google. The TTS is converted using a script called speak_to_file.sh in the HS folder (/usr/local/HomeSeer)
The result is the text will be spoken with the same voice that used on Android.
This requires the mpg123 medial player, so install that first with the command:
sudo apt-get install mpg123
Replace that file contents this:
Code:
#!/bin/bash ################################# # Speech Script by Dan Fountain # # TalkToDanF@gmail.com # ################################# INPUT=$2 STRINGNUM=0 ary=($INPUT) echo "---------------------------" echo "Speech Script by Dan Fountain" echo "TalkToDanF@gmail.com" echo "---------------------------" for key in "${!ary[@]}" do SHORTTMP[$STRINGNUM]="${SHORTTMP[$STRINGNUM]} ${ary[$key]}" LENGTH=$(echo ${#SHORTTMP[$STRINGNUM]}) #echo "word:$key, ${ary[$key]}" #echo "adding to: $STRINGNUM" if [[ "$LENGTH" -lt "100" ]]; then #echo starting new line SHORT[$STRINGNUM]=${SHORTTMP[$STRINGNUM]} else STRINGNUM=$(($STRINGNUM+1)) SHORTTMP[$STRINGNUM]="${ary[$key]}" SHORT[$STRINGNUM]="${ary[$key]}" fi done for key in "${!SHORT[@]}" do #echo "line: $key is: ${SHORT[$key]}" echo "Playing line: $(($key+1)) of $(($STRINGNUM+1))" NEXTURL=$(echo ${SHORT[$key]} | xxd -plain | tr -d '\n' | sed 's/\(..\)/%\1/g') mpg123 -w $1 -q "http://translate.google.com/translate_tts?tl=en&q=$NEXTURL" done
http://danfountain.com/2013/03/raspb...ext-to-speech/
Comment