Closed Krabardaf closed 5 years ago
That sounds like something external stops the Chromecast device.
If you enable the log in the .config file in the install folder:
<add key="ShowLog" value="true" />
and post the content of the log tab, then I can investigate!
Maybe I can add an option/checkbox: "Auto restart when the stream is closed".
Wow that is a fast answer. Amazing, thank you very much. Let me look into that! I'll post the log tomorrow evening (JST) when it will have had time to record some stuff.
Ok, let me know!
I added an 'auto restart' option to the new release: 1.0, can you test it for me?
Default the 'auto restart' option is off, you can change the default in the .config file:
<add key="AutoRestart" value="true" />
You can change the option for the current session in the UI.
Leaving work now but will test tomorrow morning. You're the best! 👍
Hey SamDel, I let the laptop run overnight and surprisingly, the connection had not been lost (with 0.9). Therefore the log is of no help still. I installed 1.0 and could see the new function, this sounds perfect, however, with 1.0 I could not connect to my cast device. I tried resetting my chromecast audio and rebooting the computer etc, but still impossible to connect. 1.0 just returned a generic error like can't connect (device case showed in orange). Curiously though, the volume setting did work, I just couldn't launch the stream. Just to be sure I reinstalled 0.9, and it worked immediately. So I'm still on 0.9 now in the end. If you want to look into that that would be awesome but I wouldn't want to lose time over just my single case either! Many thanks again!
Thanks, that's good feedback.
Odd that it keeps running during night-time, maybe the external factor that was disturbing it isn't there during night-time!?
There were also some changes related to the networking part in 1.0. I reverted most of these changes in 1.1. Can you test that one too, and post the log if you still get an error?
Thanks again!
I installed 1.1, but I get the same error. I couldn't find where your log is stored, but from what I see the error is in [time][ip]:{"requestId":1,"type":"LOAD_FAILED"}
I'd gladly post the rest of the log if you can just point to me where it is, sorry if that was obvious!
Many thanks again
The log is not stored on the filesystem, it's only in the log-tab when you enable it in the config. But I know what goes wrong when "LOAD_FAILED"
.
For your understanding: I'm struggling a bit with selecting the right IP address to use for streaming to the chromecast. It's not working for everybody now because network setups can be very different. "LOAD_FAILED"
means Chromecast can't open the stream because the application didn't provide the right IP address.
I made some changes again. Can you test 1.2?
Hi SamDel,
Thanks for the feedback and details! I installed 1.2 and it all works now. Awesome! I will let you know if the auto-reconnect option work correctly. I wish the external devs we work with here would be as efficient as you are! Thank you really.
Good to hear! I hope 1.2 works for other people as well, if not then please let it know.
The reconnect option waits for 5 seconds now when the connection is closed before loading the stream again.
Thanks for testing and the good feedback, Krabardaf!
I added a new feature in 1.3:
If you change from e.g. a network cable to a WIFI connection the stream is closed. It's closed because the local IP address changes then, and the Chromecast device can't load from the previous IP address anymore.
Now the application tries to restart the stream with the new IP address. I'm not sure if that applies to your situation!?
You can also change the local IP address that's used for streaming in 1.3 by using the dropdown. You should only use that feature when the application doesn't automatically get the right IP address, causing the stream not to load.
Hello SamDel,
Just FYI with 1.2 the cast has been running for a week H24 with no issue at all. Really thankful for that!
The laptop is using a wired connection but disconnection could always happen when manipulating it. Let me try 1.3 for you, it's the least I can do. I'll be in touch with feedback this week :)
Thanks for letting me know that it works fine :).
A changed local IP address is probably not what caused playback to stop for you then, if you have a wired connection.
Hey Samdel, I gave it a try for two days, still no disconnect issues :) However two points you might know : when a disconnection occurs, the stream might go in an error state indefinitely ( connection error). In that case there is auto no re-connection, presumably because the stream was never actually closed. However at other times when disconnecting the stream just closes, then effectively reboots on the newly available connection. Could it be that the error only occurs when no connection is available for too long? Second thing is unrelated, but your counter that keeps track of how long the connection has been up only updates once every 10 seconds or so. I absolutely don't mind but just thought you could keep it as is and just show HH:MM, or make it update every second if you display seconds. Many thanks again, you're the best 👍
The restart is now only triggered when the application gets a 'CLOSE' control message from the Chromecast device. Maybe it should also be triggered on other events, do you see something in the log (maybe 'LOAD_FAILED'?) that should also trigger a restart?
I now send a 'GET_STATUS' message to the device every 10 seconds, it responds with the time it's streaming. I update the user interface with that value. Showing only HH:MM is better maybe, thanks!
Hi SamDel, WiFi is out here for a few more days where I use the chromecast. When everything gets back online I'll try to fiddle with it a bit more :) What do you think about trying to restart when encountering a connection error, and not just when the IP change? It could be a normal retry first(right after the error), then a single retry every hours or something if the problem persist. Might not get all the details here though!
Many thanks again!
Hi Krabardaf, nice feature! You get a connect error when the application can't make a connection at all (device down, network down or out of range). When do you get a connection error? Will be nice if the application resumes playing when it's possible, I'll look at it!
Version 2.1 keeps trying to get the device in playing state, when you checked 'Automatically restart when the stream is closed'!
@Krabardaf : I'm closing this one, please reopen if there are further issues!
Hi there. Your tool is awesome!
I use it at work to stream from a computer to a pair a speakers on the next floor.
I suspect my issue has more to do with external factors but several times a day, the cast just stop. Your app shows my device as stopped, and if I press play again, the stream resumes as if nothing happened. I use a chromecast audio, that is constantly plugged in using the provided socket. It's always shown in my Google Home app so it doesn't seems to be disconnecting. Both the audio source (laptop) and chromecast are right next to a WiFi relay. Maybe it's just the connection and there's nothing that can be done, but are you aware of any other possible causes?
Additionally, is there any way I could automatically restart the stream with a script or something? This would be a dirty workaround but still helpful.
Many thanks anyhow!