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.

    Not all Modules are displaying on the tv

    Scheduled Pinned Locked Moved Troubleshooting
    34 Posts 6 Posters 11.8k Views 5 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 @lavolp3
      last edited by sdetweil

      @lavolp3 on the show/hide there is an optional additional parameter, the ‘string’ for the lockstring… its any text u want.

      from
      https://docs.magicmirror.builders/development/core-module-file.html#module-instance-methods

      this.hide(speed, callback, options)
      speed Number - Optional (Required when setting callback or options), The speed of the hide animation in milliseconds. callback Function - Optional, The callback after the hide animation is finished. options Function - Optional, Object with additional options for the hide action (see below). (Introduced in version: 2.1.0.)
      
      To hide a module, you can call the hide(speed, callback) method. You can call the hide method on the module instance itself using this.hide(), but of course you can also hide another module using anOtherModule.hide().
      
      Possible configurable options:
      
      lockString - String - When setting lock string, the module can not be shown without passing the correct lockstring. This way (multiple) modules can prevent a module from showing. It's considered best practice to use your modules identifier as the locksString: this.identifier. See visibility locking below.
      

      Sam

      How to add modules

      learning how to use browser developers window for css changes

      lavolp3L 1 Reply Last reply Reply Quote 1
      • lavolp3L Offline
        lavolp3 Module Developer @sdetweil
        last edited by

        @sdetweil Thank you. It seems the hide and show calls in MMM-pages need to be amended by the (standard) lockstring to work properly.
        The module is after all expected to overwrite any other hide/show functionality.
        I had the same issue so I’ll try that out in the next days.

        How to troubleshoot modules
        MMM-soccer v2, MMM-AVStock

        S 2 Replies Last reply Reply Quote 0
        • S Offline
          sdetweil @lavolp3
          last edited by sdetweil

          @lavolp3 Pages uses lockstring already

          module.hide(
                  self.config.animationTime / 2,
                  { lockString: self.identifier }
                ));
          
          
          module.show(
                    self.config.animationTime / 2,
                    { lockString: self.identifier }
                  ));
          

          uses the MMM-Pages module identifier as the string

          Sam

          How to add modules

          learning how to use browser developers window for css changes

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

            @lavolp3 said in Not all Modules are displaying on the tv:

            The module is after all expected to overwrite any other hide/show functionality.

            it may need FORCE (it should check if the hide or show worked)

            Sam

            How to add modules

            learning how to use browser developers window for css changes

            1 Reply Last reply Reply Quote 0
            • kusselinK Offline
              kusselin
              last edited by

              OK. thank you for the detailed discussion. But what does that mean in plain language for everyone or for me as a not so html understanding?
              What must or can I change in my config.js so that it works again?
              Greeting

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

                @kusselin if you use MMM-Pages, every module must be described on some page, or in the fixed list (fixed means every page)

                Sam

                How to add modules

                learning how to use browser developers window for css changes

                1 Reply Last reply Reply Quote 0
                • kusselinK Offline
                  kusselin
                  last edited by

                  @sdetweil said in Not all Modules are displaying on the tv:

                  if you use MMM-Pages, every module must be described on some page, or in the fixed list (fixed means every page)

                  o.k. and how do i this with the describe?? Sorry, but can you give an example please with my config.js with MM-Traffic

                  mumblebajM 1 Reply Last reply Reply Quote 0
                  • mumblebajM Offline
                    mumblebaj Module Developer @kusselin
                    last edited by

                    @kusselin This is an example of mine.

                    2010dc50-cc0a-4515-addf-eb24130fdd08-image.png

                    Modules are either on Page1 or Page 2 and then I have modules (fixed) that display on all pages.

                    Check out my modules at: https://github.com/mumblebaj?tab=repositories
                    Check my blog-post: https://mumblebaj.xyz/
                    Check my MM Container: https://hub.docker.com/repository/docker/mumblebaj/magicmirror/general

                    1 Reply Last reply Reply Quote 0
                    • kusselinK Offline
                      kusselin
                      last edited by

                      and this is mine:

                      {
                          			module: "MMM-pages",
                      		disabled: false,
                          			config: {
                                  				modules: 
                      			[[ "MMM-SoccerLiveScore" ],
                      			[ "MMM-NowPlayingOnSpotify" ],
                      			[ "MMM-COVID19-AMPEL" , "MMM-Traffic" ],
                      			[ "MMM-Formula1" , "MMM-Spotify" ],
                      			[ "MMM-Globe" , "MMM-Spotify" ],
                      			[ "MMM-PublicTransportHafas" , "MMM-Spotify" ],
                      			[ "MMM-Worldclock" , "MMM-Spotify" ]],
                      			
                      				fixed: [ "clock" , "MMM-OpenmapWeather" , "weatherforecast" , "MMM-PublicTransportHafas" , "newsfeed" , "calendar" , "MMM-Fuel", "MMM-Tankerkoenig" , "MMM-ioBroker" ],
                          				rotationTime: 60000,
                      			animationTime: 0,
                      			}
                      		},
                      

                      but what is there wromg?

                      mumblebajM 1 Reply Last reply Reply Quote 0
                      • mumblebajM Offline
                        mumblebaj Module Developer @kusselin
                        last edited by

                        @kusselin Have you tried running the module without the extra config? animationTime has default value of 0, disabled you probably don’t need to set and the rotationTime you probably don’t need to set for now.

                        Check out my modules at: https://github.com/mumblebaj?tab=repositories
                        Check my blog-post: https://mumblebaj.xyz/
                        Check my MM Container: https://hub.docker.com/repository/docker/mumblebaj/magicmirror/general

                        1 Reply Last reply Reply Quote 0
                        • kusselinK Offline
                          kusselin
                          last edited by

                          @mumblebaj said in Not all Modules are displaying on the tv:

                          Have you tried running the module without the extra config? animationTime has default value of 0, disabled you probably don’t need to set and the rotationTime you probably don’t need to set for now.

                          If I take out rotation time and duration time nothing happens either :-( traffic is not displayed although it is fixed … I don’t know what to do now … it’s strange …

                          've actually already stuck that with pages … fixed modules are always there and the others are then faded in!

                          mumblebajM 1 Reply Last reply Reply Quote 0
                          • mumblebajM Offline
                            mumblebaj Module Developer @kusselin
                            last edited by

                            @kusselin You are rotating the pages every 60 seconds? Correct? From what I understand, ever time the pages rotate a call is done to get data which would be true in the case of mmm-traffic. It could be that by the time the module get it’s data that the rotation has happened and then it does not display? I may be wrong. I don’t use the module myself.

                            Check out my modules at: https://github.com/mumblebaj?tab=repositories
                            Check my blog-post: https://mumblebaj.xyz/
                            Check my MM Container: https://hub.docker.com/repository/docker/mumblebaj/magicmirror/general

                            1 Reply Last reply Reply Quote 0
                            • kusselinK Offline
                              kusselin
                              last edited by

                              I have now taken the code for my MMM-pages out of the config.js - strange then everything works! then traffic is displayed … so it is due to the MMM-pages module …

                              Question: Can the mmm-pages code be at the very end of the config.js or does it have to be at the beginning?

                              Question 2: the mmm-pages code from me is correct, right?

                              I have already set the time to 120,000, there too no traffic and current weather is displayed! :-( I’m with my Latain at the end :-(

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

                                @kusselin said in Not all Modules are displaying on the tv:

                                I have already set the time to 120,000

                                what is the time value increment, seconds or milliseconds? if milliseconds, that 120,000 is just 2 minutes

                                Sam

                                How to add modules

                                learning how to use browser developers window for css changes

                                mumblebajM 1 Reply Last reply Reply Quote 0
                                • kusselinK Offline
                                  kusselin
                                  last edited by

                                  exactly … milliseconds and two minutes should be long for a switch …

                                  as I said, even if I take out the duration time it doesn’t work with traffic and the weather module :-(

                                  I take the complete mmm-pages code out of the config, then everything works!

                                  1 Reply Last reply Reply Quote 0
                                  • mumblebajM Offline
                                    mumblebaj Module Developer @sdetweil
                                    last edited by

                                    @sdetweil I have had a look and I see the following:

                                    Will not show MMM-Traffic. LockStrings active: module_7_MMM-pages
                                    

                                    I assume this is why the MMM-Traffic is not showing when used in MMM-Pages? I have added the modules on my test machine and I can’t get the module to show either. I see that the above error comes from the main.js of MM. maybe you can shed more light on the issue for @kusselin

                                    Check out my modules at: https://github.com/mumblebaj?tab=repositories
                                    Check my blog-post: https://mumblebaj.xyz/
                                    Check my MM Container: https://hub.docker.com/repository/docker/mumblebaj/magicmirror/general

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

                                      @mumblebaj that is not an error. Just info.

                                      The module will ONLY be shown on its page, or if set to fixed.

                                      All the message says is pages hid it, and no-one else can show it

                                      Sam

                                      How to add modules

                                      learning how to use browser developers window for css changes

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

                                        Looks like this module manipulates the hidden status directly, instead of calling the hide/show api…

                                        Sam

                                        How to add modules

                                        learning how to use browser developers window for css changes

                                        mumblebajM 1 Reply Last reply Reply Quote 0
                                        • mumblebajM Offline
                                          mumblebaj Module Developer @sdetweil
                                          last edited by

                                          @sdetweil Yeah, doesn’t seem to play well with pages. The minute you remove paged the module works fine.

                                          Check out my modules at: https://github.com/mumblebaj?tab=repositories
                                          Check my blog-post: https://mumblebaj.xyz/
                                          Check my MM Container: https://hub.docker.com/repository/docker/mumblebaj/magicmirror/general

                                          1 Reply Last reply Reply Quote 0
                                          • kusselinK Offline
                                            kusselin
                                            last edited by

                                            @mumblebaj said in Not all Modules are displaying on the tv:

                                            Yeah, doesn’t seem to play well with pages. The minute you remove paged the module works fine.

                                            Yep, that’s how I see it … the MMM traffic module cannot be used in combination with the MMM pages module !!

                                            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