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-futar - how to add modules multiple time?

    Scheduled Pinned Locked Moved Solved Troubleshooting
    24 Posts 3 Posters 5.0k Views 3 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 @0livia
      last edited by

      @0livia git clone module new_foldername

      in new_foldername

      rename all.old things to the new_foldername

      edit the new_foldername.js

      change the register() to use the new_foldername

      and use new_foldername as the module name in config.js

      Sam

      How to add modules

      learning how to use browser developers window for css changes

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

        @sdetweil ok thank you for pinging me to my issue. To double check that I got it right - what you are saying is basicly I have to copy (i dont use git) the moudule again in a different name for example mmm-futar1 and in that folder need to rename all the the mmm-futar to mmm-futar1, and in config js need to the the same thing. Is this correct?
        I’m on my way to Aalsmeer (NL) as I’m a trucker :) I 'll be back on wednesday so give it a try next week. I ll give you feedack how it goes.

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

          @0livia yes correct. you can git clone

          just add the new output foldername to the end of the command

          and inside the one file have to change it too

          Sam

          How to add modules

          learning how to use browser developers window for css changes

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

            @sdetweil Hi I have contacted the DevGuy and he said no need to clone the modules multiple times, I tried and do not work that way.

            The solution what he told is not working for me either.
            Here is what he said - you need to add the modules into the config.js file like this way.

            {
            module: “MMM-Futar”,
            position: “top_left”,
            header: ‘Közvágóhíd -> Ráckeve’,
            config: {
            stopId: ‘BKK_009628’, // Közvágóhíd
            routeId: 'BKK_H6,
            }
            },
            {
            module: “MMM-Futar”,
            position: “top_left”,
            header: ‘Ráckeve -> Közvágóhíd’,
            config: {
            stopId: ‘BKK_007947’, // Ráckeve
            routeId: ‘BKK_H6’,
            }
            },
            ]
            };

            I tried this way and it gives me a blank screen
            here is my config

            https://pastebin.com/bwrTtisP

            Anyone has any idea about this issue of mine?

            thgmirrorT S 2 Replies Last reply Reply Quote 1
            • thgmirrorT Offline
              thgmirror @0livia
              last edited by thgmirror

              Hi @0livia, I had some trouble when I tried to locate modules at the same region…so I would use first to set one occurrence to top_left and the second to top_right.

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

                @0livia black screen is because of a missing library

                see https://forum.magicmirror.builders/topic/15778/fix-for-black-screen-in-2-16-and-later/1

                Sam

                How to add modules

                learning how to use browser developers window for css changes

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

                  @sdetweil I started my mirror with the config a linked earlier.
                  This is my error in the terminal

                  [09.12.2022 15:57.24.612] [LOG] Initializing new module helper …
                  [09.12.2022 15:57.24.612] [LOG] Module helper loaded: MMM-Futar
                  [09.12.2022 15:57.24.625] [ERROR] WARNING! Could not load config file. Starting with default configuration. Error found: TypeError: Cannot read properties of undefined (reading ‘split’)

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

                    @0livia can u show a few more lines? the stacktrace is there which will show the line causing the error

                    Sam

                    How to add modules

                    learning how to use browser developers window for css changes

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

                      @sdetweil in your config posted above, u are missing a trailing quote mark

                            stopId: 'BKK_009628', // Közvágóhíd
                            routeId: 'BKK_H6,   <-----
                      

                      but other than that your config works for me…

                      did you do npm install in the module folder?
                      did u add the request module as I noted before ?

                      Screenshot at 2022-12-09 09-11-03.png

                      Sam

                      How to add modules

                      learning how to use browser developers window for css changes

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

                        @sdetweil said in MMM-futar - how to add modules multiple time?:

                        trailing quote mark

                        I did find the trailing quote mark was missing :)

                        when i first installed the module i did npm install in the module folder.
                        Should I do it again after modifying the config js?

                        I do not have this request module thingy i already done that, the mirror actually works fine evewn with the mmm-futar modul(just only one single item) as I want to add more 2 with the provided example just black screen

                        S 1 Reply Last reply Reply Quote 0
                        • 1
                        • 2
                        • 3
                        • 1 / 3
                        • 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