Read the statement by Michael Teeuw here.
How I got my Magic Mirror working on a Raspberry Pi 0 (zero)
-
@12wsx Change the Port from 8080 to 8099 and then try again…solved a lot of problems for me…
-
After some weeks with the MagicMirror running, my SD card got corrupted and I decided to reinstall the system from scratch. I switched from “Jessie Light” to “Stretch light”, used node 6.11.4 and of course the latest MagicMirror 2.1.3.
I can access the MM from the browser of my laptop, but Midori only shows a white page. Even for a very simple config file:
var config = { address: "", port: 8080, ipWhitelist: ["192.168.2.185", "127.0.0.1", "::ffff:127.0.0.1", "::1"], language: "en", units: "metric", modules: [ { module: "helloworld", position: "bottom_bar", config: { text: "Hello world!" } } ] }; /*************** DO NOT EDIT THE LINE BELOW ***************/ if (typeof module !== "undefined") {module.exports = config;}The start of MM gives no error
Starting MagicMirror: v2.1.3 Loading config ... Loading module helpers ... No helper found for module: helloworld. All module helpers loaded. Starting server on port 8080 ... Server started ... Sockets connected & modules started ... Ready to go! Please point your browser to: http://localhost:8080and if I change from
midori -e Fullscreen -a http://localhost:8080to
midori -e Fullscreen -a http://www.google.deI see the google page. So Midori itself and the output on screen seems working as well.
Is anybody having an idea where to search for the error?
Is anybody using MagicMirror 2.1.3 on its Pi Zero? -
@Hawking same problem rpi 1
-
This post is deleted! -
first set:
set ipWhitelist: [] to allow all IP addresses.Warning, this enables from everywhere (on your net) have access.
then in webbrowser go to pizero ip with port set in config ex. 192.168.1.12:8080 and check if its working -
don’t work for me, cannot connect to destination :-(
when i do
DISPLAY=:0 npm start
npm ERR! path /home/pi/package.json
npm ERR! code ENOENT
npm ERR! errno -2
npm ERR! syscall open
npm ERR! enoent ENOENT: no such file or directory, open ‘/home/pi/package.json’
npm ERR! enoent This is related to npm not being able to find a file.
npm ERR! enoentnpm ERR! A complete log of this run can be found in:
npm ERR! /home/pi/.npm/_logs/2017-10-19T18_58_10_170Z-debug.log -
why he’s looking for /home/pi/package.json then it is /home/pi/MagicMirror/package.json ?
This is my log
/home/pi/.npm/_logs/2017-10-19T18_58_10_170Z-debug.log:
0 info it worked if it ends with ok
1 verbose cli [ ‘/usr/local/bin/node’, ‘/usr/local/bin/npm’, ‘start’ ]
2 info using npm@5.3.0
3 info using node@v8.3.0
4 verbose config Skipping project config: /home/pi/.npmrc. (matches userconfig)
5 verbose stack Error: ENOENT: no such file or directory, open ‘/home/pi/package.json’
6 verbose cwd /home/pi
7 verbose Linux 4.1.19+
8 verbose argv “/usr/local/bin/node” “/usr/local/bin/npm” “start”
9 verbose node v8.3.0
10 verbose npm v5.3.0
11 error path /home/pi/package.json
12 error code ENOENT
13 error errno -2
14 error syscall open
15 error enoent ENOENT: no such file or directory, open ‘/home/pi/package.json’
16 error enoent This is related to npm not being able to find a file.
17 verbose exit [ -2, true ] -
@Doubleve
In which directory did you executenpm start
? I would assume you would first go to your MagicMirror directory (cd /home/pi/MagicMirror). This would also explain the problem with the missing package.json file.However, I’m not sure if
npm startworks at all in combination with the serveronly mode (needed for the Pi Zero). For starting, I use the method described in the first post of this thread in the section “Setting up boot scripts”.I can acccess my MM from remote, however still didn’t get it to show in the Midori browser :-/
-
as you said I was not in the right record.
I had an error with the libnss3 library. Now more errorDISPLAY =: 0 npm start
magicmirror@2.1.3 start / home / pi / MagicMirror
sh run-start.shpi @ raspberrypi ~ / MagicMirror $ npm run config: check
magicmirror@2.1.3 config: check / home / pi / MagicMirror
node tests / configs / check_config.jsChecking file … /home/pi/MagicMirror/config/config.js
Your configuration file not containt syntax error :)but it still does not work with midori
-
What does npm start do in /MagicMirror
-
@noorm91
npm startis the command to start the Magic Mirror application and display the interface on the screen. -
@bhepler
I can’t seem to start MM with npm start, tried through SSH and directly on rpi with keyboard.pi@raspberrypi:~/MagicMirror $ DISPLAY=:0 nohup npm start &
[1] 890
pi@raspberrypi:~/MagicMirror $ nohup: ignoring input and appending output to ‘nohup.out’
^C
[1]+ Exit 1 DISPLAY=:0 nohup npm startpi@raspberrypi:~/MagicMirror $
pi@raspberrypi:~/MagicMirror $ npm startmagicmirror@2.1.0 start /home/pi/MagicMirror
electron js/electron.js/home/pi/MagicMirror/node_modules/electron/dist/electron: error while loading shared libraries: libgconf-2.so.4: cannot open shared object file: No such file or directory
npm ERR! Linux 4.4.34+
npm ERR! argv “/usr/local/bin/node” “/usr/local/bin/npm” “start”
npm ERR! node v4.2.1
npm ERR! npm v2.14.7
npm ERR! file sh
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn
npm ERR! magicmirror@2.1.0 start:electron js/electron.js
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the magicmirror@2.1.0 start script ‘electron js/electron.js’.
npm ERR! This is most likely a problem with the magicmirror package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! electron js/electron.js
npm ERR! You can get their info via:
npm ERR! npm owner ls magicmirror
npm ERR! There is likely additional logging output above.npm ERR! Please include the following file with any support request:
npm ERR! /home/pi/MagicMirror/npm-debug.log -
@noorm91 said in How I got my Magic Mirror working on a Raspberry Pi 0 (zero):
@bhepler
I can’t seem to start MM with npm startThats what I expected for the Pi Zero. Did you try the method described in the first post of this thread in the section “Setting up boot scripts”?
-
I took everything back with the first post everything works !!!
-
@Doubleve
Can you tell me which Linux distribution (lsb_release -a), node version (node -v) and version of MM you are using? -
Hi guys, I saw someone asked before, isn’t there anyone who has a working image for MM2 on a Pi Zero. I tried a lot of things before, cant get it to work. Now, I don’t have a lot of time to experiment with it, school and work are killing me. My mirror is lying around, unused. Please help me out here,
Thanks!! -
@delusional112
Here is an image, it has a couple of errors that needs fixing but the magicmirror starts at least.
If you have any solutions please keep us informed…this image is made by Sebtota.
https://mega.nz/#!XlIU3QjI!QSdvAE3yXp1oMsdRGNte6lt4SncgvfozSDU7xhxtbbMHere is the topic I found the image at.
https://forum.magicmirror.builders/topic/1183/how-i-got-my-magic-mirror-working-on-a-raspberry-pi-0-zero/85?page=9 -
Any clue on what is trying to start and not functioning alright here?
Starting MagicMirror: v2.1.0 Loading config ... Loading module helpers ... No helper found for module: alert. Initializing new module helper ... No helper found for module: clock. No helper found for module: compliments. No helper found for module: currentweather. No helper found for module: weatherforecast. Initializing new module helper ... All module helpers loaded. Starting server op port 8080 ... Server started ... Connecting socket for: updatenotification Connecting socket for: newsfeed Starting module: newsfeed Sockets connected & modules started ... Ready to go! Please point your browser to: http://localhost:8080 Whoops! There was an uncaught exception... { [Error: listen EADDRINUSE :::8080] code: 'EADDRINUSE', errno: 'EADDRINUSE', syscall: 'listen', address: '::', port: 8080 } MagicMirror will not quit, but it might be a good idea to check why this happened. Maybe no internet connection? If you think this really is an issue, please open an issue on GitHub: https://github.com/MichMich/MagicMirror/issues (EE) Fatal server error: (EE) Server is already active for display 0 If this server is no longer running, remove /tmp/.X0-lock and start again. (EE) (EE) Please consult the The X.Org Foundation support at http://wiki.x.org for help. (EE) XIO: fatal IO error 11 (Resource temporarily unavailable) on X server ":0" after 7 requests (7 known processed) with 0 events remaining. -
@noorm91 said in How I got my Magic Mirror working on a Raspberry Pi 0 (zero):
Ready to go! Please point your browser to: http://localhost:8080
Whoops! There was an uncaught exception…
{ [Error: listen EADDRINUSE
:::
8080]This usually means that you already have a process trying to serve up web pages on port 8080. In my experience, this happens when you do not terminate your previous attempt to run the MM process and start up another one. The new one also tries to serve up pages on port 8080 and you get that error.
You can use
ps ax | grep nodeto see if node is running when you attempt to start your mirror. If it is, node is already serving up pages, so you will want to stop whatever process is running first. Alternately, if you are running a web server on port 8080 already, you can switch the port of the MM process in theconfig.jsfile. -
So did anyone get MM2 on a Pi Zero W with Raspian Stretch lite running?
Or is it better to stay with Jessie?
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login