MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    1. Home
    2. JohnGalt
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.
    J
    Offline
    • Profile
    • Following 0
    • Followers 0
    • Topics 9
    • Posts 144
    • Groups 0

    JohnGalt

    @JohnGalt

    15
    Reputation
    17
    Profile views
    144
    Posts
    0
    Followers
    0
    Following
    Joined
    Last Online

    JohnGalt Unfollow Follow

    Best posts made by JohnGalt

    • RE: AHT20 Humidity + Temperature Sensor

      @rkorell + @sdetweil - Thanks for the support. I think I have fixed this for myself by adapting an existing module (“MMM-Temperature”, // https://github.com/Tom-Hirschberger/MMM-Temperature).

      That module calls scripts for various sensors to capture the data. I was able to adapt an existing script for use with this sensor, so I think I am good for now.

      posted in Requests
      J
      JohnGalt
    • RE: MM won't start after upgrading to 2.29.0

      @sdetweil – I wasn’t sure you [still] wanted me to do that before you had a chance to see the extended pm2 logs outputs. I will do it now and get back to you.

      posted in Troubleshooting
      J
      JohnGalt
    • RE: The typical beginner question

      @UncleRoger – +1 on having a separate Magic Mirror instance for development (“dev instance”)! I have a small virtual machine running Magic Mirror where I can try out changes or new modules without disturbing my main instance. I don’t bother with a monitor, just display it on my desktop.

      posted in Hardware
      J
      JohnGalt
    • RE: AHT20 Humidity + Temperature Sensor

      @rkorell Yes, I can describe how I arrived at a resolution for my particular problem - which was to replace DHTxx sensors with the more accurate AHT20 temperature and humidity sensors.

      Caveat: I do not necessarily recommend this for the average person though, because I did not find Magic Mirror modules that natively support this sensor, and as a result had to make changes outside of the config.js and custom.css files. As usual, this puts me at risk of something breaking when the module is updated.

      The module being used (MMM-Temperature - found at https://github.com/Tom-Hirschberger/MMM-Temperature) utilizes python scripts to capture the data from the sensor. While the module is quite complete, with script support for many sensors, I did create a new script in order to use this particular sensor.

      The sensor is supported by Adafruit (https://learn.adafruit.com/adafruit-aht20/python-circuitpython), with instructions to install various adafruit libraries including adafruit-ahtx0 (sudo pip3 install adafruit-circuitpython-ahtx0).

      Using those libraries, your script needs to include the following instructions:

      import board
      import adafruit_ahtx0
      sensor = adafruit_ahtx0.AHTx0(board.I2C())
      

      One of the existing scripts supports I2C sensors using the Adafruit libraries, so it looked like a good candidate to use as a model. See htu21:

      #!/usr/bin/env python3
      #pip3 install adafruit-circuitpython-htu21d
      import board
      from adafruit_htu21d import HTU21D
      import json
      
      result = {}
      try:
          # Create sensor object, communicating over the board's default I2C bus
          i2c = board.I2C()  # uses board.SCL and board.SDA
          sensor = HTU21D(i2c)
          result["temperature_c"] = sensor.temperature
          result["humidity"] = sensor.relative_humidity
          result["temperature_f"] = (result["temperature_c"]*1.8) + 32
          result["error"] = False
      except:
          result["temperature_c"] = 0.0
          result["humidity"] = 0.0
          result["temperature_f"] = (result["temperature_c"]*1.8) + 32
          result["error"] = True
      
      print(json.dumps(result))
      

      My resulting script is aht20:

      #!/usr/bin/env python3
      # aht20: Modeled on htu21 
      # pip3 install adafruit-circuitpython-htu21d
      # pip3 install adafruit-circuitpython-ahtx0
      import board
      import adafruit_ahtx0
      import json
      
      result = {}
      try:
          # Create sensor object, communicating over the board's default I2C bus
          i2c = board.I2C()  # uses board.SCL and board.SDA
          # sensor = HTU21D(i2c)
          sensor = adafruit_ahtx0.AHTx0(board.I2C())
          result["temperature_c"] = sensor.temperature
          result["humidity"] = sensor.relative_humidity
          result["temperature_f"] = (result["temperature_c"]*1.8) + 32
          result["error"] = False
      except:
          result["temperature_c"] = 0.0
          result["humidity"] = 0.0
          result["temperature_f"] = (result["temperature_c"]*1.8) + 32
          result["error"] = True
      
      print(json.dumps(result))
      

      This module is now displaying the temperature and humidity from the sensor directly connected it it. Now all I have to do is figure out the complicated css and get it to look like the other modules on my Magic Mirror.

      Barring any objections, I will mark this as solved.

      posted in Requests
      J
      JohnGalt
    • RE: MM won't start after upgrading to 2.29.0

      @sdetweil – I was able to search out a fix.

      For the benefit of anyone else running Wayland and wanting or needing to switch back to x11, see: https://linuxconfig.org/how-to-use-x-instead-of-wayland-on-ubuntu-22-04 where you are asked to edit one line in a file, then reboot.

      sudo nano /etc/gdm3/custom.conf
      

      I will mark this as solved now.

      posted in Troubleshooting
      J
      JohnGalt
    • RE: Temperature/humidity on Magic Mirror

      @sdetweil Thanks, Sam. I may take a look at that Ecobee API and/or the charting. The Ecobee is currently not in use in my new house, but this may give me the added incentive to get going on that. Thanks again.

      posted in General Discussion
      J
      JohnGalt
    • RE: Black Screen with some modules + linux-armv Error

      @bkeyport and Sam: thanks for the inputs. I went through my logs and the referenced thread, and now do have DynamicWeather working. Much appreciated!

      posted in Troubleshooting
      J
      JohnGalt
    • RE: AHT20 Humidity + Temperature Sensor

      @rkorell – My pleasure.

      posted in Requests
      J
      JohnGalt
    • RE: one call api open weather

      @KristjanESPERANTO - am I misreading or does MMM-OpenWeatherMapForecast appear on both the first and last list? THANKS for the thorough review!

      posted in General Discussion
      J
      JohnGalt
    • RE: Upgrade errors?

      @sdetweil - Thanks, the log file is on its way to you…

      posted in Troubleshooting
      J
      JohnGalt

    Latest posts made by JohnGalt

    • RE: Request: Flight tracker using PiAware

      @Exndfan – ok, thanks.

      posted in Requests
      J
      JohnGalt
    • RE: Request: Flight tracker using PiAware

      @Exndfan – Interesting!

      Query: The original question was in regards to seeing data collected by a PiAware receiver. It looks like Plane Finder and PiAware both run dump1090, but beyond that I don’t know how they work, or how the data gets passed.

      Will this module also display data received by a PiAware?

      posted in Requests
      J
      JohnGalt
    • RE: Request: Flight tracker using PiAware

      @sdetweil
      AHA - I see. It looks like that module is/was quite involved! I’m not sure I can add much to answer the original question, but i did note that the OP described the data as being/like JSON, but the module difers:

      Bugs and Warnings
      ℹ️ The data provided by the flightradar24-client, is not JSON, even if it resembles it. 
      It is actually an Array of JavaScript objects. 
      For an example of the raw data, look at the demo.json file.
      
      posted in Requests
      J
      JohnGalt
    • RE: Request: Flight tracker using PiAware

      @Exndfan

      Maybe the best way to move this forward is to tell us what module you are referring to when you say something used to work but went dark some time ago.

      If we can see or reference what you are talking about, you have a better chance of getting help.

      posted in Requests
      J
      JohnGalt
    • RE: The typical beginner question

      @UncleRoger – +1 on having a separate Magic Mirror instance for development (“dev instance”)! I have a small virtual machine running Magic Mirror where I can try out changes or new modules without disturbing my main instance. I don’t bother with a monitor, just display it on my desktop.

      posted in Hardware
      J
      JohnGalt
    • RE: MMM-Worldclock

      @BKeyport – Sorry to hear that, but thanks for the module while you maintained it.

      And a big thanks for directing us to another module, and not just leaving it hanging out there!

      posted in Utilities
      J
      JohnGalt
    • RE: MMM-Chores - Manage and keep track of your household Chores

      @PierreGode – OK, thanks. I was just wondering what it is estimating, and what it is supposed to do with the estimates.

      posted in Utilities
      J
      JohnGalt
    • RE: MMM-Worldclock

      @sdetweil – That’s what I thought. Just did that and it’s working now…

      Thanks, as always!

      posted in Utilities
      J
      JohnGalt
    • RE: MMM-Worldclock

      @BKeyport, @ulrichwisser and all: Please let me know if the following questions would be better served under a new topic, but since my issues originated with this older module, and the new module shares the same name I thought it appropriate to post under this topic…

      Issue: the old module is no longer supported by the developer, who suggests using a newer module which uses the same module name. After cloning the new module, the instructions call for doing an ‘npm ci’ command, which fails due to a lack of an existing package-lock,json file.

      Question: Is there something different I should be doing, o si this something the developer needs to fix?

      Old module: https://github.com/BKeyport/MMM-Worldclock
      New module: https://github.com/ulrichwisser/MMM-Worldclock
      Error Message:

      pi@mirror1:~/MagicMirror/modules $ cd MMM-Worldclock
      pi@mirror1:~/MagicMirror/modules/MMM-Worldclock $ npm ci
      npm ERR! code EUSAGE
      npm ERR!
      npm ERR! The `npm ci` command can only install with an existing package-lock.json or
      npm ERR! npm-shrinkwrap.json with lockfileVersion >= 1. Run an install with npm@5 or
      npm ERR! later to generate a package-lock.json file, then try again.
      npm ERR!
      npm ERR! Clean install a project
      npm ERR!
      npm ERR! Usage:
      npm ERR! npm ci
      npm ERR!
      npm ERR! Options:
      npm ERR! [--install-strategy <hoisted|nested|shallow|linked>] [--legacy-bundling]
      npm ERR! [--global-style] [--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]]
      npm ERR! [--strict-peer-deps] [--foreground-scripts] [--ignore-scripts] [--no-audit]
      npm ERR! [--no-bin-links] [--no-fund] [--dry-run]
      npm ERR! [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]]
      npm ERR! [-ws|--workspaces] [--include-workspace-root] [--install-links]
      npm ERR!
      npm ERR! aliases: clean-install, ic, install-clean, isntall-clean
      npm ERR!
      npm ERR! Run "npm help ci" for more info
      
      npm ERR! A complete log of this run can be found in: /home/pi/.npm/_logs/2025-08-05T17_16_59_150Z-debug-0.log
      pi@mirror1:~/MagicMirror/modules/MMM-Worldclock $
      
      posted in Utilities
      J
      JohnGalt
    • RE: MMM-Chores - Manage and keep track of your household Chores

      @PierreGode – What does the ‘Chores per Week Estimate’ do?

      What is it estimating, and what does it do with the estimate?

      posted in Utilities
      J
      JohnGalt