Read the statement by Michael Teeuw here.
Multiple instances
-
Hello.
I must have expressed myself badly.
yes indeed there is only one on the screen but when I restart the RPI it displays one or the other.
if I understand your explanation correctly, I have to put in the file mm.sh last the instance that I want to display on the physical screen.thank you
-
@elmago What is it that you want to do exactly?
As @sdetweil says, only one instance can be on the screen at a time. Are you trying to run one on the screen and access another one remotely? If you are, this may help.
I’ve got two instances running, and they have different modules and a different port. The ‘standard’ MM instance uses the mm.sh that’s generated from @sdetweil’s script:
cd ./MagicMirror DISPLAY=:0 npm start
while my second instance runs as a server, and doesn’t display on the Pi’s screen. My second instance is in the MagicMirror2 folder and uses this script:
cd ./MagicMirror2 DISPLAY=:0 npm run server
I use a separate .sh script, but someone more knowledgeable could probably combine them. The first section of the config.js lets you define which port you want MM to use, so I changed it on the one I wanted to view remotely.
var config = { address: '0.0.0.0', port: 12345, ipWhitelist: [ '127.0.0.1', '::ffff:127.0.0.1', '::1', '::ffff:192.168.0.1/120', '192.168.0.1/24' ],
-
-
@elmago you never said u wanted one as a server!..
-
@elmago said in Multiple instances:
Hello
I did like you and it works perfectly.
Thank you so much.
No problem, glad I could help :)
-