Wlink doesn't run

204 views
Skip to first unread message

Justin Wenk

unread,
May 15, 2024, 6:35:53 AM5/15/24
to weewx-user
Hi everyone! I have the following problem: I want to use the “Wlink” extension (https://github.com/weewx/weewx/wiki/wlink). I followed the instructions but I always get an error. I use WeeWX on macOS (Sonoma 14.13.1).

Log:

2024-05-15 12:01:32 weewxd[2676]: INFO weewxd: Initializing weewxd version 5.0.2
2024-05-15 12:01:32 weewxd[2676]: INFO weewxd: Command line: /Users/justin/weewx-venv/bin/weewxd
2024-05-15 12:01:32 weewxd[2676]: INFO weewxd: Using Python 3.12.3 (v3.12.3:f6650f9ad7, Apr  9 2024, 08:18:47) [Clang 13.0.0 (clang-1300.0.29.30)]
2024-05-15 12:01:32 weewxd[2676]: INFO weewxd: Located at /Users/justin/weewx-venv/bin/python3
2024-05-15 12:01:33 weewxd[2676]: INFO weewxd: Platform macOS-14.3.1-arm64-arm-64bit
2024-05-15 12:01:33 weewxd[2676]: INFO weewxd: Locale: 'de_DE.UTF-8'
2024-05-15 12:01:33 weewxd[2676]: INFO weewxd: Entry path: /Users/justin/weewx-venv/lib/python3.12/site-packages/weewxd.py
2024-05-15 12:01:33 weewxd[2676]: INFO weewxd: WEEWX_ROOT: /Users/justin/weewx-data
2024-05-15 12:01:33 weewxd[2676]: INFO weewxd: Configuration file: /Users/justin/weewx-data/weewx.conf
2024-05-15 12:01:33 weewxd[2676]: INFO weewxd: User module: /Users/justin/weewx-data/bin/user
2024-05-15 12:01:33 weewxd[2676]: INFO weewxd: Debug: 1
2024-05-15 12:01:33 weewxd[2676]: DEBUG weewxd: Initializing engine
2024-05-15 12:01:33 weewxd[2676]: INFO weewx.engine: Loading station type WeatherLink (user.wlink)
2024-05-15 12:01:33 weewxd[2676]: CRITICAL weewxd: Caught unrecoverable exception:
2024-05-15 12:01:33 weewxd[2676]: CRITICAL weewxd:     ****  multiple exception types must be parenthesized (wlink.py, line 180)
2024-05-15 12:01:33 weewxd[2676]: CRITICAL weewxd:     ****  Traceback (most recent call last):

2024-05-15 12:01:33 weewxd[2676]: CRITICAL weewxd:     ****    File "/Users/justin/weewx-venv/lib/python3.12/site-packages/weewxd.py", line 160, in main

2024-05-15 12:01:33 weewxd[2676]: CRITICAL weewxd:     ****      engine = weewx.engine.StdEngine(config_dict)

2024-05-15 12:01:33 weewxd[2676]: CRITICAL weewxd:     ****               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

2024-05-15 12:01:33 weewxd[2676]: CRITICAL weewxd:     ****    File "/Users/justin/weewx-venv/lib/python3.12/site-packages/weewx/engine.py", line 77, in __init__

2024-05-15 12:01:33 weewxd[2676]: CRITICAL weewxd:     ****      self.setupStation(config_dict)

2024-05-15 12:01:33 weewxd[2676]: CRITICAL weewxd:     ****    File "/Users/justin/weewx-venv/lib/python3.12/site-packages/weewx/engine.py", line 104, in setupStation

2024-05-15 12:01:33 weewxd[2676]: CRITICAL weewxd:     ****      __import__(driver)

2024-05-15 12:01:33 weewxd[2676]: CRITICAL weewxd:     ****    File "/Users/justin/weewx-data/bin/user/wlink.py", line 180

2024-05-15 12:01:33 weewxd[2676]: CRITICAL weewxd:     ****      except (urllib2.URLError, socket.error,

2024-05-15 12:01:33 weewxd[2676]: CRITICAL weewxd:     ****             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

2024-05-15 12:01:33 weewxd[2676]: CRITICAL weewxd:     ****  SyntaxError: multiple exception types must be parenthesized

2024-05-15 12:01:33 weewxd[2676]: CRITICAL weewxd:     ****  Exiting.






------------------------------------------------------------------------------------------------------------------------------------
Wlink.py is located in the /weewx-data/bin/user folder.

A part from the weewx.conf:

##############################################################################

#   This section is for information about the station.

[Station]
   
    # Description of the station location, such as your town.
    location = HalleWetter
   
    # Latitude in decimal degrees. Negative for southern hemisphere.
    latitude = 51.52
    # Longitude in decimal degrees. Negative for western hemisphere.
    longitude = 11.85
   
    # Altitude of the station, with the unit it is in. This is used only
    # if the hardware cannot supply a value.
    altitude = 94, meter    # Choose 'foot' or 'meter' for unit
   
    # Set to type of station hardware. There must be a corresponding stanza
    # in this file, which includes a value for the 'driver' option.
    station_type = WeatherLink
   
    # If you have a website, you may specify an URL. The URL is required if you
    # intend to register your station. The URL must include the scheme, for
    # example, "http://" or "https://"
    #station_url = https://www.example.com
   
    # The start of the rain year (1=January; 10=October, etc.). This is
    # downloaded from the station if the hardware supports it.
    rain_year_start = 1
   
    # Start of week (0=Monday, 6=Sunday)
    week_start = 6

##############################################################################

[WeatherLink]
        username = ------------ # use the device ID for weatherlink 2.0 accounts
        password = ---------------
        driver = user.wlink

###############################################################################



I hope you can help me and the information is enough. .

Best regards,
Justin

Tom Keffer

unread,
May 15, 2024, 6:32:36 PM5/15/24
to weewx...@googlegroups.com
It looks like the wlink extension was never ported to Python 3.

--
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/97d75b62-06a6-4fda-8480-916a0b063520n%40googlegroups.com.

John Kline

unread,
May 15, 2024, 7:25:06 PM5/15/24
to weewx...@googlegroups.com
It looks like there is a 3 year old PR that Matthew never merged to port it to Python 3.

Justin, you might try:
Note: I have not tried it myself.

On May 15, 2024, at 3:32 PM, Tom Keffer <tke...@gmail.com> wrote:



Karen K

unread,
May 16, 2024, 1:10:37 AM5/16/24
to weewx-user
If the PC running WeeWX and the Weatherlink device is on the same network, you could try to retrieve data directly from the device instead of fetching it from weatherlink.com. You may want to try the WeatherLinkLiveUDP driver for this. Or if you have a paid account with weatherlink.com you could try WLLDriver.
Message has been deleted

Justin Wenk

unread,
May 16, 2024, 7:03:19 AM5/16/24
to weewx-user
Thank you for the answers! Of course that makes sense.

@Karen: Unfortunately the computer and console are not on the same network.
@John: I tried the extension. The error is gone. Apparently there is another problem. The weather data are not retrieved.

LOG:

2024-05-16 12:36:00 weewxd[4012]: INFO weewx.manager: Starting backfill of daily summaries
2024-05-16 12:36:00 weewxd[4012]: INFO weewx.manager: Empty database
2024-05-16 12:36:00 weewxd[4012]: ERROR user.wlink: server returned "Invalid Request!" for StationStatus api (incorrect password/apitoken?)
2024-05-16 12:36:00 weewxd[4012]: INFO weewx.engine: Starting main packet loop.
2024-05-16 12:36:01 weewxd[4012]: ERROR user.wlink: server returned "Invalid Request!" for StationStatus api (incorrect password/apitoken?)
2024-05-16 12:37:01 weewxd[4012]: ERROR user.wlink: server returned "Invalid Request!" for StationStatus api (incorrect password/apitoken?)
2024-05-16 12:38:02 weewxd[4012]: ERROR user.wlink: server returned "Invalid Request!" for StationStatus api (incorrect password/apitoken?)
2024-05-16 12:39:02 weewxd[4012]: ERROR user.wlink: server returned "Invalid Request!" for StationStatus api (incorrect password/apitoken?)
2024-05-16 12:40:03 weewxd[4012]: ERROR user.wlink: server returned "Invalid Request!" for StationStatus api (incorrect password/apitoken?)






weewx.conf

    driver = user.wlink
    username = 12345678910D    # use the device ID for weatherlink 2.0 accounts
    password = Test
    apitoken = 1234567891011121314151617181920


###############################################################################





My entered data:

1. The PW from my weatherlink.com account. 2. The device ID from the station. 3. API token (API V1)

Screenshot 2024-05-16 at 12-49-04 WeatherLink Home.jpg
Screenshot 2024-05-16 at 12-48-24 Device Configuration.jpg
Screenshot 2024-05-16 at 12-47-57 My Account.jpg
Message has been deleted

Justin Wenk

unread,
May 16, 2024, 8:06:42 AM5/16/24
to weewx-user
I think the error lies in the Davis API V1. When I go to https://api.weatherlink.com/v1/NoaaExt.xml?user=001D0A00DE6A&pass=DEMO&apiToken=demo0a002bc5272033001d0a002bc527 and enter my information, "Server error! #13" appears. When I input the Davis API demo data inside weewx.conf, I can receive demo weather data...

Justin Wenk

unread,
May 18, 2024, 3:25:35 PM5/18/24
to weewx-user
Hello everyone,
short update: I have now finally installed this extension https://github.com/WernerKr/davisconsoleapi. Now runs stable via the weatherlink.com API V2. API V1 is not supported by the Davis console 6313 - that's why it didn't work with the other extension.

Best regards,
Justin

Karen K

unread,
May 19, 2024, 2:58:27 AM5/19/24
to weewx-user
Justin Wenk schrieb am Samstag, 18. Mai 2024 um 21:25:35 UTC+2:
short update: I have now finally installed this extension https://github.com/WernerKr/davisconsoleapi. Now runs stable via the weatherlink.com API V2. API V1 is not supported by the Davis console 6313 - that's why it didn't work with the other extension.

Thank you for this update. I added Werner Krenn's driver to the german summary of WeeWX.

Reply all
Reply to author
Forward
0 new messages