MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.

    [MMM-Screen-Powersave-Notification] A module which (de)activates the screen based on delay and notifications

    Scheduled Pinned Locked Moved Utilities
    4 Posts 2 Posters 1.3k Views 2 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • wishmaster270W Offline
      wishmaster270 Module Developer
      last edited by wishmaster270

      Description:

      This module is inspired by https://github.com/mboskamp/MMM-PIR and https://github.com/mboskamp/MMM-PIR but is controlled by notifications;
      Based on “USER_PRESENCE”, “SCREEN_ON”, “SCREEN_OFF” and “SCREEN_TOGGLE” notifications the screen is controlled; By default “vcgencmd” command is used to turn the screen on or off and also to check the current status but it can be changed in the config file;
      After the configured delay (which can be changed during rutime with an “SCREEN_POWERSAVE” notification) the screen will be turned off if no “USER_PRESENCE” notification had been send;
      If needed custom scripts can be run after switching the screen on or off;

      Download:

      MMM-Screen-Powersave-Notification
      [card:Tom-Hirschberger/MMM-Screen-Powersave-Notification]


      0.0.9

      • the DOM objects now only will be updated if a position is set in the configuration
      • fixed all issues reported by the new automatic module scanning script developed by @KristjanESPERANTO

      0.0.8

      • using spawnSync and spawn instead of execSync and exec now. the old commands caused “Error: write EFAULT” exceptions in installations with current nodejs and electron versions

      0.0.7

      • added scripts and description of how to use xrandr or tvservice as an alternative to the default vcgencmd command to control the screen. xrandr is the only solution working with current “vc4-kms-v3d” driver used in Raspberry Bullseye operating system.
      • fixed reset of screen timeout in “hideInsteadShutoff” mode.
      • the screen will be turned on if USER_PRESENCE notification is received, now. No need to send “USER_PRESENCE” and “SCREEN_ON” notifications, now.
      • the forced option in the payload of the notifications can be set either as string or as boolean value (String was need for notifications send by MMM-RemoteControl)
      • the html DOM objects now only will be updated if the module has a position set, now.

      0.0.6

      • fixed “hideInsteadShutoff” feature
      • added a new option to change to a specific profile before the “normal” action is triggered

      0.0.5

      • it now is possible to change to configured profile instead of shutting off the screen

      0.0.4

      • a new config option “hideInsteadShutoff” only hides/shows the modules instead of shutting off /on the display; the additional scripts can be used as if shutting down / on

      0.0.3

      • It is now possible to display an countdown if an module position is configured

      0.0.2

      • It is now possible to define different delays for different profiles (MMM-ProfileSwitcher)

      0.0.1

      • Supports “USER_PRESENCE”, “SCREEN_ON”, “SCREEN_OFF”, “SCREEN_TOGGLE” and “SCREEN_POWERSAVE” notifications
      • Scripts can be run after turning the screen on or off (i.e. to (de)activate a microphone)
      • Forced down/up is supported (i.e. to ignore an PIR event)
      1 Reply Last reply Reply Quote 1
      • S Offline
        sdetweil
        last edited by sdetweil

        note that some of us (me) have displays that will not turn off at all… also not on PI…

        so my MMM-SleepWake uses module hide/show (and have to remember what was hidden before show to not screw up those page based modules… or modules hidden by voice…)

        Sam

        How to add modules

        learning how to use browser developers window for css changes

        wishmaster270W 1 Reply Last reply Reply Quote 0
        • wishmaster270W Offline
          wishmaster270 Module Developer @sdetweil
          last edited by

          @sdetweil You are absolutly right. But it is a totally different aproach. Hiding the modules to get the background as dark as possible does not save the same energy as turning off the screen. I am one of the lucky guys that uses a Benq monitor which shuts off in a second after turning off the signal and is back in less than three when turning it on again.
          I think your module is the perfect solution for people who are not that lucky

          1 Reply Last reply Reply Quote 0
          • wishmaster270W Offline
            wishmaster270 Module Developer
            last edited by

            I did a lot of work to the module the last days. Now modules can be hidden / shown instead of turning off/on the display. Also a countdown can be displayed and the delay can be set by active profile (MMM-ProfileSwitcher)

            1 Reply Last reply Reply Quote 1
            • 1 / 1
            • First post
              Last post
            Enjoying MagicMirror? Please consider a donation!
            MagicMirror created by Michael Teeuw.
            Forum managed by Sam, technical setup by Karsten.
            This forum is using NodeBB as its core | Contributors
            Contact | Privacy Policy