[PLUGIN] YouTube Cast Receiver

Hi there!

Thank you for the effort, making this plugin. I have troubles getting the plugin to work. First, it worked flawlessly, but after some time this plugin stopped working. Now, I can cast on the YouTube app, but the video keeps loading and the audio does not come through. I already tried doing a factory reset of my system, but without help. I would greatly appreciate a pointer as to how I can resolve this and can of course provide more information that would help you debugging this problem.

Could you also try restarting your phone and your router?

Hello, looking for a little help with my first Volumio Pi4 build. Running latest everything. Spotify works. YouTube will not cast. My YouTube app sees the device as an option, but never actually connects. Any suggestions?

plugin seems to work fine over hereā€¦

Try restarting your phone

Yep, that seems to have done the trickā€¦ I restarted the router and the Pi but not my phone. Doh!

Update, back to not working.

Hello. Plugin seems to work fine over here.

Is there any way to continue watching the movie on the primary device after turning on the YouTube Cast Receiver (volumio) on a secondary device?
*I would like to see the image on my notebook and listen to the audio from a raspberry pi (volumio) connected to a external DAC.

Thanks

It is not possible because that is not how casting works. In this case, sending the audio via Bluetooth is probably the most straightforward method.

1 Like

hey I also have a problem where I canā€™t get any further, Iā€™m probably on the hose

PI4 Volumio 3.198

R: ===================================================================
(node:2030) UnhandledPromiseRejectionWarning: TypeError: Cannot read property ā€˜nameā€™ of null
at EventEmitter. (/data/plugins/music_service/ytcr/index.js:237:76)
at EventEmitter.emit (events.js:315:20)
at EventEmitter. (/data/plugins/music_service/ytcr/node_modules/yt-cast-receiver/lib/index.js:52:16)
at EventEmitter.emit (events.js:315:20)
at YouTubeApp.stop (/data/plugins/music_service/ytcr/node_modules/yt-cast-receiver/lib/app.js:158:31)
at runMicrotasks ()
at processTicksAndRejections (internal/process/task_queues.js:93:5)
(node:2030) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag --unhandled-rejections=strict (see Command-line API | Node.js v17.5.0 Documentation). (rejection id: 3)

youtube2 runs with the api

but i canā€™t get youtube cast to work

thx for help :slight_smile:

This is odd. A direct interpretation of the error means the connection disconnected before it is established, which doesnā€™t make senseā€¦

I have tested with YouTube mobile app v17.06.32 and can connect without issues. Could you try restarting Volumio, your mobile and your router?

I got it working before but with volumio3 no youtube turning up. I rebooted serval times So we have to wait for new release volumio3?

I did reinstalling it with version 1.8.0 beta then it works

when I try to at google api with add user I got error that my youtube account is not allowed. I followed youre manual to the letter.

I just tried creating a new set of Google API credentials and did not encounter this issue.

Is the test user email address the same as the one you use for creating the credentials?

youtube cast doesnt work from iphone to volumio, 1st disconted and in 2nd try keeps connecting

from log:
cast from phone
dial: returning pid 84b225f5-1646-45bf-b5ff-f3796ad1050c
after retry:
info: [ytcr] ***** Disconnected *****

editā€¦ was casting from youtube music appā€¦ from youtube works!
its possible to make it possible to stream also from music app? :smiley:

Technically impossible at the moment.

Perhaps a stupid question (indicating that I havenā€™t understood what the plugin does): What is the difference to if I use Youtube e.g. on my laptop and stream the audio via bluetooth to Volumio?

Bluetooth: stream is fetched on laptop / phone. Audio of said stream then gets transcoded and sent to receiver for playback.
YouTube cast: video ID sent to plugin. Plugin then fetches stream from YouTube for playback.

Sound quality-wise, probably not much difference in this case since YouTube streams are low quality.