(This isn't fair )
Not you.
But how it all works.
I am stuck between a rock and hard place.
Arcing back to my TTS
problem.
I've found the command options to control the volume of ffmpeg
when playing a file.
(I hope)
So the command looks sound (pardon the pun) but I am not getting it to work.
Putting a debug
node on the output it looks alright.
But I don't hear anything.
I can't really (or don't know how to) test it from the terminal
of the remote (headless) machine.
This is what I have now.
[{"id":"5c18a1879c3fb946","type":"ttsultimate","z":"235f16ee6e459f2c","name":"","voice":"en-AU","ssml":false,"sonosipaddress":"192.168.1.109","sonosvolume":"30","sonoshailing":"0","config":"557d8082.eb5a8","property":"payload","propertyType":{},"rules":[],"playertype":"noplayer","speakingrate":"","speakingpitch":"","unmuteIfMuted":false,"elevenlabsStability":"","elevenlabsSimilarity_boost":"","x":3350,"y":1150,"wires":[["e0d1d13cca74b4e5"],[]]},{"id":"49fe9520d7455acf","type":"inject","z":"235f16ee6e459f2c","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"Hello there","payloadType":"str","x":3280,"y":1220,"wires":[["5c18a1879c3fb946"]]},{"id":"e0d1d13cca74b4e5","type":"switch","z":"235f16ee6e459f2c","name":"","property":"filesArray","propertyType":"msg","rules":[{"t":"nnull"}],"checkall":"true","repair":false,"outputs":1,"x":3500,"y":1150,"wires":[["6dcf944e40d84d7f"]]},{"id":"6dcf944e40d84d7f","type":"change","z":"235f16ee6e459f2c","name":"-12","rules":[{"t":"set","p":"volume","pt":"msg","to":"-12","tot":"num"}],"action":"","property":"","from":"","to":"","reg":false,"x":3630,"y":1150,"wires":[["180cac7d01f18109"]]},{"id":"180cac7d01f18109","type":"function","z":"235f16ee6e459f2c","name":"function 15","func":"msg.payload = msg.filesArray[0].file;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":3800,"y":1040,"wires":[["aeb8a5ea2cedced4","89ae14c79347b072"]]},{"id":"dc5b0685e89a38fd","type":"change","z":"235f16ee6e459f2c","name":"0db","rules":[{"t":"set","p":"volume","pt":"msg","to":"0","tot":"num"}],"action":"","property":"","from":"","to":"","reg":false,"x":3640,"y":1060,"wires":[["180cac7d01f18109"]]},{"id":"e4ad0d971cae4654","type":"change","z":"235f16ee6e459f2c","name":"+3","rules":[{"t":"set","p":"volume","pt":"msg","to":"3","tot":"num"}],"action":"","property":"","from":"","to":"","reg":false,"x":3630,"y":1260,"wires":[["180cac7d01f18109"]]},{"id":"aeb8a5ea2cedced4","type":"template","z":"235f16ee6e459f2c","name":"","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"{{payload}} -af \"volume={{volume}}dB\" -f wav - | DISPLAY=:0 aplay","output":"str","x":3970,"y":1020,"wires":[["8629bda419932c92"]]},{"id":"89ae14c79347b072","type":"exec","z":"235f16ee6e459f2c","command":"ffmpeg -i","addpay":"payload","append":"-f wav - | DISPLAY=:0 aplay ","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"","x":3980,"y":1110,"wires":[[],[],[]]},{"id":"fcf61de15ab84c8e","type":"switch","z":"235f16ee6e459f2c","name":"","property":"filesArray","propertyType":"msg","rules":[{"t":"nnull"}],"checkall":"true","repair":false,"outputs":1,"x":3510,"y":1040,"wires":[["dc5b0685e89a38fd"]]},{"id":"ef63e2bf8cb30c92","type":"switch","z":"235f16ee6e459f2c","name":"","property":"filesArray","propertyType":"msg","rules":[{"t":"nnull"}],"checkall":"true","repair":false,"outputs":1,"x":3500,"y":1260,"wires":[["e4ad0d971cae4654"]]},{"id":"8629bda419932c92","type":"debug","z":"235f16ee6e459f2c","name":"debug 9","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":4140,"y":1020,"wires":[]},{"id":"4fd53652fa2a7941","type":"ttsultimate","z":"235f16ee6e459f2c","name":"","voice":"en-AU","ssml":false,"sonosipaddress":"192.168.1.109","sonosvolume":"30","sonoshailing":"0","config":"557d8082.eb5a8","property":"payload","propertyType":{},"rules":[],"playertype":"noplayer","speakingrate":"","speakingpitch":"","unmuteIfMuted":false,"elevenlabsStability":"","elevenlabsSimilarity_boost":"","x":3360,"y":1040,"wires":[["fcf61de15ab84c8e"],[]]},{"id":"922d332ef377b798","type":"ttsultimate","z":"235f16ee6e459f2c","name":"","voice":"en-AU","ssml":false,"sonosipaddress":"192.168.1.109","sonosvolume":"30","sonoshailing":"0","config":"557d8082.eb5a8","property":"payload","propertyType":{},"rules":[],"playertype":"noplayer","speakingrate":"","speakingpitch":"","unmuteIfMuted":false,"elevenlabsStability":"","elevenlabsSimilarity_boost":"","x":3350,"y":1260,"wires":[["ef63e2bf8cb30c92"],[]]},{"id":"c41a891876e7e97d","type":"inject","z":"235f16ee6e459f2c","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"Hello there","payloadType":"str","x":3290,"y":1110,"wires":[["4fd53652fa2a7941"]]},{"id":"7f3abb61038637e5","type":"inject","z":"235f16ee6e459f2c","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"Hello there","payloadType":"str","x":3280,"y":1330,"wires":[["922d332ef377b798"]]},{"id":"0966946ed06cc3f8","type":"exec","z":"235f16ee6e459f2c","command":"ffmpeg -i","addpay":"payload","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"","x":4140,"y":1070,"wires":[[],[],[]]},{"id":"bf61456b0ab0b571","type":"inject","z":"235f16ee6e459f2c","name":"","props":[{"p":"payload"},{"p":"something","v":"-12","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"payload","payloadType":"str","x":3850,"y":1290,"wires":[["bb8467bab5e8a033"]]},{"id":"bb8467bab5e8a033","type":"template","z":"235f16ee6e459f2c","name":"","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"{{{payload}}} -af \"volume={{something}}dB\"","output":"str","x":4050,"y":1290,"wires":[["1d75070cea065d29"]]},{"id":"1d75070cea065d29","type":"debug","z":"235f16ee6e459f2c","name":"debug 10","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":4290,"y":1290,"wires":[]},{"id":"afa186a13b1df202","type":"inject","z":"235f16ee6e459f2c","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"Hello there","payloadType":"str","x":3300,"y":990,"wires":[["23ca465dc505edb7"]]},{"id":"23ca465dc505edb7","type":"ttsultimate","z":"235f16ee6e459f2c","name":"","voice":"en-AU","ssml":false,"sonosipaddress":"192.168.1.109","sonosvolume":"30","sonoshailing":"0","config":"557d8082.eb5a8","property":"payload","propertyType":{},"rules":[],"playertype":"noplayer","speakingrate":"","speakingpitch":"","unmuteIfMuted":false,"elevenlabsStability":"","elevenlabsSimilarity_boost":"","x":3370,"y":920,"wires":[["b5987bbb64a341d2"],[]]},{"id":"b5987bbb64a341d2","type":"switch","z":"235f16ee6e459f2c","name":"","property":"filesArray","propertyType":"msg","rules":[{"t":"nnull"}],"checkall":"true","repair":false,"outputs":1,"x":3520,"y":920,"wires":[["3dcee35ef0f08cb1"]]},{"id":"3dcee35ef0f08cb1","type":"function","z":"235f16ee6e459f2c","name":"function 14","func":"msg.payload = msg.filesArray[0].file;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":3660,"y":920,"wires":[["9ef912cce16e2209"]]},{"id":"9ef912cce16e2209","type":"exec","z":"235f16ee6e459f2c","command":"ffmpeg -i","addpay":"payload","append":"-af \"volume=-12dB\" -f wav - | DISPLAY=:0 aplay ","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"","x":3830,"y":920,"wires":[[],[],[]]},{"id":"557d8082.eb5a8","type":"ttsultimate-config","name":"googletranslate","noderedipaddress":"127.0.0.1","noderedport":"1980","purgediratrestart":"leave","ttsservice":"googletranslate","TTSRootFolderPath":""}]
Picture:
The base line works. But no sound/volume control.
Quick trip to the YELLOW nodes.
This modifies the command and includes the volume
part. (See outputs in debug
)
But when I change the exec
node from the working one to the RED one, I hear silence.
I don't know how to PROVE the new command structure/syntax works, but see:
In this blog post, we will explain the concept of volume, how to adjust volume using FFmpeg, and some of the problems that you may encounter while doing so.
It maybe nice if I know how to invoke the TTS
from the other machine's CLI and make sure it works at that level.
Sorry if this is getting OFF TOPIC for the thread, but as I said: I'm stuck between a rock and hard place as I know SFA about what I am doing.
SORRY!
I just found the mistake.
I forgot to the the 3 {}
around the payload.
Working now.
SO SORRY @marcus-j-davies .