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

    Posts

    Recent Best Controversial
    • RE: MMM-WunderGround Temperature stop working

      Yes, you’re right. My “old” station disappears. I’ll take a new one and it works.

      Thanks

      posted in Troubleshooting
      M
      MyMirror
    • RE: MMM-WunderGround Temperature stop working

      Where do you change/renew your station?
      Can you provide the link?
      Thanks

      posted in Troubleshooting
      M
      MyMirror
    • RE: MMM-WunderGround Temperature stop working

      @trividar
      Click on “Learn more” and ask for a price :-(

      posted in Troubleshooting
      M
      MyMirror
    • RE: MMM-WunderGround Temperature stop working

      See here:
      https://www.wunderground.com/weather/api/
      They wrote:
      “To improve our services and enhance our relationship with our users, we will no longer provide free weather API keys as part of our program.”

      posted in Troubleshooting
      M
      MyMirror
    • RE: Trouble with python script for ultrasonic mudule HC-SR04

      @idoodler Thanks for your Reply.
      There is no clicking noise … as i haven’t got any sound device connected.
      But you’re right … the 100 seems to be the problem.
      I didn’t “saw” it … damn.
      I’ll correct this and test it again.

      Thanks

      posted in Troubleshooting
      M
      MyMirror
    • Trouble with python script for ultrasonic mudule HC-SR04

      Hi,

      i’ve got some problems with my script (don’t know, where i found it).
      In principle, it works, but after 1 or 2 days, the monitor switches no longer on or off.
      This means that the script is in an undefined state.
      With the logging I wanted to see where it hangs, but that does not really work either.
      Who can help me and optimize the script?

      Thank you

      #Bibliotheken einbinden / Import libs
      from subprocess import call
      import RPi.GPIO as GPIO
      import time
      import logging
      
      #Einstellungen für das Logging / settings for log options
      logging.basicConfig(level=logging.INFO,
                          format='%(message)s',
                          datefmt='%m-%d %H:%M',
                          filename='PIR.log',
                          filemode='w')
      
      # define a Handler which writes INFO messages or higher to the sys.stderr
      console = logging.StreamHandler()
      console.setLevel(logging.INFO)
      
      # set a format which is simpler for console use
      formatter = logging.Formatter('%(name)-12s: %(levelname)-8s %(message)s')
      
      # tell the handler to use this format
      console.setFormatter(formatter)
      
      # add the handler to the root logger
      logging.getLogger('').addHandler(console)
      
      #GPIO Modus (BOARD / BCM)
      GPIO.setmode(GPIO.BCM)
       
      #GPIO Pins zuweisen / set GPIO pins
      GPIO_TRIGGER = 23
      GPIO_ECHO = 24
      Monitor_State = 0
      Counter = 0
      TVSERVICE = '/opt/vc/bin/tvservice'
      
      #Richtung der GPIO-Pins festlegen (IN / OUT) / direction for Pins (in/out)
      GPIO.setup(GPIO_TRIGGER, GPIO.OUT)
      GPIO.setup(GPIO_ECHO, GPIO.IN)
      
      Text = (time.strftime("%d.%m.%Y %H:%M:%S")) + (" Messung vom User gestartet")
      logging.info('Gestartet')
      logging.info(Text)
      logging.info('ENDE')
      
      # Bildschirm erst einmal ausschalten :-) / switch off monitor first :-)
      call([TVSERVICE, '-o'])
       
      def distanz():
          # setze Trigger auf HIGH / set trigger to HIGH
          GPIO.output(GPIO_TRIGGER, True)
       
          # setze Trigger nach 0.01ms aus LOW / set trigger after 0.01ms low
          time.sleep(0.00001)
          GPIO.output(GPIO_TRIGGER, False)
       
          StartZeit = time.time()
          StopZeit = time.time()
       
          # speichere Startzeit / remember starttime
          while GPIO.input(GPIO_ECHO) == 0:
              StartZeit = time.time()
       
          # speichere Ankunftszeit / remember 2'nd time
          while GPIO.input(GPIO_ECHO) == 1:
              StopZeit = time.time()
       
          # Zeit Differenz zwischen Start und Ankunft / calc difference
          TimeElapsed = StopZeit - StartZeit
          # mit der Schallgeschwindigkeit (34300 cm/s) multiplizieren
          # und durch 2 teilen, da hin und zurueck
          distanz = (TimeElapsed * 34300) / 2
       
          return distanz
       
      if __name__ == '__main__':
          try:
              while True:
                  abstand = distanz()
      
                  if abstand < 120 and Monitor_State == 0:
                    logging.info('Monitor gestartet')
                    Monitor_State=1
                    Counter = 0
                    call([TVSERVICE, '-p'])
                    
                  elif abstand < 120 and Monitor_State == 1:
                    Ausgabe = " Counter reset " + (" - %.1f cm" % abstand)
                    logging.info(Ausgabe)
                    Counter = 0
                    
                  elif abstand >= 120 and Monitor_State == 1 and Counter = 100 and Counter >= 11:
                    Monitor_State=0
                    Counter = 0
                    call([TVSERVICE, '-o'])
                  
                  time.sleep(1)
       
              # Beim Abbruch durch STRG+C resetten / reset after STRG+C
          except KeyboardInterrupt:
              GPIO.cleanup()
      
      
      posted in Troubleshooting
      M
      MyMirror
    • RE: Trouble with Wunderlist and/or Todoist - who can help?

      Hi pyrosmiley,
      thank you for the more detailed information. I’ll check that in the coming days. At the moment I’m busy with other things (including children’s birthday …).
      I get in touch with the results.

      posted in Troubleshooting
      M
      MyMirror
    • RE: Trouble with Wunderlist and/or Todoist - who can help?

      Hi pyrosmiley,
      i’ve removed every bracket and space … no content from the wunderlist :-(
      I think, i’ll Forget this for a while and start really new from bottom up (just with the wunderlist).
      The todoist is ok.
      If i share my account with my wife and my kids, and they will have access to todoist … they will give me thousend of tasks i have to for them :-) :-) … no, this can’t be the right way .So i have to think about, how to separate that.
      The main problem here is, to use seperate accounts with one app on my mobile.
      Thanks a lot for your help and ideas - if you find a way … pls share it :-).

      @potts-mike: Thanks for your tip

      Greets

      posted in Troubleshooting
      M
      MyMirror
    • RE: Trouble with Wunderlist and/or Todoist - who can help?

      @MyMirror
      Your example was very helpful - but the projektColors are without any effect.

      posted in Troubleshooting
      M
      MyMirror
    • 1 / 1