Supergiovane / node-red-contrib-tts-ultimate

This node transforms a text into a speech audio. You can hear the voice natively through Sonos or external players.
MIT License
22 stars 5 forks source link

Bug: Sonos will repeat the TTS/hailing over and over again. #78

Closed drexxi closed 8 months ago

drexxi commented 8 months ago

Salutation (i'll not respond to users that doesn’t wrote at least "Hello")

Hey, I'm using your brilliant TTS node for Node-Red. Since a few days I have problems with my Notification, they are just played over and over by Sonos. My configuration has been untouched for years, it must be a new feature from Sonos. Unfortunately I don't know how to help myself. Do you have any ideas?

Describe the bug TTS will repeat over and over again. Amazon Polley / AWS Node-Version 2.05

To Reproduce Steps to reproduce the behavior: Just send any Message once, it will repeat over and over again. It doesn't matter if hailing is on or off. Expected behavior Message repeated once.

Screenshots If applicable, add screenshots to help explain your problem.

TTS-Ultimate Version 2.05

Are you running node-red behind homematic, docker or anything similar?

Additional context ...

Supergiovane commented 8 months ago

Hi. That’s weird. Mine works flawlessly and i’m on the latest sonos firmware. Could it be a music “repeat” option? You can check in the sonos app, if you have activated that option bu mistake.

drexxi commented 8 months ago

Hey, I don’t know where this option could be? Thats how my player looks like:Am 28.10.2023 um 21:07 schrieb Massimo Saccani @.***>: Hi. That’s weird. Mine works flawlessly and i’m on the latest sonos firmware. Could it be a music “repeat” option? You can check in the sonos app, if you have activated that option bu mistake.

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you authored the thread.Message ID: @.***>

Supergiovane commented 8 months ago

What Speaker model are you using?

drexxi commented 8 months ago

One SL, newest firmware Am 28.10.2023 um 21:25 schrieb Massimo Saccani @.***>: What Speaker model are you using?

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you authored the thread.Message ID: @.***>

Supergiovane commented 8 months ago

https://support.sonos.com/en-us/article/shuffle-repeat-and-crossfade-songs

What happen if you play a song?

drexxi commented 8 months ago

Hey, I can play a song or a playlist totally normal. can’t find any general Option for repeat. I can setup a repeat if I play a song in Spotify or something.

In my Sonos App you can see the Song is playing but there isn’t any symbol activated:

I don’t know what’s wrong… it was running in the same setup since I think 2021. Something must changed, ether tts or node red or Sonos..

Am 28.10.2023 um 21:41 schrieb Massimo Saccani @.***>:

https://support.sonos.com/en-us/article/shuffle-repeat-and-crossfade-songs

What happen if you play a song?

— Reply to this email directly, view it on GitHub https://github.com/Supergiovane/node-red-contrib-tts-ultimate/issues/78#issuecomment-1783906390, or unsubscribe https://github.com/notifications/unsubscribe-auth/AKMDZC7ZK2QFYINNM4NPIQ3YBVNVNAVCNFSM6AAAAAA6UIUEWGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTOOBTHEYDMMZZGA. You are receiving this because you authored the thread.

Supergiovane commented 8 months ago

Please let me show your flow. Paste the flow here, so i can take a look.

drexxi commented 8 months ago

[ { "id": "c17c7f9b2388983a", "type": "tab", "label": "Sonos", "disabled": false, "info": "", "env": [] }, { "id": "b54d7a83ef877d15", "type": "ttsultimate", "z": "c17c7f9b2388983a", "name": "", "voice": "Vicki#engineType:neural", "ssml": false, "sonosipaddress": "192.168.42.108", "sonosvolume": "50", "sonoshailing": "0", "config": "51f6e244fb3af5b0", "property": "payload", "propertyType": {}, "rules": [], "playertype": "sonos", "speakingrate": "1", "speakingpitch": "0", "unmuteIfMuted": true, "elevenlabsStability": "", "elevenlabsSimilarity_boost": "", "x": 1530, "y": 100, "wires": [ [], [] ] }, { "id": "68d6751ebc7424cd", "type": "link in", "z": "c17c7f9b2388983a", "name": "Kiingel von Doorbird", "links": [ "2e89942f855183bb" ], "x": 445, "y": 80, "wires": [ [ "f8851d788dbfdb4d" ] ] }, { "id": "f8851d788dbfdb4d", "type": "change", "z": "c17c7f9b2388983a", "name": "BoolToString", "rules": [ { "t": "set", "p": "payload", "pt": "msg", "to": "Es ist jemand an der Tür!", "tot": "str" } ], "action": "", "property": "", "from": "", "to": "", "reg": false, "x": 970, "y": 100, "wires": [ [ "b54d7a83ef877d15", "f39b51b5c75f05ed" ] ] }, { "id": "af5dac1cbf72f65d", "type": "comment", "z": "c17c7f9b2388983a", "name": "Doorbird Klingel, TTS an SONOS", "info": "", "x": 550, "y": 40, "wires": [] }, { "id": "205beb0fe040f057", "type": "inject", "z": "c17c7f9b2388983a", "name": "Schalten um 7 Uhr Morgens", "props": [ { "p": "payload" }, { "p": "topic", "vt": "str" } ], "repeat": "", "crontab": "00 07 *", "once": false, "onceDelay": 0.1, "topic": "", "payload": "true", "payloadType": "bool", "x": 180, "y": 260, "wires": [ [ "1448d1cde0b61c00", "5f379bb6bac8dcfc", "b4af1be57f253fd5", "4464ca14429c13bb", "21ed50fab318d51a" ] ] }, { "id": "1448d1cde0b61c00", "type": "api-current-state", "z": "c17c7f9b2388983a", "name": "", "server": "634a7447.a28cbc", "version": 3, "outputs": 1, "halt_if": "", "halt_if_type": "str", "halt_if_compare": "is", "entity_id": "sensor.guntamatic_ascheleerenin", "state_type": "str", "blockInputOverrides": false, "outputProperties": [ { "property": "ascheLeeren", "propertyType": "msg", "value": "", "valueType": "entityState" } ], "for": "0", "forType": "num", "forUnits": "minutes", "override_topic": false, "state_location": "payload", "override_payload": "msg", "entity_location": "data", "override_data": "msg", "x": 600, "y": 260, "wires": [ [ "f3350bc621267b5d" ] ] }, { "id": "f3350bc621267b5d", "type": "function", "z": "c17c7f9b2388983a", "name": "ConcatStrings", "func": "if (msg.ascheLeeren < 12)\n{ msg = { payload: \"Die Asche muss in \" + msg.ascheLeeren + \" Stunden geleert werden.\" }}\nelse msg = null;\n\n\n\n\nreturn msg;", "outputs": 1, "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 980, "y": 260, "wires": [ [ "b54d7a83ef877d15", "f39b51b5c75f05ed" ] ] }, { "id": "ff5d7215066a1dad", "type": "comment", "z": "c17c7f9b2388983a", "name": "Heizung Asche leeren, TTS an SONOS", "info": "", "x": 570, "y": 220, "wires": [] }, { "id": "651e9282f29bfa80", "type": "inject", "z": "c17c7f9b2388983a", "name": "test", "props": [ { "p": "payload" }, { "p": "topic", "vt": "str" } ], "repeat": "", "crontab": "", "once": false, "onceDelay": 0.1, "topic": "", "payload": "true", "payloadType": "bool", "x": 770, "y": 40, "wires": [ [ "f8851d788dbfdb4d" ] ] }, { "id": "765fd03bd61d70cf", "type": "inject", "z": "c17c7f9b2388983a", "name": "test", "props": [ { "p": "payload" }, { "p": "topic", "vt": "str" } ], "repeat": "", "crontab": "", "once": false, "onceDelay": 0.1, "topic": "", "payload": "true", "payloadType": "bool", "x": 310, "y": 640, "wires": [ [ "21ed50fab318d51a", "4464ca14429c13bb", "b4af1be57f253fd5", "5f379bb6bac8dcfc" ] ] }, { "id": "21ed50fab318d51a", "type": "api-current-state", "z": "c17c7f9b2388983a", "name": "", "server": "634a7447.a28cbc", "version": 3, "outputs": 1, "halt_if": "", "halt_if_type": "str", "halt_if_compare": "is", "entity_id": "sensor.braune_tonne", "state_type": "str", "blockInputOverrides": false, "outputProperties": [ { "property": "payload", "propertyType": "msg", "value": "", "valueType": "entityState" }, { "property": "data", "propertyType": "msg", "value": "", "valueType": "entity" } ], "for": "0", "forType": "num", "forUnits": "minutes", "override_topic": false, "state_location": "payload", "override_payload": "msg", "entity_location": "data", "override_data": "msg", "x": 560, "y": 640, "wires": [ [ "2822e2f3312eb271" ] ] }, { "id": "4464ca14429c13bb", "type": "api-current-state", "z": "c17c7f9b2388983a", "name": "", "server": "634a7447.a28cbc", "version": 3, "outputs": 1, "halt_if": "", "halt_if_type": "str", "halt_if_compare": "is", "entity_id": "sensor.blaue_tonne", "state_type": "str", "blockInputOverrides": false, "outputProperties": [ { "property": "payload", "propertyType": "msg", "value": "", "valueType": "entityState" }, { "property": "data", "propertyType": "msg", "value": "", "valueType": "entity" } ], "for": "0", "forType": "num", "forUnits": "minutes", "override_topic": false, "state_location": "payload", "override_payload": "msg", "entity_location": "data", "override_data": "msg", "x": 560, "y": 580, "wires": [ [ "919b34a4ee924e7f" ] ] }, { "id": "b4af1be57f253fd5", "type": "api-current-state", "z": "c17c7f9b2388983a", "name": "", "server": "634a7447.a28cbc", "version": 3, "outputs": 1, "halt_if": "", "halt_if_type": "str", "halt_if_compare": "is", "entity_id": "sensor.gelbe_tonne", "state_type": "str", "blockInputOverrides": false, "outputProperties": [ { "property": "payload", "propertyType": "msg", "value": "", "valueType": "entityState" }, { "property": "data", "propertyType": "msg", "value": "", "valueType": "entity" } ], "for": "0", "forType": "num", "forUnits": "minutes", "override_topic": false, "state_location": "payload", "override_payload": "msg", "entity_location": "data", "override_data": "msg", "x": 560, "y": 520, "wires": [ [ "857ea062a771703c" ] ] }, { "id": "5f379bb6bac8dcfc", "type": "api-current-state", "z": "c17c7f9b2388983a", "name": "", "server": "634a7447.a28cbc", "version": 3, "outputs": 1, "halt_if": "", "halt_if_type": "str", "halt_if_compare": "is", "entity_id": "sensor.schwarze_tonne", "state_type": "str", "blockInputOverrides": false, "outputProperties": [ { "property": "payload", "propertyType": "msg", "value": "", "valueType": "entityState" }, { "property": "data", "propertyType": "msg", "value": "", "valueType": "entity" } ], "for": "0", "forType": "num", "forUnits": "minutes", "override_topic": false, "state_location": "payload", "override_payload": "msg", "entity_location": "data", "override_data": "msg", "x": 570, "y": 460, "wires": [ [ "eb7cc034a3c244f2" ] ] }, { "id": "eb7cc034a3c244f2", "type": "function", "z": "c17c7f9b2388983a", "name": "SetColorAndDay", "func": "let tonnenFarbe = \"schwarze Tonne\";\nlet tag;\n\nlet myfunc = () => {\n msg = {\n \"payload\": \"Die \" + tonnenFarbe + \" wird \" + tag + \" geleert.\"\n }\n}\n\nif (msg.payload == 3)\n{\n tag = \"über­über­mor­gen\"\n myfunc();\n}\nelse if (msg.payload == 2)\n{\n tag = \"übermorgen\"\n myfunc();\n}\nelse if (msg.payload == 1)\n{\n tag = \"morgen\"\n myfunc();\n}\nelse if(msg.payload == 0)\n{\n tag = \"heute\"\n myfunc();\n}\nelse msg = null;\n\n\nreturn msg;\n", "outputs": 1, "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 990, "y": 460, "wires": [ [ "b54d7a83ef877d15", "f39b51b5c75f05ed" ] ] }, { "id": "857ea062a771703c", "type": "function", "z": "c17c7f9b2388983a", "name": "SetColorAndDay", "func": "let tonnenFarbe = \"gelbe Tonne\";\nlet tag;\n\nlet myfunc = () => {\n msg = {\n \"payload\": \"Die \" + tonnenFarbe + \" wird \" + tag + \" geleert.\"\n }\n}\n\nif (msg.payload == 3)\n{\n tag = \"über­über­mor­gen\"\n myfunc();\n}\nelse if (msg.payload == 2)\n{\n tag = \"übermorgen\"\n myfunc();\n}\nelse if (msg.payload == 1)\n{\n tag = \"morgen\"\n myfunc();\n}\nelse if(msg.payload == 0)\n{\n tag = \"heute\"\n myfunc();\n}\nelse msg = null;\n\n\nreturn msg;\n", "outputs": 1, "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 990, "y": 520, "wires": [ [ "b54d7a83ef877d15", "f39b51b5c75f05ed" ] ] }, { "id": "919b34a4ee924e7f", "type": "function", "z": "c17c7f9b2388983a", "name": "SetColorAndDay", "func": "let tonnenFarbe = \"blaue Tonne\";\nlet tag;\n\nlet myfunc = () => {\n msg = {\n \"payload\": \"Die \" + tonnenFarbe + \" wird \" + tag + \" geleert.\"\n }\n}\n\nif (msg.payload == 3)\n{\n tag = \"über­über­mor­gen\"\n myfunc();\n}\nelse if (msg.payload == 2)\n{\n tag = \"übermorgen\"\n myfunc();\n}\nelse if (msg.payload == 1)\n{\n tag = \"morgen\"\n myfunc();\n}\nelse if(msg.payload == 0)\n{\n tag = \"heute\"\n myfunc();\n}\nelse msg = null;\n\n\nreturn msg;\n", "outputs": 1, "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 990, "y": 580, "wires": [ [ "b54d7a83ef877d15", "f39b51b5c75f05ed" ] ] }, { "id": "2822e2f3312eb271", "type": "function", "z": "c17c7f9b2388983a", "name": "SetColorAndDay", "func": "let tonnenFarbe = \"braune Tonne\";\nlet tag;\n\nlet myfunc = () => {\n msg = {\n \"payload\": \"Die \" + tonnenFarbe + \" wird \" + tag + \" geleert.\"\n }\n}\n\nif (msg.payload == 3)\n{\n tag = \"über­über­mor­gen\"\n myfunc();\n}\nelse if (msg.payload == 2)\n{\n tag = \"übermorgen\"\n myfunc();\n}\nelse if (msg.payload == 1)\n{\n tag = \"morgen\"\n myfunc();\n}\nelse if(msg.payload == 0)\n{\n tag = \"heute\"\n myfunc();\n}\nelse msg = null;\n\n\nreturn msg;\n", "outputs": 1, "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 990, "y": 640, "wires": [ [ "b54d7a83ef877d15", "f39b51b5c75f05ed" ] ] }, { "id": "abe8be7d9a7a1ea1", "type": "comment", "z": "c17c7f9b2388983a", "name": "Mülltonnen leeren, TTS an SONOS", "info": "", "x": 560, "y": 400, "wires": [] }, { "id": "db5918fb4dac5753", "type": "api-current-state", "z": "c17c7f9b2388983a", "name": "", "server": "634a7447.a28cbc", "version": 3, "outputs": 1, "halt_if": "", "halt_if_type": "str", "halt_if_compare": "is", "entity_id": "sensor.guntamatic_stoerung79", "state_type": "str", "blockInputOverrides": false, "outputProperties": [ { "property": "payload", "propertyType": "msg", "value": "", "valueType": "entityState" }, { "property": "data", "propertyType": "msg", "value": "", "valueType": "entity" } ], "for": "0", "forType": "num", "forUnits": "minutes", "override_topic": false, "state_location": "payload", "override_payload": "msg", "entity_location": "data", "override_data": "msg", "x": 590, "y": 340, "wires": [ [ "af03ac0e3156a56f" ] ] }, { "id": "2868e3c806e6fbae", "type": "inject", "z": "c17c7f9b2388983a", "name": "Alle 30 Minuten", "props": [ { "p": "payload" }, { "p": "topic", "vt": "str" } ], "repeat": "1800", "crontab": "", "once": true, "onceDelay": "1", "topic": "", "payload": "true", "payloadType": "bool", "x": 140, "y": 300, "wires": [ [ "db5918fb4dac5753" ] ] }, { "id": "f33d16470c35bcc5", "type": "comment", "z": "c17c7f9b2388983a", "name": "Heizung Störung TTS an SONOS", "info": "", "x": 550, "y": 300, "wires": [] }, { "id": "af03ac0e3156a56f", "type": "function", "z": "c17c7f9b2388983a", "name": "ConcatStrings", "func": "if (msg.payload != \" \")\n{ msg = { payload: \"Die Heizung hat eine Störung.\"}}\nelse msg = null;\n\n\n\n\nreturn msg;", "outputs": 1, "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 980, "y": 340, "wires": [ [ "b54d7a83ef877d15", "f39b51b5c75f05ed" ] ] }, { "id": "5acfc8f69e0e4062", "type": "ha-button", "z": "c17c7f9b2388983a", "name": "Status Update Home Assistant", "version": 0, "debugenabled": false, "outputs": 1, "entityConfig": "3fe820a78002c1dc", "outputProperties": [ { "property": "payload", "propertyType": "msg", "value": "", "valueType": "entityState" }, { "property": "topic", "propertyType": "msg", "value": "", "valueType": "triggerId" }, { "property": "data", "propertyType": "msg", "value": "", "valueType": "entity" } ], "x": 170, "y": 340, "wires": [ [ "5f379bb6bac8dcfc", "b4af1be57f253fd5", "4464ca14429c13bb", "21ed50fab318d51a", "db5918fb4dac5753", "1448d1cde0b61c00" ] ] }, { "id": "e283e7c65c98db04", "type": "api-call-service", "z": "c17c7f9b2388983a", "name": "Nachricht_chwe", "server": "634a7447.a28cbc", "version": 5, "debugenabled": true, "domain": "notify", "service": "mobile_app_ime", "areaId": [], "deviceId": [], "entityId": [], "data": "{\"message\":\"{{payload}}\"}", "dataType": "json", "mergeContext": "", "mustacheAltTags": false, "outputProperties": [], "queue": "none", "x": 1540, "y": 160, "wires": [ [] ] }, { "id": "f39b51b5c75f05ed", "type": "function", "z": "c17c7f9b2388983a", "name": "function 2", "func": "\nreturn msg;", "outputs": 1, "noerr": 0, "initialize": "", "finalize": "", "libs": [], "x": 1280, "y": 200, "wires": [ [ "e283e7c65c98db04", "f8a2d66e968ffd29" ] ] }, { "id": "f8a2d66e968ffd29", "type": "api-call-service", "z": "c17c7f9b2388983a", "name": "Nachricht_sawe", "server": "634a7447.a28cbc", "version": 5, "debugenabled": true, "domain": "notify", "service": "mobile_app_sara_handy", "areaId": [], "deviceId": [], "entityId": [], "data": "{\"message\":\"{{payload}}\"}", "dataType": "json", "mergeContext": "", "mustacheAltTags": false, "outputProperties": [], "queue": "none", "x": 1540, "y": 240, "wires": [ [] ] }, { "id": "d56791611d563be5", "type": "comment", "z": "c17c7f9b2388983a", "name": "Letztes Hunde Gassi", "info": "", "x": 510, "y": 700, "wires": [] }, { "id": "4f620a90b4286710", "type": "inject", "z": "c17c7f9b2388983a", "name": "Gassi gehen", "props": [ { "p": "payload" } ], "repeat": "", "crontab": "00 21 *", "once": false, "onceDelay": 0.1, "topic": "", "payload": "Die Gaia und die Kimi wollen jetzt Gassi gehen.", "payloadType": "str", "x": 510, "y": 740, "wires": [ [ "f39b51b5c75f05ed", "b54d7a83ef877d15" ] ] }, { "id": "1fec50e7ca38541d", "type": "api-current-state", "z": "c17c7f9b2388983a", "name": "", "server": "634a7447.a28cbc", "version": 3, "outputs": 1, "halt_if": "", "halt_if_type": "str", "halt_if_compare": "is", "entity_id": "sensor.geschirrspuler_program_progress", "state_type": "str", "blockInputOverrides": false, "outputProperties": [ { "property": "payload", "propertyType": "msg", "value": "", "valueType": "entityState" }, { "property": "data", "propertyType": "msg", "value": "", "valueType": "entity" } ], "for": "0", "forType": "num", "forUnits": "minutes", "override_topic": false, "state_location": "payload", "override_payload": "msg", "entity_location": "data", "override_data": "msg", "x": 630, "y": 840, "wires": [ [ "b54d7a83ef877d15" ] ] }, { "id": "d33ff0f7aa824eab", "type": "comment", "z": "c17c7f9b2388983a", "name": "Geschirrspüler", "info": "", "x": 500, "y": 800, "wires": [] }, { "id": "e989c609330d90a8", "type": "inject", "z": "c17c7f9b2388983a", "name": "test", "props": [ { "p": "payload" }, { "p": "topic", "vt": "str" } ], "repeat": "", "crontab": "", "once": false, "onceDelay": 0.1, "topic": "", "payload": "true", "payloadType": "bool", "x": 310, "y": 840, "wires": [ [ "1fec50e7ca38541d" ] ] }, { "id": "51f6e244fb3af5b0", "type": "ttsultimate-config", "name": "Polley", "noderedipaddress": "AUTODISCOVER", "noderedport": "1980", "purgediratrestart": "purge", "ttsservice": "polly", "TTSRootFolderPath": "" }, { "id": "634a7447.a28cbc", "type": "server", "name": "Home Assistant", "version": 5, "addon": false, "rejectUnauthorizedCerts": false, "ha_boolean": "y|yes|true|on|home|open", "connectionDelay": true, "cacheJson": true, "heartbeat": false, "heartbeatInterval": "30", "areaSelector": "friendlyName", "deviceSelector": "friendlyName", "entitySelector": "friendlyName", "statusSeparator": "at: ", "statusYear": "hidden", "statusMonth": "short", "statusDay": "numeric", "statusHourCycle": "h23", "statusTimeFormat": "h:m", "enableGlobalContextStore": true }, { "id": "3fe820a78002c1dc", "type": "ha-entity-config", "server": "634a7447.a28cbc", "deviceConfig": "", "name": "HAStatusUpdate", "version": "6", "entityType": "button", "haConfig": [ { "property": "name", "value": "Status Update" }, { "property": "icon", "value": "mdi:speaker-wireless" }, { "property": "entity_category", "value": "" }, { "property": "device_class", "value": "" } ], "resend": false, "debugEnabled": false } ]

Supergiovane commented 8 months ago

Hi, i cannot paste your flow due to errors. Please use the <> menu button (in the message toolbar) to paste the flow

drexxi commented 8 months ago

I think it was a bug in Sonos or in Node-Red it works again without a change from me.