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-Touch

    Scheduled Pinned Locked Moved System
    36 Posts 7 Posters 23.6k Views 10 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.
    • S Offline
      sdetweil @MrCoffee
      last edited by sdetweil

      @MrCoffee no idea… either in the module folder or MM folder…

      but if there is a fatal error, it probably cant write the logs

      Sam

      How to add modules

      learning how to use browser developers window for css changes

      MrCoffeeM 1 Reply Last reply Reply Quote 0
      • MrCoffeeM Offline
        MrCoffee @sdetweil
        last edited by

        @sdetweil Ok. I see. So I will have to ask gfischershaw.
        Thx

        1 Reply Last reply Reply Quote 0
        • 3 Offline
          3squaremirror
          last edited by

          can someone provide me with an example of Executing methods of module?

          i’d like to create a swipe up and swipe down to hide and unhide a module. thank you.

          S M 2 Replies Last reply Reply Quote 0
          • S Offline
            sdetweil @3squaremirror
            last edited by

            @3squaremirror can u be more specific, execute methods of a module?

            Sam

            How to add modules

            learning how to use browser developers window for css changes

            3 1 Reply Last reply Reply Quote 0
            • M Offline
              MMRIZE @3squaremirror
              last edited by

              @3squaremirror
              I have not tested yet, but you can get a concept. (I’ll assume you are using default configuration and mode)

                gestureCommands: {
                  "default": {
                    "SWIPE_UP_1" : (commander) => {
                      commander.getModules().forEach((m) => {m.show()})
                    },
                    "SWIPE_DOWN_1" : (commander) => {
                      commander.getModules().forEach((m) => {m.hide()})
                    }
                  }
                },
              

              Swiping up with one finger would reveal modules.
              Swiping down with one finger would hide modules.
              But in the real world, some modules are protected with lock string from hiding/showing,

              3 1 Reply Last reply Reply Quote 0
              • 3 Offline
                3squaremirror @MMRIZE
                last edited by

                @MMRIZE I saw that in the example in the GitHub page. I’m confused on where to specify which module to hide/show. Thanks.

                1 Reply Last reply Reply Quote 0
                • 3 Offline
                  3squaremirror @sdetweil
                  last edited by

                  @sdetweil to hide and show a specific module.

                  S M 2 Replies Last reply Reply Quote 0
                  • S Offline
                    sdetweil @3squaremirror
                    last edited by

                    @3squaremirror i understood that part…

                    I think @MMRIZE answered

                    Sam

                    How to add modules

                    learning how to use browser developers window for css changes

                    3 1 Reply Last reply Reply Quote 0
                    • 3 Offline
                      3squaremirror @sdetweil
                      last edited by

                      @sdetweil I’m not clear on where to specify the module I want to hide/show. Can you help me understand? Thank you.

                      S 1 Reply Last reply Reply Quote 0
                      • S Offline
                        sdetweil @3squaremirror
                        last edited by

                        @3squaremirror i believe @MMRIZE provided code to hide all, and you could have a list (or only one) module name to match for hiding/showing

                        Sam

                        How to add modules

                        learning how to use browser developers window for css changes

                        1 Reply Last reply Reply Quote 0
                        • M Offline
                          MMRIZE @3squaremirror
                          last edited by

                          @3squaremirror

                          "SWIPE_UP_1" : (commander) => {
                            let clock = commander.getModule('clock')
                            clock.hide()
                          },
                          

                          https://github.com/gfischershaw/MMM-Touch/wiki/Manual#command

                          3 1 Reply Last reply Reply Quote 0
                          • 3 Offline
                            3squaremirror @MMRIZE
                            last edited by

                            @MMRIZE THANK YOU! much appreciated.

                            1 Reply Last reply Reply Quote 0
                            • 3 Offline
                              3squaremirror
                              last edited by

                              one other question. I’m trying to make use of the onIdle function to activate a screensaver page in my MMM-pages.

                              from Pages’s github

                              SHOW_HIDDEN_PAGE	String	MMM-pages will switch to the provided hidden page name.
                              

                              from Touch’s github

                              // will send a TOUCH_IDLE_TRIGGERED notification
                              onIdle: "TOUCH_IDLE_TRIGGERED",
                              

                              I’ve successfully got the Touch module to send a notification based on the onIdle timer. I just don’t know how to specify my Page’s screensaver page along with the payload.

                              "SHOW_HIDDEN_PAGE", 'screenSaver'
                              

                              my code for each module

                              {
                                      module: 'MMM-pages',
                              	disabled: false,
                                  classes: 'default everyone',
                                      config: {
                                              modules:
                                                  [[ "MMM-DateOnly", "clock2" ],
                              			[ "MMM-OpenWeatherMapForecast", "clock" ],
                                          [ "calendar", "clock" ],
                              			[ "clock", "MMM-Wallpaper" ]
                              			],
                                              fixed: [ "weather", "MMM-page-indicator", "MMM-SimpleLogo" ],
                                              hiddenPages: {
                                                  "screenSaver": [ "MMM-Wallpaper", "MMM-FlipClock" ],
                                                  "admin": [ "MMM-ShowMeSystemStatsModule", "MMM-AnOnScreenMenuModule" ],
                                              },
                                      }
                                  },
                              
                              {
                                  module: "MMM-Touch",
                                  position: "top_bar",
                                  disabled: false,
                                  config: {
                                  debug: false,
                                  useDisplay: false,
                              	autoMode: false,
                                  defaultMode: "default",
                              
                                threshold: {
                                  idle_ms: 3000, // Idle time (in milliseconds) after which the defined "onIdle" notification / callback function should be triggered
                                },
                                onIdle: ("SHOW_HIDDEN_PAGE", 'screenSaver'),
                              
                                      gestureCommands: {
                                          default: {
                                              TAP_1: (commander) => {
                                                  commander.sendNotification("USER_PRESENCE", true);
                                              },
                                              PRESS_1: (commander) => {
                                                  commander.sendNotification("USER_PRESENCE", true);
                                              },
                                              TAP_2: (commander) => {
                                                  commander.sendNotification("LOAD_NEXT_WALLPAPER", true);
                                              },
                              
                                              "SWIPE_UP_1" : (commander) => {
                                                let clock = commander.getModule('MMM-OpenWeatherMapForecast')
                                                clock.show()
                                              },
                                              "SWIPE_DOWN_1" : (commander) => {
                                                let clock = commander.getModule('MMM-OpenWeatherMapForecast')
                                                clock.hide()
                                              },
                              
                                              SWIPE_UP_2: (commander) => {
                                                  commander.sendNotification("SHOW_HIDDEN_PAGE", "screenSaver");
                                              },
                                              SWIPE_DOWN_2: (commander) => {
                                                  commander.sendNotification("LEAVE_HIDDEN_PAGE");
                                              },
                              
                                              SWIPE_LEFT_1: (commander) => {
                                                  commander.sendNotification("PAGE_INCREMENT", null);
                                              },
                                              SWIPE_RIGHT_1: (commander) => {
                                                  commander.sendNotification("PAGE_DECREMENT", null);
                                              }
                                          },
                                      }
                                  }
                              },
                              
                              M 1 Reply Last reply Reply Quote 0
                              • M Offline
                                MMRIZE @3squaremirror
                                last edited by

                                @3squaremirror
                                Currently, MMM-Touch’s onIdle notification or function couldn’t carry the payload value.

                                One solution would be modifying the source. It is not so difficult. Just a few lines are needed for that. Then make a PR and wait to be accepted by the module owner.

                                The real issue is… The module owner - @gfischershaw seems not to manage this module any more. As an original developer of this module, I feel some responsibility. Maybe I should get back from this unmaintained situation. (I’m not sure what to do yet.)

                                Second solution would be the conjunction with MMM-NotificationTrigger module. It could chain/translate one notification to other notifications. So you can relay TOUCH_IDLE_TRIGGERED to {SHOW_HIDDEN_PAGE, 'screenSaver'} . See that. Or I think there would be some equivalent modules somewhere.

                                3 1 Reply Last reply Reply Quote 0
                                • 3 Offline
                                  3squaremirror @MMRIZE
                                  last edited by

                                  @MMRIZE thank you for responding, that works well.

                                  1 Reply Last reply Reply Quote 0

                                  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
                                  • 1
                                  • 2
                                  • 1 / 2
                                  • 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