TTS on OH3 in Rules and Main-Ui

  • Platform information:
    • Hardware: Pi4
    • OS: Hypriot OS latest
    • Java Runtime Environment: docker
  • Issue of the topic:Can someone exactly show me how to setup the TTS-Feature with an Alexa? What I already did:
  1. I installed the Amazon echo control binding over main ui
  2. I added the Amazon-account
  3. I added the Alexa that should speak
  4. I connectected the speak-channnel to a string item
  5. I Send a command to the string with a rule
  6. nothing happened
  7. I can’t enter anything in Main Ui, because I don’t know how to set the standalone widget metadata correctly
  • Please post configurations (if applicable):
    rule:
triggers:
  - id: "1"
    configuration:
      itemName: SzenenItem
      command: jemandistzuhause
    type: core.ItemCommandTrigger
conditions: []
actions:
  - inputs: {}
    id: "2"
    configuration:
      itemName: Schlafzimmerecho_Sprich
      command: '"Die Alarmanlage wurde unscharf gestellt. Herzlich willkommen zuhause!"'
    type: core.ItemCommandAction

I know that it works in OH3, because I upgraded from an old install, and there it works…but the old install is gone now…

change to

command: 'Die Alarmanlage wurde unscharf gestellt. Herzlich willkommen zuhause!'

Tried, but the new UI strips the ’ ’ away, or makes them to " ’ ’ " so sadly this is not working…

If you create this command, dont use ’ or ". Otherwise try this:

triggers:
- id: "1"
configuration:
itemName: dummyschalter
type: core.ItemStateChangeTrigger
conditions: []
actions:
- inputs: {}
id: "2"
configuration:
itemName: WZEchoTTS
command: '<speak> <audio src="soundbank://soundlibrary/ui/gameshow/amzn_ui_sfx_gameshow_positive_response_01"
/>Hinweis: Waschmaschine ist fertig </speak>'
type: core.ItemCommandAction

this throws yaml errors…

This is not working…tried to bring it in the right format…but still I hear nothing on tts:

triggers:
  - id: "1"
    configuration:
      itemName: SzenenItem
      command: bernhardistzuhause
    type: core.ItemCommandTrigger
conditions: []
actions:
  - inputs: {}
    id: "2"
    configuration:
      itemName: Schlafzimmerecho_Sprich
      command: '<speak> <audio
        src="soundbank://soundlibrary/ui/gameshow/amzn_ui_sfx_gameshow_positive_response_01"
        />Hinweis: Waschmaschine ist fertig </speak>'
    type: core.ItemCommandAction

Ps.: I test with the “play” button in main-ui, but Echo is not reacting…

Work perfect

For you it’s working?

Yes check this out:
https://imgur.com/a/JLEqUbn

Well formatted code sorry for bad formatted code before

triggers:
  - id: "1"
    configuration:
      itemName: dummyschalter
    type: core.ItemStateChangeTrigger
conditions: []
actions:
  - inputs: {}
    id: "2"
    configuration:
      itemName: WZEchoTTS
      command: '<speak> <audio
        src="soundbank://soundlibrary/ui/gameshow/amzn_ui_sfx_gameshow_positive_response_01"
        />Hinweis: Waschmaschine ist fertig </speak>'
    type: core.ItemCommandAction

That’s exactly what I did…the Item seems to recieve the command, but I don’t hear anything…maybe the problem is not in the rule anymore…

Yes, you will create an item… Thats more than bad… It’s a rule! TTS leave it as it is. You must create a rule that this work, not an item.

Yes but for the rule I need an item connected to that channel that than can recieve the rule command no? Thats How I did it in 2.5…And in your rule, the command is also passed to an item…

core.ItemCommandAction

Yes like this:




I don’t have something like this:

Where come this text from? This looks like an item. I don’t have this in my item…

when I trigger the rule, it appears for a short time…I secreenshotted right after i pressed play to test the rule…normally this field is empty…I just switched on the semantic-tag point and none (like yours instead of emty) still nothing…

The only difference I have in my item is the symbol, and the profile (which was none for me). I switched it to standard, but still don’t hear anything…

Check logs if there is a warning or error. I think it’s a fault on your side. Can you send this via script?

No errors or warnings regarding the echo control…ony this one which relates to a wrong state-description metadata I think:

2021-01-15 15:12:00.467 [WARN ] [dataStateDescriptionFragmentProvider] - Unable to parse the stateDescription from metadata for item ThermostatKuche_Setpointheating, ignoring it

Just for the record…I also have problems regarding this rule…it’s z-wave so a complete different binding…here the only-if doesn’t apply and the rule never runs…:

triggers:
  - id: "1"
    configuration:
      itemName: DimmerKuechenlicht
    type: core.ItemStateUpdateTrigger
conditions:
  - inputs: {}
    id: "4"
    configuration:
      itemName: DimmerKuechenlicht
      state: "80"
      operator: ">"
    type: core.ItemStateCondition
actions:
  - inputs: {}
    id: "2"
    configuration:
      itemName: Arbeitsplattenlicht_Switch
      command: ON
    type: core.ItemCommandAction
  - inputs: {}
    id: "3"
    configuration:
      itemName: Dunstabzugshaube
      command: ON
    type: core.ItemCommandAction

I’m trying for five days now and i’m completely desperarted as I can’t find any cause and as the “old” rules which are written inside the rules folder work perfectly…I’ts a complete fresh install…

WHat do you mean by that?

DSL or Javascript