MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    1. Home
    2. evroom
    3. Posts
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.
    evroomE Offline
    • Profile
    • Following 0
    • Followers 2
    • Topics 18
    • Posts 499
    • Groups 1

    Posts

    Recent Best Controversial
    • RE: Strange issue

      @richland007
      I re-read your first post and your problem is more restarting then actual crashing.
      Of course a restart can be caused by a crash …
      MMM-WatchDog tends to restart MM, so I too would suggest to remove this module.
      In principle all it does is sending a ping and restarting MM using pm2 when a timeout occurs.
      I also would expect to see some lines in the pm2 logs on WatchDog.
      Can you do ?:

      pi@MagicPi:~ $ grep -i watchdog /home/pi/.pm2/logs/mm-out.log
      pi@MagicPi:~ $ grep -i watchdog /home/pi/.pm2/logs/mm-error.log
      

      What is alo a good package to install is sysstat:

      pi@MagicPi:~ $ sudo apt-get install sysstat
      

      This allows for commands like iostat and sar.

      vmstat 10 10
      iostat 10 10
      sar 10 10
      
      posted in Troubleshooting
      evroomE
      evroom
    • RE: Strange issue

      Ha ha, not that great, my MM is as slow as a turtle again.
      The used swap on my USB stick in the meanwhile is 1GB.
      Cannot use any commands to investigate further.
      Not very satisfactory. :frowning_face:

      posted in Troubleshooting
      evroomE
      evroom
    • RE: Strange issue

      @richland007

      Then let’s give it a try :slightly_smiling_face:

      First create the script:

      pi@MagicPi:~ $ cd
      pi@MagicPi:~ $ nano top.sh
      

      Copy-paste this:

      !/bin/sh
      
      date >> /home/pi/top.txt
      top -b -o +%MEM | head -n 22 >> /home/pi/top.txt
      top -b -o +%MEM | head -n 22 >> /home/pi/top.txt
      echo "=============================================" >> /home/pi/top.txt
      

      Make it executable:

      pi@MagicPi:~ $ chmod 755 top.sh
      

      Perhaps a good idea to prepare the output file in order to be sure the cron user can write in it:

      pi@MagicPi:~ $ touch /home/pi/top.txt
      pi@MagicPi:~ $ chmod 666 /home/pi/top.txt
      

      Now we add a cronjob:

      pi@MagicPi:~ $ crontab -e
      

      Add this line at the end:

      00,05,10,15,20,25,30,35,40,45,50,55 * * * * /home/pi/top.sh >/dev/null 2>&1
      

      To verify:

      pi@MagicPi:~ $ crontab -l
      

      To verify if the cronjob is actually running:

      pi@MagicPi:~ $ tail -F /var/log/syslog
      

      To check if something comes in your output file:

      pi@MagicPi:~ $ tail -F top.txt
      

      The script will run every 5 minutes, every hour, every day.
      It will output the top 15 MEMory usage and the top 15 CPU usage.

      In your case, it will be interesting to look at the last entries before the crash.
      Need to identify first if it is an CPU or MEM issue, or both.
      Then we can modify the script.

      Please do not post lengthy output.
      Better we minimise the output by grepping and sorting, etc.

      Success!

      posted in Troubleshooting
      evroomE
      evroom
    • RE: Strange issue

      @richland007
      Since you managed to setup MM to the point that it is running, but crashing, I take it you know a little bit of Linux.
      Otherwise it will be more like a Linux workshop.

      Do you know how to use nano and/or vi to edit files?
      Know what for example cat, tail and head does?
      Just some Linux basics.

      I do not want to sound like a smartarse and knowitall, am a hobbyist just like you.
      Just to know the level of describing that is needed.

      posted in Troubleshooting
      evroomE
      evroom
    • RE: Strange issue

      Hi,

      Investigating crashes and freezes, etc, can be very difficult.
      When everything is running fine and you collect data, you will see that everything is more or less okay.
      When it crashed or is frozen, you are too late.

      Since a few weeks I had the problem that my MM was frozen and I could not enter any commands or a command took painstakingly long to return output.
      A command like top was out of the question for example.
      Using a script running as a cron job, I was able to identify a memory issue with electron.js.
      I then decide to use a usb stick on which I created a swap device.
      Since then my MM is not freezing anymore.
      And I am able to see electron.js using up my memory and sometimes I see spikes in CPU usage.

      Mind you, that crashing is something different then freezing, but the tools to use are more or less the same, provided the MM application or a MM module is not the culprit.

      My script to check memory usage, very basic and simple:

      pi@MagicPi:~ $ cat top.sh
      #!/bin/sh
      
      date >> /home/pi/top.txt
      top -b -o +%MEM | head -n 22 >> /home/pi/top.txt
      echo "=============================================" >> /home/pi/top.txt
      

      The cron job:

      00,05,10,15,20,25,30,35,40,45,50,55 * * * * /home/pi/top.sh >/dev/null 2>&1
      

      %CPU will sort on CPU usage.

      Concerning swap space, top will show the usage, but this gives a quick view:

      $ free -h
      

      Swap details via:

      $ swapon -s
      

      There are many more commands and settings to look at, but one has to start somewhere :-)

      Good luck.

      posted in Troubleshooting
      evroomE
      evroom
    • RE: TV Tuner

      @Cr4z33, no, sorry, didn’t pursue this as I do not need such a function myself.

      posted in Requests
      evroomE
      evroom
    • RE: Change font size for MMM-HTMLBox module

      Some times Google is your friend:

      custom.css

      .MMM-HTMLBox {
      font-size: 18px;
      line-height: 22px;
      }
      
      posted in Custom CSS
      evroomE
      evroom
    • Change font size for MMM-HTMLBox module

      Module: MMM-HTMLBox
      I want to use this simple but useful module, but how can I change font size for this module ?

      I tried the custom.css

      .MMM-HTMLBox {
      font-size: 12px;
      }
      

      That does work, but now the spacing is rather large.
      The module itself does not have a css file.

      Someone who can guide me a bit ?

      posted in Custom CSS
      evroomE
      evroom
    • RE: MagicMirror crashed due to "gnutls_handshake() failed: Error in the push function"

      Btw, a simple restart of MagicMirror solved the issue and my MM is working again.
      Web search tells me that:

      gnutls_handshake(): This function performs the handshake of the TLS/SSL protocol, and initializes the TLS session parameters.

      Looks to be related with git, as all calls were done to github.com.

      posted in Troubleshooting
      evroomE
      evroom
    • MagicMirror crashed due to "gnutls_handshake() failed: Error in the push function"

      Hi,

      This morning my MM showed a black screen and the pm2 log says following:

      /home/pi/.pm2/logs/MagicMirror-error.log last 15 lines:
      0|MagicMir | fatal: unable to access 'https://github.com/fewieden/MMM-soccer.git/': gnutls_handshake() failed: Error in the push function.
      0|MagicMir |
      0|MagicMir | fatal: unable to access 'https://github.com/raywo/MMM-PublicTransportHafas.git/': gnutls_handshake() failed: Error in the push function.
      0|MagicMir |
      0|MagicMir | fatal: unable to access 'https://github.com/shbatm/MMM-RTSPStream.git/': gnutls_handshake() failed: Error in the push function.
      0|MagicMir |
      0|MagicMir | fatal: unable to access 'https://github.com/fmandal/MMM-YrThen/': gnutls_handshake() failed: Error in the push function.
      0|MagicMir |
      0|MagicMir | fatal: unable to access 'https://github.com/MichMich/MagicMirror.git/': gnutls_handshake() failed: Error in the push function.
      0|MagicMir |
      

      I did a search in the forum, but I could not find any other occurrences.
      Will search the web now to see if I can find something more on this topic.
      In the meantime any clue as to what happened is welcome.

      posted in Troubleshooting
      evroomE
      evroom
    • RE: [MMM-RTSPStream] - Video Streaming from Live Feeds & Security Cameras

      I can stream full HD at 50 fps:

      Video codec omx-h264 width 1920 height 1080 profile 100 fps 50.000000

      A bit odd.

      posted in Utilities
      evroomE
      evroom
    • RE: [MMM-RTSPStream] - Video Streaming from Live Feeds & Security Cameras

      RAI 3 HD probably is not free-to-air, so I cannot check it.

      But to be honest, it seems NOT to work for me too.
      Only SD, no HD.
      I had it working on v2.4.1 (made notes about it to not to forget) and did not use it after that.

      You can test it directly, without having to change the MM config all the time:

      $ omxplayer --win "0 0 800 480" --live "http://192.168.1.6:8001/1:0:1:D4B:8800:13E:EEEE0000:0:0:0:"
      
      $ omxplayer --win "0 0 800 480" --live "http://192.168.1.6:8001/1:0:1:2191:5:13E:EEEE0000:0:0:0:"
      

      omxplayer will show the stream details:

      Video codec omx-mpeg2 width 720 height 576 profile 4 fps 25.000000
      Video codec omx-h264 width 1920 height 1080 profile 100 fps 50.000000
      

      On my Pi it seems to run, but nothing appears on the screen.
      :-(

      posted in Utilities
      evroomE
      evroom
    • RE: [MMM-RTSPStream] - Video Streaming from Live Feeds & Security Cameras

      Hi,

      Can you check this ?

      $ vcgencmd codec_enabled MPG2
      

      It should say “MPG2=enabled”.

      License can be bought for a few euro’s:

      http://www.raspberrypi.com/mpeg-2-license-key/

      posted in Utilities
      evroomE
      evroom
    • RE: TV Tuner

      @Cr4z33,

      You can put the code end the end of the file, so after the body stuff.
      If you are not familiar with vi, you can use nano:

      $ nano /home/pi/MagicMirror/css/custom.css
      

      I have made some changes in the body part, to change the screen margins, etc.

      body {
             margin: 10px;
             height: calc(100% - 10px);
             width: calc(100% - 10px);
      }
      
      posted in Requests
      evroomE
      evroom
    • RE: TV Tuner

      Hi,

      Try this:

      # vi /home/pi/MagicMirror/css/custom.css
      :
      :
      .MMM-RTSPStream .innerWrapper {
        border-style: none;
      }
      
      # pm2 restart MagicMirror
      

      I would still try to have the video window and the module window overlap each other, as it perhaps may influence the position and aligning of other modules.

      posted in Requests
      evroomE
      evroom
    • RE: TV Tuner

      Hi,

      I remember it took me quite a while to have it to my likings (size and position of the window(s)).
      The width and height of the stream defines the size of your video.
      The width and height in the config defines the place of the stream and what you actually see.
      A bit difficult to explain.
      Works like a “sjabloon”, template.

      Could you show your MMM-RTSPStream config settings and also a part of the ‘pm2 logs MagicMirror’ output ?
      Where it says: “Starting stream stream1 with args: [”.

      posted in Requests
      evroomE
      evroom
    • RE: MMM-Soccer - Standings, Schedules and Top Scorers

      Hi @surger13 ,

      You do not have the api_key specified.
      The README says:

      api_key: false,
      

      But for me this does not work.
      I registered at https://www.football-data.org/client/register and the resulting api_key is working fine.

      api_key: 'xxxxd62e29754e10b56029399458xxxx',
      

      This is a fake key, use the one you get after registering.

      Good luck.

      posted in Sport
      evroomE
      evroom
    • RE: TV Tuner

      @Cr4z33
      Please find below an example for streaming from an Enigma2 box.
      The most important line is the url.
      The other lines are custom-made for my 2 camera streams.
      The url is taken from VLC, which I use to stream SAT TV to my PC.

      A few remarks on what I experienced:

      For Raspberry Pi, you may need the MPG2 license in order to be able to stream the satellite TS stream.

      The Raspberry Pi 3 Model 3 and omxplayer can only handle 1 TS stream, as it appears to be the case.
      And a maximum 3 RTSP camera streams.
      Perhaps more powerful HW can handle more.

      I did not look into the possibility of choosing between streams / channels.
      This needs some additional programming or even forking the code to make it specific for TS streams.

      Hope it helps.

      config.js :

      {
        module: "MMM-RTSPStream",
        disabled: false,
        position: "middle_center",
        header: "Axis Security Monitor",
        config: {
          autoStart: true,
          rotateStreams: false,
          moduleWidth: 900,
          moduleHeight: 364,
          localPlayer: 'omxplayer',
          remotePlayer: 'none',
          showSnapWhenPaused: false,
          remoteSnaps: false,
          stream1: {
          name: 'SAT-TV',
          url: 'http://192.168.178.28:8001/1:0:19:2B66:3F3:1:C00000:0:0:0:', // ZDF HD
            protocol: "tcp",
            width: 590,
            height: 332
          },
        }
      },
      
      posted in Requests
      evroomE
      evroom
    • RE: MMM-Soccer - Standings, Schedules and Top Scorers

      @strawberry-3-141
      Thanks, works like a charm.

      Any possibility to introduce a rotation option, in order to rotate the standings of the leagues in “show” or “leagues” ?

      posted in Sport
      evroomE
      evroom
    • RE: MMM-Soccer - Standings, Schedules and Top Scorers

      Hi,

      Great job on version 2.0.
      I have it running.
      Added Eredivisie and some logos; all fine.

      Just one question.
      In your example your header is left aligned and shows “1. BUNDESLIGA 2015/16”.
      Not updated to show the version 2.0 example.
      When I choose the Bundesliga I just get “BUNDESLIGA” and it is right aligned.
      How do I get it at least left aligned ?
      I tried adding this to the custom.css, but it doesn’t work:

      .MMM-soccer .header {
          text-align: left;
      }
      
      posted in Sport
      evroomE
      evroom
    • 1
    • 2
    • 21
    • 22
    • 23
    • 24
    • 25
    • 23 / 25