Low battery alarm doesn`t work... Module not found...

38 views
Skip to first unread message

felix.m...@gmail.com

unread,
Sep 25, 2020, 11:48:55 AM9/25/20
to weewx-user

hello

I have some trouble with the lowBattery script.
I have copied the hole file "lowBattery.py" to my user directory...(/home/pi/ ???????)
Is that right?
Than I have edit " user.lowBattery.BatteryAlarm" to  report_services in weewx.conf.

If I run  "sudo tail -f /var/log/syslog" it shows:

Sep 25 17:40:32 wetterstation weewx[4871] CRITICAL __main__: Caught unrecoverable exception:
Sep 25 17:40:32 wetterstation weewx[4871] CRITICAL __main__:     ****  No module named 'user.lowBattery'
Sep 25 17:40:32 wetterstation weewx[4871] CRITICAL __main__:     ****  Traceback (most recent call last):
Sep 25 17:40:32 wetterstation weewx[4871] CRITICAL __main__:     ****    File "/usr/share/weewx/weewxd", line 148, in main
Sep 25 17:40:32 wetterstation weewx[4871] CRITICAL __main__:     ****      engine = weewx.engine.StdEngine(config_dict)
Sep 25 17:40:32 wetterstation weewx[4871] CRITICAL __main__:     ****    File "/usr/share/weewx/weewx/engine.py", line 75, in __init__
Sep 25 17:40:32 wetterstation weewx[4871] CRITICAL __main__:     ****      self.loadServices(config_dict)
Sep 25 17:40:32 wetterstation weewx[4871] CRITICAL __main__:     ****    File "/usr/share/weewx/weewx/engine.py", line 138, in loadServices
Sep 25 17:40:32 wetterstation weewx[4871] CRITICAL __main__:     ****      obj = weeutil.weeutil.get_object(svc)(self,config_dict)
Sep 25 17:40:32 wetterstation weewx[4871] CRITICAL __main__:     ****    File "/usr/share/weewx/weeutil/weeutil.py", line 1093, in get_object
Sep 25 17:40:32 wetterstation weewx[4871] CRITICAL __main__:     ****      mod = __import__(module)
Sep 25 17:40:32 wetterstation weewx[4871] CRITICAL __main__:     ****  ModuleNotFoundError: No module named 'user.lowBattery'
Sep 25 17:40:32 wetterstation weewx[4871] CRITICAL __main__:     ****  Exiting.

Sorry, I`m a little noob, but maybe somebody can help me. Thx

Tom Keffer

unread,
Sep 25, 2020, 12:05:16 PM9/25/20
to weewx-user
It looks like you did a package install, so your user directory is /usr/share/weewx/user

--
You received this message because you are subscribed to the Google Groups "weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email to weewx-user+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/4cba3e35-63dd-4730-943d-f1b6f8a58774n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages