Welcome to Smart Home Forum by FIBARO
Dear Guest,
as you can notice parts of Smart Home Forum by FIBARO is not available for you. You have to register in order to view all content and post in our community. Don't worry! Registration is a simple free process that requires minimal information for you to sign up. Become a part of of Smart Home Forum by FIBARO by creating an account.
As a member you can:
- Start new topics and reply to others
- Follow topics and users to get email updates
- Get your own profile page and make new friends
- Send personal messages
- ... and learn a lot about our system!
Regards,
Smart Home Forum by FIBARO Team
Search the Community
Showing results for tags 'TTS'.
-
Version 1.0.0
98 downloads
Sending Text-to-Speech message from your Fibaro hub to Alexa devices and Alexa app on mobile phones (Android and iOS). Give a voice to your smart home. Alexa on your mobile will speak all messages/alerts or any other monitoring messages that you need to know at real time. You will know real time what happens, wherever you are.... (internet connection requires) The QA uses 3rd party "Voice Monkey" skill for free. You are just a few minutes away to make your home speaks.📣🔊 The provided QA is an open source and feel free to change it per your requirements. -
Version 1.0
456 downloads
First of all the entire credit goes to @davanha who has written this text to speech (and alarm control) APK for android and continues to maintain the code. Outstanding job. Now, to my opinion, everyone should use this very simple and straight forward implementation. This is a great opportunity to give a voice to your home. I'm using TTS for years (UBI and EMIC solutions), but to have it on my phone at any place at home !!! sounds much better. Of course if you have tablet which runs Fibaro application and now you can make it speak... great feature for all your family, finally they can hear what you're doing. In my case the smart home is part of the family. I know that many users use other solutions like SONOS, Google, but not one of them has this nice and convenience way to speak directly to you or any other member of your family at any place at home. Please follow next installation steps: 1. Create TTS scene and copy the code (TTS scene v1.0-lua.txt) on your HC2. 2. Download zenitgatekeeper_0.1.651.txt to your phone or tablet. Change file extension to .apk and install the application. 3. Go to setting (initial password 1234) Application settings -> [check 'Autostart application after reboot' box] -> Http services [check all boxes on this page] see fifth screenshot-> go back till you see "Text-To-Speech mode" window (as displayed on third screenshot) 4. Usually we're cleaning our phones by killing background applications, so please lock this application on your phone. 5. To verify proper installation run on web browser follow line http://<ipadress of android device>:8080/tts=testing Your android device should now play the speech 6. You can add to play intro announcement before the message.. like "ding dong" or any other. To do so please click "Settings" button (default password to settings menu is "1234") -> Application Settings -> Http services -> Play speech on device. 7. New releases of the app are available at https://github.com/davandev/AlarmController/releases 8. Now if the setup is OK... open any code on your HC2 and execute fibaro:startScene('ttsSceneID',{"testing my text to speech setup","<IP address of android device:8080"}) fibaro:startScene('ttsSceneID',{"testing my text to speech setup","<IP address of android device>:8080",<volume level>}) Usual volume level range is 1-15. Please notice that the volume level of your phone or tablet will be changed accordingly. 9. Another great feature of zenitgatekeeper application, it can receive "wakeup" command and it will turn on the android device screen. I've found this very useful for my tablet in living room. Till now the display was constantly on, now since I have motion sensor in the room, I'm able to turn on the display only if someone in the room. It extends my tablet display life cycle. To use wakeup just start TTS scene as shown below: fibaro:startScene('ttsSceneID',{"wakeup","<IP address of android device:8080"}) For more information please visit this topic: https://forum.fibaro.com/topic/25004-using-an-android-device-as-a-text-to-speech-engine/ Notes: This solution works on your local LAN- home network only. When your device is out of range, no message will be received. But when you back to your area the device connects automatically and starts to "speak". My suggestion is to assign fixed IP address to your device on your home network. Otherwise the IP address could be changed and you'll need to change it in the code. You will hear the messages even if your phone is on mute. To stop to hear the messages you need to reduce the volume or to kill the application. Some ideas of messages could be seen on first screenshot. In addition you can install the apk application on other members of the family and you can redirect relevant messages of smart home directly to them only.- 10 comments
- 1 review
-
- tts
- text to speech
-
(and 3 more)
Tagged with:
-
Hello Team I have a sonos player 5 and I just want to use the TTS functionnality. What should I do ? Thanks in advance for your feedback
-
-
If you want to generate an audio message from a scene or virtual device and ear it on a Google Home or a Chromcast device, just do this: configure a server (e.g.: a Raspberry PI) with the following software: Google Home Notifier. add a global variable in Home Center create a simple Home Center scene activated by the variable And then simply put a text string into the variable and ear it play on the audio device. Expect between 3 to 6 seconds between the variable setting and the audio to play (depending on the various devices involved).
- 15 replies
-
- 1
-
- chromecast
- google home
-
(and 2 more)
Tagged with:
-
Hi, I have been working for a while to get an android device working as a text-to-speech engine and to generate speech from text that I can play in any speaker at home, and now I have finally got it working! Android has a pretty good tts engine and you can even configure custom voices that creates speech on languages not yet supported by android itself. Description The scenario is the following: HC2 or some other device wants a text translated to speech, it sends an http request including the text towards the android device, on the android device there is a http server started that receives the request and generates the synthesized speech using androids builtin TextToSpeech api, the android device can then either immediately play the speech in the device and/or store the synthesized content in a file. After successfully generated the speech file the android device sends a request to a configurable "callback url" to notify that the generated .wav file can now be downloaded. I realized during the work, that there are more scenarios than I from the beginning thought of, but the setup I was looking at was the following: However it is not really needed to convert and cache the file, you could also just notify your wifi speaker to play it. A third solution would be to let the android device itself play the speech, either through its internal speaker or via a speaker connected to headphone jacket. Ok so that was the idea and description of different use cases, if you want to try this out you need: Download and install the app on a android device 2. Start the app in Text-to-speech mode 3. Initial configuration 4. Test it 5. Create a scene/vd that sends tts requests. 6. Create a scene/vd that is invoked when tts speech is completed. 7. Download the speech file or tell your speaker system to download and play it. Download and install the app on a android device The app can be downloaded from here (app-debug.apk), you need to allow installation from unknown sources in android this is normally configured through "Android Settings" --> "Security" --> "Unknown Sources" I have tested the app on devices running android 5.0 and 6.0, earlier I also tested it on 4.4 but my samsung s2 finally seemed to give up so I dont know the current status on 4.4. The app needs "Storage" permissions to store the wav file on device. You can find and set the needed permission that by Android Settings --> apps --> --> permissions --> ZenitGatekeeper Short background around the app, I wrote the app originally with another thought in mind and that was to make it easy for the rest of the family to arm/disarm the home alarm (I am currently using the fibaro system as my security system at home), so it is wall mounted in the entrance and works like a keypad where you can arm the alarm or enter a pin to disarm the alarm. Since the device is always on and always connected to wifi I thought I would try to re-use the app also for generating text-to-speech. The app will start a web server and wait for requests, it currently supports a few different types of requests, - /ping : will just respond with 200 ok - /wakeup : will turn on the device screen (I use a fibaro motion sensor that triggers this event) - /tts=msg : will generate a tts file based on the provided message. - /ttsFetch : will return the latest generated speech file. - /log : returns the application logfile At successful text-to-speech generation the app will invoke an configured url to notify that the .wav file is ready. Start the app in Text-to-speech mode Start the app and push the text-to-speech button to start text-to-speech mode. As described above, the app was originally written to be used as a keypad, but I have added a "TTS mode" which only starts the app to be used as a TTS engine. Initial configuration The app needs some basic configuration to work properly, following configuration describes what is needed to get text-to-speech mode to work. Click "Settings" button (default password to settings menu is "1234") -> Application Settings -> Http services -> * "Enable http services" : will start the http server that listens on port 8080. * "Enable Text-To-Speech service" : will enable the text-to-speech function * "Play speech in device" : will play the speech in the device speakers if enabled. * "Text-To-Speech callback URL" : an callback url used to notify the requester that the speech is completed and can be downloaded. Push back button until you get to the TTS mode main page again, now it should look something like this and you should be ready to test it out: Test it To start with you could just open a webbrowser and type http://<ipadress to android device>:8080/tts=hey%20it%20works If it works out properly your android device should now play the speech and you should also receive a callback to your configured callback url. Next step would be to invoke it from your scenes/vd but I guess that is up to you decide how to do. For the interested reader source is available at https://github.com/davandev/AlarmController New releases of the app will be available at https://github.com/davandev/AlarmController/releases Let me know if you run into problems. Cheers
- 69 replies
-
- 1
-
- text-to-speech
- tts
-
(and 2 more)
Tagged with:
-
What is the syntax of sonos "text-to-speech" function in lua?
-
Hi, I'm using the 1.0.1b beta of the Sonos remote with the voicers API. I have a basic test scene to develop voice usage in my system From when I start the it takes between 8-9 seconds before I hear the sentence. The sonos mutes from when I start the scene The code is a simple function --[[ %% properties %% events %% globals --]] local ZoneID = 1308 local Message = "Seting away mode now, Alarm will arm in 30 seconds" local VolLevel = 30 local TTSEngineID = 356 if (fibaro:countScenes()>1) then fibaro:abort() end function tempFunc() fibaro:setGlobal("TTSZoneID", ZoneID) fibaro:setGlobal("TTSMessage", Message) fibaro:setGlobal("TTSVolLevel", VolLevel) fibaro:startScene(TTSEngineID) end tempFunc() The actual code to "speak" is separate as this allows me to call it with the required sentence and not repeat all the code The TTSEngineID code is from the forum here --[[ %% properties %% events %% globals --]] -- Configuration - Scene Info sceneName = "TTS Engine" sceneVersion = "1.0.1" -- Configuration - Device IDs local bid = 28 -- ID of the VD buttom (do not change) local sid = fibaro:getGlobalValue("TTSZoneID") -- Validate Number of Scene Instance if (fibaro:countScenes()>1) then fibaro:abort() end -- Main Scene Execution Code function tempFunc() local params = { message = fibaro:getGlobalValue("TTSMessage"), duration = 'auto', -- Duration: "auto", xx seconds language = "en-gb", -- Language: see http://www.voicerss.org/api/documentation.aspx to get your language code volume = fibaro:getGlobalValue("TTSVolLevel"), } local _f = fibaro local _x ={root="x_sonos_object",load=function(b)local c=_f:getGlobalValue(b.root)if string.len(c)>0 then local d=json.decode(c)if d and type(d)=="table"then return d else fibaro:debug("Unable to process data, check variable")end else fibaro:debug("No data found!")end end,set=function(b,e,d)local f=b:load()if f[e]then for g,h in pairs(d)do f[e][g]=h end else f[e]=d end;_f:setGlobal(b.root,json.encode(f))end,get=function(b,e)local f=b:load()if f and type(f)=="table"then for g,h in pairs(f)do if tostring(g)==tostring(e or"")then return h end end end;return nil end} -- Make a request to the remote to process params object instantly _x:set(tostring(sid), { tts = params }) _f:call(sid, "pressButton", bid) end -- Trigger Management local currentDate = os.date("*t") local startSource = fibaro:getSourceTrigger() --Start of Scene Execution if (startSource["type"] == 'property') then fibaro:debug("Started through property") tempFunc() -- this is calling the the function if something happens. elseif (startSource["type"] == 'global') then fibaro:debug("Started through variable") tempFunc() -- this is calling the the function if something happens. elseif (startSource["type"] == "autostart") then fibaro:debug("Started through autostart") tempFunc() -- this is calling the the function if something happens. elseif (startSource["type"] == "other") then fibaro:debug("Started through other ") tempFunc() -- this is calling the the function if something happens. else fibaro:debug("Scene not started, this can only be started through other, property, global or autostart!"); end -- End of Scene Execution fibaro:debug("Scene, " .. sceneName .. " v" .. sceneVersion .. " completed.") Is there anybody else experiencing this type of delay (or perhaps its normal ??) Is I used MP3's on my local NAS would it be faster? Thanks -F
-
Hi, I have come across what I think is a limit to the number of words that the TTS engine can speak. The following scene lua will work --[[ %% properties %% events %% globals --]] -- Configuration - Device IDs local bid = 28 local sid = 1203 local params = { message = "the big furry cat sat on the mat", duration = 'auto', -- Duration: "auto", xx seconds language = "en-gb", -- Language: see http://www.voicerss.org/api/documentation.aspx to get your language code volume = 45, } local _f = fibaro local _x ={root="x_sonos_object",load=function(b)local c=_f:getGlobalValue(b.root)if string.len(c)>0 then local d=json.decode(c)if d and type(d)=="table"then return d else fibaro:debug("Unable to process data, check variable")end else fibaro:debug("No data found!")end end,set=function(b,e,d)local f=b:load()if f[e]then for g,h in pairs(d)do f[e][g]=h end else f[e]=d end;_f:setGlobal(b.root,json.encode(f))end,get=function(b,e)local f=b:load()if f and type(f)=="table"then for g,h in pairs(f)do if tostring(g)==tostring(e or"")then return h end end end;return nil end} -- Make a request to the remote to process params object instantly _x:set(tostring(sid), { tts = params }) _f:call(sid, "pressButton", bid) but if I replace the message line with a longer message it doesn't work. (no error is given) message = "the big furry cat sat on the mat and the dog sat on the floor", I think the limit seems to be around 46 characters (or perhaps its a time limit, ~2 seconds of speaking??) 'Guest' in the following post indicated that they had announcements that were much longer that 50 chars that were working fine with the 1.0.0 beta http://forum.fibaro.com/index.php?/topic/20662-sonos-remote-v100-beta/page-3 Is this a known issue or is there a fix out there... Thanks -F
-
hello! I have tryed to use sonos TTS with kirschoffs VD but I cant get it to work. How have you guys solved it? Im using the latest sonos firmware, 6.1.1 regards K