Whitelisted chromecast works with default tictactoe app ID but not mine - google-cast

I am trying to get the tic tac toe demo from github working on my Chromecast after changing only the app id of the clients. With the default app id, I have been able to launch and play the game with an android client and a mac client.
I have:
Added my Chromecast device on the developer console (it has a green status indicator)
Set (via the Android Chromecast app) the Chromecast to send the device serial number
Verified that the serial number is correct
Verified with both the Android and Windows Chromecast apps that the serial# setting is retained
Power cycled the Chromecast
Setup an app id in the developer console (status is a grey circle labeled 'Unpublished')
Entered an internet accessible (not local) URL for the app id
Installed the receiver app at the above url and verified I can access it from a browser on the same network as the Chromecast
Also tried a local IP address (192.168.x.x) which I understand is supported as well
Modified the web client ttt.js file to use my app id (and verified app id is correct)
Modified the android client (GameActivity.java) to use my app id (and verified app id)
Did a git diff to make sure that I didn't inadvertently change anything else
Verified that my local copy of the source is the latest from git
When running the android client I can connect to my Chromecast but the Chromecast home screen shows "Brain Freeze", "We're sorry, but something could not load", "Activity aborted".
The logcat console in eclipse for the android device reports, "ConnectionResultCallback. Unable to launch the game. statusCode: 2002".
The web client on the Mac results in the same messages on the Chromecast and
'"reason":"CANCELLED","type":"LAUNCH_ERROR"'
on the web page output.
Is there a way to get more information from the Chromecast to indicate what is going wrong with the launch?
Follow Up
It turns out that the issue was in my network setup and not in my chromecast setup. After sniffing the network traffic with wireshark, I could see that the ARP request to retrieve the MAC address of my server was not getting a response. I am running my server on Virtualbox with a bridged adapter but needed to turn on promiscuous mode (allow all). Now the chromecast successfully launches the receiver app and I can play the tic tac toe game when using an HTTP based URL. (I need to fix the certificate for HTTPS).
Thanks Les, for the effort.

Did you verify that [x] send my serial # to Google has been checked (using the setup app)?
Also, did you wait 15 minutes and then restart your device (power cycle)?

Related

Chromecast won't play HLS stream

I am running a local server on iOS application and trying to stream the phone screen.
So the app makes this HLS(http://myipaddress:port/hls.m3u8)and updates it. I can play that on Chrome browser without any issue.
I have also set the CORS headers thus there is no error in the Chromecast remote debugger.
Somehow it doesn't play and it stuck there.
When I checked the response tab, it is empty.
Chromecast remote debugger
Http response header

Chromecast debug- can cast but cannot inspect

I have a gen3 chromecast device (whitelisted) and have had no issues inspecting traffic using chrome://inspect in the past. Now all of a sudden I just cannot seem to debug the CC device.
When I “chrome://inspect” I can see the device (not by its name that I have setup. It just says Chromecast) but when I start playing I don’t see the inspect option to start inspecting
I have tried the following:
Updated chrome
Re-booted the CC device
Re-booted wifi router
Tried it on a different TV
Also when I try to adb connect it throws an error saying that the device rejected connection. What does this mean and how do I resolve this?
I was having the same issue, there are a few things you need to make sure are set up correctly.
For the Chromecast:
Make sure the Chromecast is registered to your account on https://cast.google.com/publish/#/overview
Double-check the serial as it can mix O and 0, 1 and l, etc.
(Not sure if 100% it's necessary) Enabled "send statistics to Google" in the settings.
Once the device is "Ready For Testing" reboot it.
For the app:
The app must be registered to the same account as the device.
If you don't have an app (e.g. just want to test casting from your website), you need to create one. You can make it a "Styled Media Receiver" so you don't need to host JS anywhere. It's basically the same as the default receiver.
Make sure your app is published. Once it is, reboot the Chromecast.
The app must already be running before you can inspect it.
To make sure the issue is not coming from your website, you can use https://casttool.appspot.com/cactool/ (replace the appID with yours).
Start casting, then head to chrome://inspect/#devices and the "inspect" button should hopefully be there.

Call node api from mobile phone while developing flutter app

I am developing a chat application. I connect my mobile phone for testing/debugging while developing. But I can't call backend node API from my mobile phone and have to use an emulator to do so and the emulator works very slow on my laptop. Is there any way I could call the API from my connected mobile itself while developing?
static const BaseUrl = "http://10.0.2.2:3000/";
I also tried by giving ip address wherein both pc and my mobile phone are in the same network as below-
static const BaseUrl = "http://ipv4 address:8000/";
Is there any way I can test my app while developing through connected mobile phone and call backend node api?
Go into your Command Prompt or whatever console you have. I am using windows, so I would open up the CMD and type in IPconfig. Go to where you see "IPv4 Address", and copy the numbers that you see there. THAT will be what you will need to use in order to get access to your server. Make sure that your phone and computer(or whatever you are running the server on) is on the same WIFI, or else this will not work.

How can client know the changing from server side?

In Node. How I can push a notify to the clients with new information that another client made changing to server, even client is offline and online back.
Ex: I logged on my account to 3 device, 1 on my laptop, 1 on my PC, 1 on my mobile. On my laptop, I change the account’s information but I leaved the browser on my PC. When server send a notify to all clients, the online devices can receive the new information, without offline device. I want when I back access to my PC, I can detect the change from server without HTTP request.
You are looking for websockets.
https://developer.mozilla.org/en-US/docs/Web/API/WebSocket

Whitelisting additional Chromecast doesn't work

I have successfully witelisted my first Chromecast a while ago and my app development is well on its way. Recently I requested to add another device to my whitelist. The request went through, I've got a response. I can access my new device on port 9222, however my app fails to start the Receiver App # URL listed in AppId when connected to new Chroemcast (it still works fine with the old one).
How can I verify that the new whitelisted device connected to the same old AppID or Developer ID?
Thanks.
After a request to chromecast-updates#google.com the ChromeCast team fixed the problem on their side. Thanks.

Resources