imberezin / google-cast-sdk

Automatically exported from code.google.com/p/google-cast-sdk
0 stars 0 forks source link

Unable to connect to custom receiver from Chrome on iOS #714

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Set up a simple custom receiver app (see: 
https://github.com/akupila/chromecast-problem)
2. Connect to app from iPhone
3. An error occurs: {"code":"channel_error","description":"The operation 
couldn’t be completed. (com.google.chrome.ios.cast error 2.)"}
4. iPhone says Chromecast connected (if connecting again it says "Stop 
Casting") but app doesn't receive session information

What is the expected output? What do you see instead?
The session should start, functionality should be the same as in Chrome on 
desktop.

What version of the product are you using? On what operating system?
iPhone: iOS 9.2 (13C75) running Chrome 47.0.2526.70
Chromecast: 2nd generation, firmware 1.17.48342
I haven't been able to test on Android or Windows.

Please provide any additional information below.
The timeout occurs exactly when castReceiverManager.start() is called. 
Everything is working fine on Chrome 47.0.2526.80 (64-bit) on OS X 10.11.1 
(15B42).

Original issue reported on code.google.com by akup...@gmail.com on 16 Dec 2015 at 9:43

GoogleCodeExporter commented 8 years ago
Chromecast debug output (http://<ip>:9222):

iOS session:
receiver.js:56 Starting Receiver with namespace 
urn:x-cast:akupila.chromecast.test
2015-12-16 10:34:03.797 cast_receiver.js:40  [  0.059s] 
[cast.receiver.CastReceiverManager] Version: 2.0.0.0040
2015-12-16 10:34:03.801 receiver.js:56 Waiting 5sec
2015-12-16 10:34:08.827 receiver.js:56 Starting CastReceiverManager
2015-12-16 10:34:08.835 cast_receiver.js:40  [  5.097s] [goog.net.WebSocket] 
Opening the WebSocket on ws://localhost:8008/v2/ipc
2015-12-16 10:34:08.842 cast_receiver.js:40  [  5.108s] [goog.net.WebSocket] 
WebSocket opened on ws://localhost:8008/v2/ipc
2015-12-16 10:34:08.887 receiver.js:56 onReady 
{"id":"B030C4BA","name":"Autoplay Development 
[Local]","sessionId":"5965B2C6-8DCE-46E8-B5BE-B8C1DE98D743","namespaces":["urn:x
-cast:akupila.chromecast.test"],"launchingSenderId":"126:D856DBCB-E09A-45E9-BE92
-3712382BBEC4"}
2015-12-16 10:34:08.891 receiver.js:56 onSystemVolumeChanged 
{"level":1,"muted":false}
2015-12-16 10:34:08.894 receiver.js:56 onVisibilityChanged true
2015-12-16 10:34:08.896 receiver.js:56 onStandbyChanged 
{"type":"standbychanged","Z":false,"defaultPrevented":false,"Zb":true,"data":nul
l,"isStandby":false}
2015-12-16 10:34:08.899 receiver.js:56 onSenderConnected 
"126:D856DBCB-E09A-45E9-BE92-3712382BBEC4"
2015-12-16 10:39:13.431 receiver.js:56 onSenderDisconnected 
"126:D856DBCB-E09A-45E9-BE92-3712382BBEC4"

OS X session:
receiver.js:56 Starting Receiver with namespace 
urn:x-cast:akupila.chromecast.test
2015-12-16 10:51:00.140 cast_receiver.js:40  [  0.062s] 
[cast.receiver.CastReceiverManager] Version: 2.0.0.0040
2015-12-16 10:51:00.145 receiver.js:56 Waiting 5sec
2015-12-16 10:51:05.157 receiver.js:56 Starting CastReceiverManager
2015-12-16 10:51:05.166 cast_receiver.js:40  [  5.088s] [goog.net.WebSocket] 
Opening the WebSocket on ws://localhost:8008/v2/ipc
2015-12-16 10:51:05.183 cast_receiver.js:40  [  5.103s] [goog.net.WebSocket] 
WebSocket opened on ws://localhost:8008/v2/ipc
2015-12-16 10:51:05.221 receiver.js:56 onReady 
{"id":"B030C4BA","name":"Autoplay Development 
[Local]","sessionId":"37669BE8-9693-4019-8EC8-AFE611F345E2","namespaces":["urn:x
-cast:akupila.chromecast.test"],"launchingSenderId":"62:client-50962"}
2015-12-16 10:51:05.226 receiver.js:56 onSystemVolumeChanged 
{"level":1,"muted":false}
2015-12-16 10:51:05.231 receiver.js:56 onVisibilityChanged true
2015-12-16 10:51:05.234 receiver.js:56 onStandbyChanged 
{"type":"standbychanged","Z":false,"defaultPrevented":false,"Zb":true,"data":nul
l,"isStandby":false}
2015-12-16 10:51:05.239 receiver.js:56 onSenderConnected "62:client-50962"
2015-12-16 10:51:07.071 receiver.js:56 message from 62:client-50962: ping
2015-12-16 10:51:07.074 receiver.js:56 responding to 62:client-50962: pong
2015-12-16 10:51:09.066 receiver.js:56 message from 62:client-50962: ping
2015-12-16 10:51:09.068 receiver.js:56 responding to 62:client-50962: pong

Original comment by akup...@gmail.com on 16 Dec 2015 at 9:52

GoogleCodeExporter commented 8 years ago
Tab casting is not supported on Mobile Chrome at the moment. You can cast 
through Cast enabled apps (iOS sender apps) from an iOS devices. 

Original comment by na...@google.com on 17 Dec 2015 at 12:36

GoogleCodeExporter commented 8 years ago
To be clear: I don't want to mirror the tab, i want to communicate through the 
MessageBus with a custom receiver.

If using the MessageBus is for some reason not supported on mobile Chrome 
(MediaManager is working: https://github.com/googlecast/CastVideos-chrome works 
fine) i believe this should be documented somewhere.

Original comment by akup...@gmail.com on 17 Dec 2015 at 6:54

GoogleCodeExporter commented 8 years ago
At the moment, it is not possible to communicate to the MessageBus (which is a 
part of receiver API) because extensions are not supported on Mobile Chrome. 
Although, it something that we are looking into. 
However, I would suggest you post a question with your specific use-case on 
Stack Overflow under Google Cast or Chromecast tag(s). Our engineers maintain 
active presence there and might be able to help you.

Original comment by na...@google.com on 17 Dec 2015 at 9:36