@bertreb said in New plugin pimatic-sounds:
I will look into it. You listened to radio by asking GA to tune in to a station?
yes
New plugin pimatic-sounds
@bertreb said in New plugin pimatic-sounds:
I will look into it. You listened to radio by asking GA to tune in to a station?
yes
Hi Bert,
as I learned, the discovery function need some time to get the “friendlyName”. Do you know if it ist possible to address the GH by only the “riendlyName” directly. Benefit would be the possibility to address groups to play sounds.
I tested it with a script. It works fine, but the time to discover the available GH is round about 10s for me (I remember such a period as well on you side. Am I right?). This would be to long for every single request.
Hi, the friendly name needs to be discovered or translated to ip on the network and that takes some time. Using the ip address is faster. Thats one of the reasons I skipped the discovery function (mdns). I’m using static ip addresses in my lan so that’s a one time configuration.
Looks good, too bad I cannot install node.js higher than 4.x because of some plugins I use that are not being updated anymore.
But since I’ve installed node-red on a different pi (because of gbridge.io pulling the plug) to use speech control on pimatic I’ve been able to create this in node-red
I’m going to experiment with a test setup of pimatic on a higher node version to see if I can get all plugins to run the way I’d like to.
Hi, you could also use leave the not maintained plugins on the current node 4 pi and install the rest on an other node 10 rpi. You could use the mesh plugin to connect the old rpi to the new one.
Yeah but that would mean I have to keep using and maintaining an extra raspberry pi, I was trying to run it all on 1 pi from ssd.
Even homeduino won’t install on node 10.x for some reason. really have no clue why.
@andi-tudor said in New plugin pimatic-sounds:
@bertreb said in New plugin pimatic-sounds:
I will look into it. You listened to radio by asking GA to tune in to a station?
yes
Hi, i got a solution that will resume a playing audio stream after a Sounds text or audio message. This version only works with TuneIn radio/music streams. Thats the app Google Home uses to stream ‘radio’ stations.
Let me know if you want to test it.
Took the plunge on a complete new installation of Pimatic since I’m recovering from an operation, cannot work at the moment
Got most of pimatic working again on node 10.15, only ledlight (for controlling hyperion) and smartmeter readings are not working now. I guess I need a different smartmeter plugin, have to look into that.
pimatic-led-light is abandoned so that’s too bad. Hue-zll working with your help in another thread, thanks for that!
But this also means I can test Pimatic-sounds. I would love resume tune-in playing!
thanks for all your work and help, really appreciate it!
@djmvt said in New plugin pimatic-sounds:
Took the plunge on a complete new installation of Pimatic since I’m recovering from an operation, cannot work at the moment
Got most of pimatic working again on node 10.15, only ledlight (for controlling hyperion) and smartmeter readings are not working now. I guess I need a different smartmeter plugin, have to look into that.
pimatic-led-light is abandoned so that’s too bad. Hue-zll working with your help in another thread, thanks for that!But this also means I can test Pimatic-sounds. I would love resume tune-in playing!
thanks for all your work and help, really appreciate it!
Hi for the smartmeters problem you could migrate to Smartmeter3 or Smartmeter-Obis.
@bertreb said in New plugin pimatic-sounds:
Hi for the smartmeters problem you could migrate to Smartmeter3 or Smartmeter-Obis.
trying that but gives me a lot of errors on the rules I had.
Came from pimatic-smartmeter-gas so have to figure out how to migrate.
Thanks for the pimatic-sounds update, will check tomorow!
@djmvt said in New plugin pimatic-sounds:
pimatic-smartmeter-gas
Hi, the conversion problem should ‘only’ be different attribute names.
If its is something else could you provide some error log (i’m the maintainer of smartmeter3 and smartmeter-obis)
Tested the sounds device briefly: seems to work as excpected, nice!
As I’ve seen in this thread speakergroups are not available, also when creating a speaker pair (2 of the same to create stereo sound) it’s also not available as a device.
Will it be possible in the future to add more google devices? we’ve got 5 of them (only speakers, not counting chromecasts). would be nice to add multiple speakers
thanks!
I will look into the group option.
You can already create more than 1 chromecast device. Chromecast is the protocol. Google Home device is also using chromecast.
Or do you mean other type of devices?
@bertreb I mean more google home devices. If I add 1 it works fine, when I add a second home device pimatic crashes with “adress already in use” error:
info [pimatic-sounds]: Device connected
00:07:26warn [pimatic]: Keeping pimatic alive, but could be in an undefined state, please restart pimatic as soon as possible!
00:07:26error [pimatic]: An uncaught exception occurred: Error: listen EADDRINUSE: address already in use :::4321
at Server.setupListenHandle [as _listen2] (net.js:1277:14)
at listenInCluster (net.js:1325:12)
at Server.listen (net.js:1412:7)
at ChromecastDevice.initSounds (/home/pi/pimatic-app/node_modules/pimatic-sounds/pimatic-sounds.coffee:146:9)
at ChromecastDevice.initSounds (/home/pi/pimatic-app/node_modules/pimatic-sounds/pimatic-sounds.coffee:1:1)
at Timeout.startupTime [as _onTimeout] (/home/pi/pimatic-app/node_modules/pimatic-sounds/pimatic-sounds.coffee:95:16)
at ontimeout (timers.js:436:11)
at tryOnTimeout (timers.js:300:5)
at listOnTimeout (timers.js:263:5)
at Timer.processTimers (timers.js:223:10)
This is most probably a bug in pimatic or in a module, please report it!
Woke up and saw these messages in the pimatic log:
Log messages
Showing 7 of 10 Messages
2020-02-13 03:14:25warn [pimatic]: Keeping pimatic alive, but could be in an undefined state, please restart pimatic as soon as possible!
03:14:25error [pimatic]: An uncaught exception occurred: Error: read ECONNRESET
at TLSWrap.onStreamRead (internal/stream_base_commons.js:111:27)
From connect
at TLSSocket.connect (/home/pi/pimatic-app/node_modules/pimatic/startup.coffee:56:29)
at Object.connect (_tls_wrap.js:1154:12)
at Client.connect (/home/pi/pimatic-app/node_modules/pimatic-sounds/node_modules/castv2-client/node_modules/castv2/lib/client.js:35:21)
at PlatformSender.connect (/home/pi/pimatic-app/node_modules/pimatic-sounds/node_modules/castv2-client/lib/senders/platform.js:27:15)
at ChromecastDevice.initSounds (/home/pi/pimatic-app/node_modules/pimatic-sounds/pimatic-sounds.coffee:165:17)
at ChromecastDevice.initSounds (/home/pi/pimatic-app/node_modules/pimatic-sounds/pimatic-sounds.coffee:1:1)
at Timeout.startupTime [as _onTimeout] (/home/pi/pimatic-app/node_modules/pimatic-sounds/pimatic-sounds.coffee:95:16)
at ontimeout (timers.js:436:11)
at tryOnTimeout (timers.js:300:5)
at listOnTimeout (timers.js:263:5)
at Timer.processTimers (timers.js:223:10)
This is most probably a bug in pimatic or in a module, please report it!
03:14:12warn [pimatic]: Keeping pimatic alive, but could be in an undefined state, please restart pimatic as soon as possible!
03:14:12error [pimatic]: An uncaught exception occurred: Error: Device timeout
at fn.ontimeout (/home/pi/pimatic-app/node_modules/pimatic-sounds/node_modules/castv2-client/lib/senders/platform.js:56:26)
at Object.onceWrapper (events.js:277:13)
at fn.emit (events.js:189:13)
at Timeout.ontimeout [as _onTimeout] (/home/pi/pimatic-app/node_modules/pimatic-sounds/node_modules/castv2-client/lib/controllers/heartbeat.js:44:10)
at ontimeout (timers.js:436:11)
at tryOnTimeout (timers.js:300:5)
at listOnTimeout (timers.js:263:5)
at Timer.processTimers (timers.js:223:10)
This is most probably a bug in pimatic or in a module, please report it!
02:31:31warn [pimatic]: Keeping pimatic alive, but could be in an undefined state, please restart pimatic as soon as possible!
02:31:31error [pimatic]: An uncaught exception occurred: Error: read ECONNRESET
at TLSWrap.onStreamRead (internal/stream_base_commons.js:111:27)
From connect
at TLSSocket.connect (/home/pi/pimatic-app/node_modules/pimatic/startup.coffee:56:29)
at Object.connect (_tls_wrap.js:1154:12)
at Client.connect (/home/pi/pimatic-app/node_modules/pimatic-sounds/node_modules/castv2-client/node_modules/castv2/lib/client.js:35:21)
at PlatformSender.connect (/home/pi/pimatic-app/node_modules/pimatic-sounds/node_modules/castv2-client/lib/senders/platform.js:27:15)
at ChromecastDevice.initSounds (/home/pi/pimatic-app/node_modules/pimatic-sounds/pimatic-sounds.coffee:165:17)
at ChromecastDevice.initSounds (/home/pi/pimatic-app/node_modules/pimatic-sounds/pimatic-sounds.coffee:1:1)
at Timeout.startupTime [as _onTimeout] (/home/pi/pimatic-app/node_modules/pimatic-sounds/pimatic-sounds.coffee:95:16)
at ontimeout (timers.js:436:11)
at tryOnTimeout (timers.js:300:5)
at listOnTimeout (timers.js:263:5)
at Timer.processTimers (timers.js:223:10)
This is most probably a bug in pimatic or in a module, please report it!
02:31:20error [pimatic-sounds]: Device ‘google-hub-keuken-’ offline
Hi, The error is coming from multiple webservers trying to start at the same port address. The webserver for serving the sounds was per device. I’m only having 1 GA so is didn’t test multiple devices. For the plugin i need only 1 webserver to serve devices so I moved the webserver to the plugin level and the server is now created once. That should solve this error in version 0.0.14.
Version 0.0.14 has has also support for Sonos (+SYMFONISK) devices and is published.
Thanks for testing and discovering.
installed and confirmed, multiple devices are accepted now. Thanks!
Also tested resume streaming: works, but only if the tune-in stream is started on the same device as to where I want to cast to. When I stream to a group of speakers and send a message with pimatic-sounds to 1 cast device it interrupts the stream on the group speakers, play a message on the cast device I selected and then the tune-in stream stops.
Group streams are sending on a different port, as far as I can see every group or pair gets is own port but I don’t know why it selects a certain IP (in my case, the IP from one of my google home speakers).
Strange thing is: when I try to cast to one speaker of a pair (wich is essentially also a group) that cast gets rejected. (got a json error from your plugin with the phrase “not allowed”)
Don’t know if you can do anything with that info though haha.
got a question:
Is it possible to reset the volume to the previous value when casting with a volume change in the rule?
The volume should go back to the value before the sound was played if you used the vol option after the text or file.
Example. When something is playing on vol 10 and the following action is executed "play text “vdvvdvddv” vol 40 on <hdhdhhd>"
After that the volume should go back to 10.
Or do you mean when nothing is playing after a Sound text/file the volume should go back to the old value?