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

    Posts

    Recent Best Controversial
    • RE: LED Backlight for mirror - PIR to control them

      I did this.

      alt text

      I used the MMM-PIR-Sensor module and changed the following in node_helper.js:

      From:

              if (data.indexOf("0x120002") !== -1)
                exec("/opt/vc/bin/tvservice --preferred && chvt 6 && chvt 7", null);
      

      To:

              if (data.indexOf("0x120002") !== -1){
                exec("/opt/vc/bin/tvservice --preferred && chvt 6 && chvt 7", null);
                exec("python /home/pi/py-spidev/RPi-LPD8806/LED.py");
             }
      

      and

      From:

            exec("/opt/vc/bin/tvservice -o", null);
      

      To:

            exec("/opt/vc/bin/tvservice -o", null);
            exec("python /home/pi/py-spidev/RPi-LPD8806/off.py");
             }
      

      Note that in the first from - to there is a “)” missing in the original code that you will need to fix. Also note that as soon as the module gets updated if you hack the code like I did above it will be wiped out when you update.

      posted in General Discussion
      O
      orayoflighto
    • RE: LED Backlight for mirror - PIR to control them

      @cowboysdude

      I used these only because they were incredibly cheap and I originally started out looking at MMM-PiLights which uses the same LPD8806 type:

      https://www.amazon.com/gp/product/B01COEJST8/ref=oh_aui_detailpage_o09_s00?ie=UTF8&psc=1

      I used this python code:
      https://github.com/longjos/RPi-LPD8806

      posted in General Discussion
      O
      orayoflighto
    • RE: MMM-GooglePhotos

      For those just joining, I was able to get this to work using the Google OAuth desktop option and the V2 token generator that hermanho made at the link below

      https://github.com/aneaville/MMM-GooglePhotos/issues/145

      posted in Entertainment
      O
      orayoflighto
    • RE: MMM-PiLights - Control a LPD8806 Led Strip on a Raspberry Pi

      I ordered these:
      https://www.amazon.com/gp/product/B01COEJST8/ref=oh_aui_detailpage_o09_s00?ie=UTF8&psc=1

      FYI - for those that are reading this in the future, make sure that your power supply ground is grounded to the RPi ground. That tripped me up.

      posted in Utilities
      O
      orayoflighto
    • RE: MMM-PiLights notification trigger for PIR

      The answer to my question is to add the sendNotification line in the MMM-PiLights.js as follows:
      From:

      	socketNotificationReceived: function(notification, payload) {
      		if (notification === "USER_PRESENCE"){
      			this.sendNotification(notification, payload)
      		}
      

      To:

      	socketNotificationReceived: function(notification, payload) {
      		if (notification === "USER_PRESENCE"){
      			this.sendNotification(notification, payload);
                              this.sendNotification('PILIGHTS_SEQUENCE', 'blue_pulse');
      		}
      

      Unfortunately I have realized that I want to do something more elaborate then the PiLights module allows so instead I am now calling a python script instead.

      posted in Troubleshooting
      O
      orayoflighto
    • RE: LED Backlight for mirror - PIR to control them

      Different strips have different ways they need to be programmed. Some have faster refresh rates than others.

      Most people will suggest ADA102 for beginners. The strips I linked to are LPD8806. As I mentioned previously the only reason I bought those ones is that MMM-PiLights was programmed to use them.

      posted in General Discussion
      O
      orayoflighto
    • 1 / 1