• 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-Hoymiles-Wifi

Scheduled Pinned Locked Moved Development
25 Posts 5 Posters 3.5k Views 4 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.
  • E Offline
    evroom @evroom
    last edited by Nov 10, 2024, 2:27 PM

    Just FYI.

    I am currently busy making some changes to the module.
    As there is no sunshine due to the current weather conditions, it is a bit difficult to have real measurements.
    Trying to add a test using a JSON dataset.
    Hope to be able to present it a.s.a.p.

    E.J.

    MagicMirror version: 2.30.0
    Raspberry Pi 4 Model B Rev 1.5 (8 GB RAM)
    Raspbian GNU/Linux 12 (bookworm)

    Test environment:
    MagicMirror version: v2.30.0
    Raspberry Pi 3 Model B Plus Rev 1.3 (1 GB RAM)
    Raspbian GNU/Linux 12 (bookworm)

    1 Reply Last reply Reply Quote 0
    • S Offline
      sdetweil @evroom
      last edited by Nov 10, 2024, 2:28 PM

      @evroom said in MMM-Hoymiles-Wifi:

      ~/MagicMirror/modules/MMM-Hoymiles-Wifi/hoymiles_data.py
      Change this line to the address of your DTU:
      dtu = DTU(“192.168.178.114”)

      sounds like a new config parm so you don’t have to edit the file
      (pass as a parameter on /hoymiles_data.py start)

      Sam

      How to add modules

      learning how to use browser developers window for css changes

      E 1 Reply Last reply Nov 10, 2024, 2:38 PM Reply Quote 0
      • E Offline
        evroom @sdetweil
        last edited by evroom Nov 10, 2024, 2:43 PM Nov 10, 2024, 2:38 PM

        @sdetweil said in MMM-Hoymiles-Wifi:

        sounds like a new config parm so you don’t have to edit the file
        (pass as a parameter on /hoymiles_data.py start)

        Exactly!

        I did change hoymiles_data.py to be able to refrain from hard-coding it:
        python hoymiles_data.py --dtu_ip_address 192.168.178.114--debug
        The next thing would be to pass the parameter(s) from the configuration (to be coded in the MMM-Hoymiles-Wifi.js file).

        As I never made a module myself, I would need to find out how.

        Any suggestions are much appreciated!

        E.J.

        MagicMirror version: 2.30.0
        Raspberry Pi 4 Model B Rev 1.5 (8 GB RAM)
        Raspbian GNU/Linux 12 (bookworm)

        Test environment:
        MagicMirror version: v2.30.0
        Raspberry Pi 3 Model B Plus Rev 1.3 (1 GB RAM)
        Raspbian GNU/Linux 12 (bookworm)

        S 1 Reply Last reply Nov 10, 2024, 2:52 PM Reply Quote 0
        • S Offline
          sdetweil @evroom
          last edited by sdetweil Nov 10, 2024, 2:57 PM Nov 10, 2024, 2:52 PM

          @evroom put it in the modulename.js defaults section
          i bet the config is already passed to the node helper which execs the python script.
          yep

            this.sendSocketNotification("INIT", this.config)
          

          then the user adds the property to the config.js module entry, as they are editing it anyhow

          Sam

          How to add modules

          learning how to use browser developers window for css changes

          E 1 Reply Last reply Nov 10, 2024, 3:35 PM Reply Quote 0
          • E Offline
            evroom @SuVo
            last edited by Nov 10, 2024, 3:23 PM

            @SuVo

            Hi, question,

            do you live somewhere sunny ?

            Could you try the run this and share the output ?

            hoymiles-wifi --host 192.168.178.114 get-real-data-new

            You’ll need to change the IP to the IP of your DTU.

            E.J.

            MagicMirror version: 2.30.0
            Raspberry Pi 4 Model B Rev 1.5 (8 GB RAM)
            Raspbian GNU/Linux 12 (bookworm)

            Test environment:
            MagicMirror version: v2.30.0
            Raspberry Pi 3 Model B Plus Rev 1.3 (1 GB RAM)
            Raspbian GNU/Linux 12 (bookworm)

            1 Reply Last reply Reply Quote 0
            • E Offline
              evroom @sdetweil
              last edited by Nov 10, 2024, 3:35 PM

              @sdetweil said in MMM-Hoymiles-Wifi:

              i bet the config is already passed to the node helper which execs the python script.

              Actually the python script is being executed via a shell script (in order to make it running using pm2).
              I do not see anything in the node_helper.js file.

              This is mainly due to the fact that the developer of the module used MMM-HTMLSnippet as basis and concentrated more on the data that he wanted to display.

              The challenge is now to have everything running inside the module, without this ‘external’ stuff.
              As all modules tend to do.

              MagicMirror version: 2.30.0
              Raspberry Pi 4 Model B Rev 1.5 (8 GB RAM)
              Raspbian GNU/Linux 12 (bookworm)

              Test environment:
              MagicMirror version: v2.30.0
              Raspberry Pi 3 Model B Plus Rev 1.3 (1 GB RAM)
              Raspbian GNU/Linux 12 (bookworm)

              S S 2 Replies Last reply Nov 10, 2024, 4:49 PM Reply Quote 1
              • S Offline
                sdetweil @evroom
                last edited by sdetweil Nov 10, 2024, 5:09 PM Nov 10, 2024, 4:49 PM

                @evroom see my pythonPrint module for how to execute a python script

                https://github.com/sdetweil/MMM-PythonPrint
                you can also exec a shell script too

                and launch pm2 to start/stop that shell script

                Sam

                How to add modules

                learning how to use browser developers window for css changes

                1 Reply Last reply Reply Quote 1
                • S Offline
                  schris88 @evroom
                  last edited by Nov 11, 2024, 10:11 AM

                  @evroom said in MMM-Hoymiles-Wifi:

                  @sdetweil said in MMM-Hoymiles-Wifi:

                  i bet the config is already passed to the node helper which execs the python script.

                  Actually the python script is being executed via a shell script (in order to make it running using pm2).
                  I do not see anything in the node_helper.js file.

                  This is mainly due to the fact that the developer of the module used MMM-HTMLSnippet as basis and concentrated more on the data that he wanted to display.

                  The challenge is now to have everything running inside the module, without this ‘external’ stuff.
                  As all modules tend to do.

                  This is true, it´s a hacked proof of concept, nothing to be proud of at the moment :D

                  Not sure how much time I have for it till end of year, I can grant write access to anyone who´s willing to help.

                  E 1 Reply Last reply Nov 11, 2024, 1:48 PM Reply Quote 0
                  • E Offline
                    evroom @schris88
                    last edited by evroom Nov 11, 2024, 1:49 PM Nov 11, 2024, 1:48 PM

                    @schris88 said in MMM-Hoymiles-Wifi:

                    This is true, it´s a hacked proof of concept, nothing to be proud of at the moment :D

                    Not sure how much time I have for it till end of year, I can grant write access to anyone who´s willing to help.

                    Not to worry. You sparked an idea.

                    I have some modifications ready (I forked it), but fighting with github to get it synced (github wants to delete all my modifications when I try).
                    Perhaps granting me access (evroom) wil make it easier.
                    Although it is not really the way to use github, I guess.

                    E.J.

                    MagicMirror version: 2.30.0
                    Raspberry Pi 4 Model B Rev 1.5 (8 GB RAM)
                    Raspbian GNU/Linux 12 (bookworm)

                    Test environment:
                    MagicMirror version: v2.30.0
                    Raspberry Pi 3 Model B Plus Rev 1.3 (1 GB RAM)
                    Raspbian GNU/Linux 12 (bookworm)

                    S 1 Reply Last reply Nov 11, 2024, 1:53 PM Reply Quote 0
                    • S Offline
                      sdetweil @evroom
                      last edited by sdetweil Nov 11, 2024, 2:18 PM Nov 11, 2024, 1:53 PM

                      @evroom

                      you fork
                      clone fork //git clone
                      make new branch // git checkout -b nane
                      make code changes
                      // this part multiple times
                      add to files to commit // git add filename
                      git commit
                      git push // to add to github fork
                      //

                      on github go to original repo source
                      create pull request // for origin to pull changes from your fork

                      if subsequent push to same branch, PR will be updated automatically

                      Sam

                      How to add modules

                      learning how to use browser developers window for css changes

                      E 1 Reply Last reply Nov 11, 2024, 2:59 PM Reply Quote 0
                      • 1
                      • 2
                      • 3
                      • 2 / 3
                      2 / 3
                      • First post
                        12/25
                        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