Page 1 of 2

MM5 loses connection with Google Home and goes to sleep [#18017]

Posted: Tue Jun 01, 2021 1:57 am
by CraigG
The past 3 releases have had an issue where MM seems to lose casting connection to Google Home and then the PC goes to sleep as nothing is happening.

I am assuming this as, when I wake the computer up again, the alert on screen is that the "speaker is no longer connected or available" or something like that.

the speaking I am casting to is absolutely available. I reported a similar issue a long while back and I believe the fix was you giving the system more time to reconnect before showing the alert.

MM5 loses connection with Google Home and goes to sleep

Posted: Tue Jun 01, 2021 1:57 am
by CraigG
The past 3 releases have had an issue where MM seems to lose casting connection to Google Home and then the PC goes to sleep as nothing is happening.

I am assuming this as, when I wake the computer up again, the alert on screen is that the "speaker is no longer connected or available" or something like that.

the speaking I am casting to is absolutely available. I reported a similar issue a long while back and I believe the fix was you giving the system more time to reconnect before showing the alert.

Re: MM5 loses connection with Google Home and goes to sleep

Posted: Tue Jun 01, 2021 1:09 pm
by Lowlander
I assume that MediaMonkey was casting to the device when this occurs?

Please capture this in a debug log (step 4b) with the debug version of MediaMonkey 5 build 2410 and attach the log to a Support Ticket: https://www.mediamonkey.com/forum/viewt ... 30&t=86643

Re: MM5 loses connection with Google Home and goes to sleep

Posted: Wed Jun 02, 2021 1:45 am
by CraigG

Re: MM5 loses connection with Google Home and goes to sleep

Posted: Wed Jun 02, 2021 2:24 pm
by Ludek
Hi,
in the debug log I see that "Living Room speaker (Chromecast Audio)" was replying our MEDIA_STATUS messages for 2000 seconds (33 minutes) and then suddenly it stopped replying and sent PING and we repeatedly replied with PONG, but it sent PING again over and over. So it looks that the device was no longer receiving our messages for some reason.

Can you confirm that if you (in this state) press Stop button on the player (or double-click a file to play) then the connection is estabilished again and it continues to play? If yes then I could try to detect this situation and "re-connect" to get from this state.

Re: MM5 loses connection with Google Home and goes to sleep

Posted: Wed Jun 02, 2021 4:01 pm
by CraigG
Hi Ludek

When this issue occurs, I notice music has stopped playing. I go to the laptop and it is asleep. I wake up the computer and it can take MM a few seconds to work. It kind of freezes for a second or two. Then I double click on a track and get the error "speaker is unavailable" or something like that. If I click it 1-2 more times, it connects and plays again fine.

I'm casting to Google Audio (its a chromecast kind of thing)

Re: MM5 loses connection with Google Home and goes to sleep

Posted: Thu Jun 03, 2021 3:09 am
by Ludek
Hi,
could you please do one more test with PC configured not to go to sleep at all?

I would like to know whether the reason for the lost connection is the Windows going to sleep or whether Windows goes to sleep as consequence of the lost conenction.

Thx.

Re: MM5 loses connection with Google Home and goes to sleep

Posted: Thu Jun 03, 2021 6:44 pm
by CraigG
Hi there

I disabled the sleep function on the laptop and have twice left MM to play. It didn't stop playback either time.

So, it seems the Windows sleep function is ignoring MM or MM is allowing the system to go to sleep sleep?

Re: MM5 loses connection with Google Home and goes to sleep

Posted: Fri Jun 04, 2021 1:40 pm
by Peke
Hi,
Windows 10 2004 introduced something called Deep Sleep which is sort half hibernate, half sleep eg. PC is shutdown, but due the sake of quick boot some portions are still in memory, maybe you are experiencing this. Can you please make screenshot of your windows power options?

Re: MM5 loses connection with Google Home and goes to sleep

Posted: Fri Jun 04, 2021 11:26 pm
by CraigG
Doesn't seem likely. As mentioned, this issue only arose 2-3 versions of MM5 ago.

https://1drv.ms/u/s!AoM1UrOaoKUMkeBAXpH ... Q?e=QUYMBf

Re: MM5 loses connection with Google Home and goes to sleep

Posted: Mon Jun 07, 2021 4:40 am
by Ludek
Hi,
this sounds like issue https://www.ventismedia.com/mantis/view.php?id=15089

But I was re-analyzing your debug log again now and seeing that it played for 33 minutes and that during that time we were correctly preventing PC from going to sleep by calling SetThreadExecutionState with ES_CONTINUOUS and ES_SYSTEM_REQUIRED every 30 seconds until the "Living Room speaker" stopped replying with MEDIA_STATUS and started replying with just PING.
So from the log it looks that the "PC sleep" was initiated after the device stopped sending its MEDIA_STATUS.

Did you (in your previous test when the log was generated) used also 10 minutes as the "sleep timeout" ?
Can you try to set sleep timeout just to 1 minute and try whether the PC goes to sleep despite casting to the "Living Room speaker" ? If yes, could you catch this in another log?

Thanks!

Re: MM5 loses connection with Google Home and goes to sleep

Posted: Mon Jun 07, 2021 3:44 pm
by CraigG
Hey - I turned the 'sleep' function off on the laptop, as per your request. Does Google Audio Cast have its own sleep timer? I can't see anything like that in the preferences.

I probably had the laptop set to 10 minutes on my original debug report.

I'll set it to 1 minute but i am away from home for a week so i'll have to come back to you.

Re: MM5 loses connection with Google Home and goes to sleep

Posted: Wed Jun 09, 2021 10:14 pm
by CraigG
Hey - I changed the sleep to 1 min and let MM play and it didn't cut off after 5-10 minutes.

https://1drv.ms/u/s!AoM1UrOaoKUMkeESw6F ... w?e=ZWcryf

Re: MM5 loses connection with Google Home and goes to sleep

Posted: Thu Jun 10, 2021 12:10 pm
by Ludek
OK, so it looks that this issue was not related to sleep settings, but rather random connection failure, are you still able to replicate this issue -- or it was a one time issue?

Re: MM5 loses connection with Google Home and goes to sleep

Posted: Fri Jun 11, 2021 12:09 am
by CraigG
Hi Ludek

It happened again now. My sleep setting is set to 15 minutes. New debug in the same folder above as well as a screen shot of two error messages.

There are two debug files. The one with (2) may also show a regular issue with MM. I click a tune expecting it to shuffle all the tracks in the playlist but it stops playing after playing the clicked track. I then double click another tune and it plays that track and consecutive ones after that, as expected.