It allow to cast a YouTube video on MagicMirror
This module is an Extented for
MMM-GoogleAssistant
Execute npm run install:EXT-YouTubeCast
in the MMM-GoogleAssistant's folder.
cd ~/MagicMirror/modules/MMM-GoogleAssistant
npm run install:EXT-YouTubeCast
electronOptions
A new part of config is needed for displaying this module.
On the begining of MagicMirror config.js, modify with electronOptions
var config = {
address: "localhost",
electronOptions: {
webPreferences: {
webviewTag: true
}
},
port: 8080,
...
{
module: "MMM-GoogleAssistant/EXTs/EXT-YouTubeCast",
position: "top_center", // optional (can be deleted if using fullscreen)
config: {
debug: false,
fullscreen: false,
width: "30vw",
height: "30vh",
alwaysDisplayed: true,
castName: "MagicMirror",
port: 8569
}
},
Field Type Default Description debug boolean false enable or not debug mode fullscreen boolean false enable fullscreen video (default in windows) width string 30vw width of the your YouTube window (can be a px value too) height string 30vh heigth of the your YouTube window (can be a px value too) alwaysDisplayed boolean true should the YouTubeCast windows have to be always displayed when a video is not playing ? castName string MagicMirror name of the cast device port number 8569 port of the device
Just open YouTube (or YouTube Music) app on your phone/tablet or with the youtube website in a computer
Click on the cast icon and select your device name defined in module configuration
The video will be played on your mirror !
All devices must be in the same network
EXT_YOUTUBECAST-STOP
: Stop the videoEXT_YOUTUBECAST-CONNECTED
: When video startEXT_YOUTUBECAST-DISCONNECTED
: When Video endThis module will hide all modules when a video is playing in fullscreen
It's the better way to disable all modules to increase RPI performance
It will useEXT_LOCKED
lockString
cd ~/MagicMirror/modules/MMM-GoogleAssistant
npm run update
cd ~/MagicMirror/modules/MMM-GoogleAssistant
npm run remove:EXT-YouTubeCast