I've built a very simple custom receiver for Chromecast, but I can't seem to get it to launch. When I try, I get the following error...
{
code: 'session_error',
description: 'CANCELLED',
details: {
reason: 'CANCELLED',
type: 'LAUNCH_ERROR'
}
}
I have no idea what this means or how to get more information about the error. The app worked last night, but stopped when I came in to work this morning.
Here's what I've tried:
- Verified that "Send serial number to Google" is checked.
- Rebooted Chromecast.
- Performed factory resets (reverified that "Send serial number' is checked).
- Verified that my device is registered in the Chromecast console (double checked serial number)
- Created a new app in the Chromecast console and using that ID to launch the receiver.
- Chromecast debugger. It connects to the device OK, but doesn't seem to help with this error. I get a "Detached from the target" message when I run the app and re-attaching doesn't show any errors.
- Confirmed that I'm able to connect to the receiver from my Android tablet (it's just an html page).
The only thing I can think of that changed between last night and this morning is that I'm using my phones hotspot to connect my Chromecast to my laptop (it's the only semi-reliable wifi I have access to at the office). i took my phone with me when I left, so the laptop and Chromecast became disconnected overnight. However, since I'm able to communicate with Chromecast (my sender app - a html page - can see the device, the built-in media apps work, the debugger can connect, etc), that doesn't seem to be the culprit.
Here is the code for the receiver...
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>Hello World Chromecast App</title>
</head>
<body>
Hello World!
<script src="//www.gstatic.com/cast/sdk/libs/receiver/2.0.0/cast_receiver.js"></script>
<script>
window.onload = function () {
window.castReceiverManager = cast.receiver.CastReceiverManager.getInstance();
window.castReceiverManager.start();
}
</script>
</body>
</html>
Any ideas of what I can try to either fix this or find out what the actual error is?