This appears to be an issue with MMM-Remote-Control, which has a “MONITOROFF” command that I was using to turn off the display. That command executes tvservice -o
, which according to this documentation “destroys any framebuffers/dispmanx layers associated with the display” that are not restored when the display comes back on. On their recommendation, I switched the command to vcgencmd display_power 0
and my issues have gone away.
Read the statement by Michael Teeuw here.
Latest posts made by nealterrell
-
RE: Mirror does not update after turning monitor back on
-
Mirror does not update after turning monitor back on
I have tried to search for this problem but to no avail.
My mirror uses MMM-PIR-Sensor to turn on the screen when detecting motion, and then off again after 10 seconds. But most times the screen turns on, the UI is “out of sync” with the current time – the clock is wrong, modules haven’t been shown/hidden on schedule with MMM-ModuleScheduler, any Alerts that were triggered won’t show, etc. Sometimes I can see the screen “catch up” if I stay in front of it for a few seconds; sometimes the screen never catches up, and I have to restart the service. I can pull up a browser from another computer or on the Pi, point it at the MM server, and everything is fine on that device – this only seems to be a problem with the default
npm start
MM process.Has anyone experienced this issue?
-
RE: node serveronly works, but npm start doesn't
@sdetweil I found that MMM-PIR-Sensor was failing when requiring
onoff
, so I wiped itsnode_modules
,npm install
, and now everything is fine. Sorry for wasting your time! -
RE: node serveronly works, but npm start doesn't
@sdetweil Thank you for your reply. Raspberry Pi 4. Initially I upgraded with
git pull && npm install
, but I found your upgrade script and ran that. Now I added-x
to run-start, and this is the output:> magicmirror@2.10.0 start /home/pi/MagicMirror > ./run-start.sh + ./untrack-css.sh + '[' -z :0.0 ']' ++ uname -m + arch=armv7l + false=false ++ grep -v '^\s//' config/config.js ++ grep -i serveronly: ++ awk '{print tolower($2)}' ++ tr -d ',"'\''' + serveronly= + serveronly=false ++ pgrep Xorg + xorg=454 ++ uname + mac=Linux + '[' false. '!=' false. -o armv7l == armv6l ']' + '[' 454. == . -a Linux '!=' Darwin ']' + electron js/electron.js [17:16:24.796] [LOG] Starting MagicMirror: v2.10.0 [17:16:24.810] [LOG] Loading config ... [17:16:24.820] [LOG] Loading module helpers ... [17:16:24.948] [LOG] Initializing new module helper ... [17:16:24.949] [LOG] Module helper loaded: MMM-Remote-Control
I added some logging to
app.js
where it loads modules, and the process terminates on the lineModule = require(helperPath)
whenhelperPath
is the MMM-PIR-Sensor module.I don’t expect you to diagnose every misbehaving module, so I’ll continue to dig and see what went wrong. Any advice would be appreciated; especially regarding why there’s no issue with
node serveronly
. -
node serveronly works, but npm start doesn't
How can I go about diagnosing an issue where
node serveronly
works fine, butnpm start
(whether on a terminal or viapm2
) fails silently? The only log information fromnpm
is this:> magicmirror@2.10.0 start /home/pi/MagicMirror > ./run-start.sh [15:42:38.586] [LOG] Starting MagicMirror: v2.10.0 [15:42:38.595] [LOG] Loading config ... [15:42:38.600] [LOG] Loading module helpers ... [15:42:38.689] [LOG] Initializing new module helper ... [15:42:38.690] [LOG] Module helper loaded: MMM-Remote-Control (process terminates)
It’s something to do with the
MMM-PIR-Sensor
module – removing it from config fixesnpm start
– but the module works fine innode serveronly
mode, so I am having trouble identifying the problem.