Read the statement by Michael Teeuw here.
Multiple screens fo MM.
-
@chichi1887 well, you need two pm2_MagcMirror.json, right? and each points to a different mm.sh, right?
original
pm2_MagicMirror.json"apps" : [{ "name" : "MM_Screen1", "script" : "/home/pi/MagicMirror/installers/mm.sh", "watch" : ["/home/pi/MagicMirror/config/config.js"]
new pm2_MagicMirror2.json
"apps" : [{ "name" : "MM_Screen2", "script" : "/home/pi/MagicMirror/installers/mm2.sh", "watch" : ["/home/pi/MagicMirror/config/config2.js"]
then
pm2 start each json
and then pm2 saveto test before pm2 start , you can
cd ~/MagicMirror installers/mm2.sh
or
cd ~/MagicMirror installers/mm.sh
to start them both, open another terminal window or ssh session, starting one in each
ctrl-c in the term window will end that instance
-
@sdetweil said in Multiple screens fo MM.:
cd ~/MagicMirror
installers/mm2.shHey,
the mm.sh starts without a problem but the second has this
all modules that starts on the mm.sh are disable in the mm2 config.
Display=0 in both are correkt or the second must be nr.1? -
When I start the mm2.sh script, despite the correct configuration, it takes the config.js instead of the config2.js. Therefore, it seems unable to start both instances simultaneously because it attempts to open the same config.js. The configuration looks like this in the mm2.sh script:
cd ~/MagicMirror
export MM_CONFIG=config2.js
DISPLAY=:0 npm startthe pm2_MagicMirror2.json is copy and paste from u ;-)
-
@chichi1887 see this from the doc
-
-
@chichi1887 yes , Linux treats the two monitors as one big display, so you have to add
electronOptions:{ left:xxxx}
above the modules:[] listto one of the config.js to move the second mm over one screen width size
if vertical, then it’s y:xxxx
-
@sdetweil said in Multiple screens fo MM.:
electronOptions:{ left:xxxx}
above the modules:[] listif vertical, then it’s y:xxxx
Live example - I use two 1920x1080 monitors, my system is using latest OS, but with X11 turned on rather than Wayland for compatibility reasons to some background tasks:
var config = { address: "0.0.0.0", port: 8081, electronOptions: { x: 1920 }, // Right here! ipWhitelist: [], language: "en", timeFormat: 12, units: "imperial", customCss: "css/custom2.css", modules: [
-
@sdetweil thx u so much. All Modules and configs works Perfect. thx
-
@chichi1887 awesome. thanks for the feedback