• Recent
  • Tags
  • Unsolved
  • Solved
  • MagicMirror² Repository
  • Documentation
  • 3rd-Party-Modules
  • Donate
  • Discord
  • Register
  • Login
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-euro2024

Scheduled Pinned Locked Moved Sport
23 Posts 7 Posters 3.8k Views 7 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.
  • 0 Offline
    0m4r Module Developer
    last edited by Apr 1, 2024, 1:48 PM

    A few weeks more to go, but the magic mirror module is already here for you: https://github.com/0m4r/MMM-euro2024!

    MMM-euro2024

    https://github.com/0m4r

    K C C 3 Replies Last reply Apr 1, 2024, 5:21 PM Reply Quote 2
    • K Offline
      KristjanESPERANTO Module Developer @0m4r
      last edited by Apr 1, 2024, 5:21 PM

      @0m4r Nice! Thanks! 👏
      Don’t forget to add it to the module list 🙂

      1 Reply Last reply Reply Quote 1
      • C Offline
        chrisfr1976 @0m4r
        last edited by Apr 3, 2024, 5:46 PM

        @0m4r There is a problem with the token. I think, I’m stupid, but:

        You write for the config token: [YOUR_TOKEN]

        So I’ve tried token:[1234567890], With this I get an error in the config.js and the mirror does not start up.
        Then I’ve tried token:1234567890,. Same issue.
        Then I’ve tried token:"1234567890", Then the config.js is okay and electron starts. But in this case I get an error message:
        [ERROR] MMM-euro2024 fetchTeams 2018 {"message":"Your API token is invalid.","errorCode":400}

        …of course I received a real API-key from Daniel. Copy+paste, so the key real in my config is okay.

        How should I enter the API-Key? :thinking_face:

        Regards, Chris.

        S 0 2 Replies Last reply Apr 3, 2024, 7:47 PM Reply Quote 1
        • S Offline
          sdetweil @chrisfr1976
          last edited by Apr 3, 2024, 7:47 PM

          @chrisfr1976 what is the module property for the api key? that is what ‘token’ means.

          and typically [apikey]
          means replace all that with the quoted string of the apikey

          Sam

          How to add modules

          learning how to use browser developers window for css changes

          1 Reply Last reply Reply Quote 0
          • 0 Offline
            0m4r Module Developer @chrisfr1976
            last edited by Apr 4, 2024, 7:21 AM

            @chrisfr1976 can you share the config you set up for the module (obviously hiding the token)? Apart from a problem with the token itself, I cannot think of anything wrong with what you describe.

            https://github.com/0m4r

            S 1 Reply Last reply Apr 4, 2024, 10:16 AM Reply Quote 0
            • S Offline
              sdetweil @0m4r
              last edited by sdetweil Apr 4, 2024, 10:31 AM Apr 4, 2024, 10:16 AM

              @0m4r the sample is missing the config:{} section

              {
                disabled: false,
                module: "MMM-euro2024",
                position: "bottom_center",
                defaults: {
                  updateInterval: 60 * 1000, // one minute
                },
                token: [YOUR_TOKEN]
              }
              

              should be

              
              {
                disabled: false,
                module: "MMM-euro2024",
                position: "bottom_center",
                config:{
                     updateInterval: 60 * 1000, // one minute
                     token: [YOUR_TOKEN]
                 }
              }
              

              your module passes this.config to the node_helper, but there is no config block, so only {} gets passed

              this.sendSocketNotification(this.name + 'CONFIG', this.config);
              

              Sam

              How to add modules

              learning how to use browser developers window for css changes

              S 1 Reply Last reply Apr 4, 2024, 10:22 AM Reply Quote 2
              • S Offline
                sdetweil @sdetweil
                last edited by sdetweil Apr 4, 2024, 10:25 AM Apr 4, 2024, 10:22 AM

                @0m4r
                also, the defaults go in the modulename.js not in the node_helper.js

                defaults: {
                    competitionId: 2018, // Euro 2024
                    updateInterval: 60 * 1000, // 1 minute
                  },
                

                this provides overridable properties via config.js

                from the doc
                https://docs.magicmirror.builders/development/core-module-file.html#available-module-instance-properties

                Screenshot_20240404_052415_Chrome.jpg

                Screenshot_20240404_052424_Chrome.jpg

                Sam

                How to add modules

                learning how to use browser developers window for css changes

                0 1 Reply Last reply Apr 5, 2024, 6:34 AM Reply Quote 1
                • 0 Offline
                  0m4r Module Developer @sdetweil
                  last edited by Apr 5, 2024, 6:34 AM

                  @sdetweil thanks for the detailed feedback.
                  I will update it as soon as I get a moment :)

                  https://github.com/0m4r

                  0 1 Reply Last reply Apr 7, 2024, 11:04 AM Reply Quote 1
                  • 0 Offline
                    0m4r Module Developer @0m4r
                    last edited by Apr 7, 2024, 11:04 AM

                    The README.md is updated.
                    The configuration instructions should be now correct: https://github.com/0m4r/MMM-euro2024?tab=readme-ov-file#configuration

                    https://github.com/0m4r

                    S 1 Reply Last reply Apr 7, 2024, 11:41 AM Reply Quote 0
                    • S Offline
                      sdetweil @0m4r
                      last edited by sdetweil Apr 7, 2024, 3:05 PM Apr 7, 2024, 11:41 AM

                      @0m4r i want to nudge you a little more, on the defaults.

                      my MMM-Config module presents a form for config customization, and it does this by discovering the parameters in the defaults section of the modulename.js. as it sits, your module would have no parameters for the user to configure

                      just move that one section to the modulename.js from the node helper and all will be good. no other change to your module is required because you did that change.

                      Sam

                      How to add modules

                      learning how to use browser developers window for css changes

                      0 1 Reply Last reply Apr 7, 2024, 2:17 PM Reply Quote 0
                      • 1
                      • 2
                      • 3
                      • 1 / 3
                      1 / 3
                      • First post
                        1/23
                        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