Failure of GW1000 to connect after SD corruption & re-flash

118 views
Skip to first unread message

Nick

unread,
Jun 13, 2025, 8:32:15 AMJun 13
to weewx-user
Afternoon all,

A bit of help please, as I seem to be banging my head on a brick wall here.

I set up a RPI 3 with Weewx and a waldbeck wifi weather station ages ago
& it worked 100% with Weewx V4... and the GW1000 driver. (the station &
RPI are not local to me, but I am on site for a holiday and I have the job)

However the SD card became corrupt and it had to be re-flashed to latest
version of RPIOS & V5.x for Weewx. (no, no back-up, just don't ask OK).

I have purged Weewx as it had two sets of configs files & directories etc.

This is debian apt style install.

The Wx station appears in the WSview-plus android application, but I
can't get data out of it! It _is_ uploading to wunderground without issue.

Correctly set config options in weewx.conf in /etc/weewx/

Installed the GW1000 driver from
<https://github.com/Millardiang/weewx-gw1000>

On starting weewx, either via systemd, or from the cli it fails at the
first hurdle. Though the error has now changed - Doh! I have had

It was:
<code>
weewx.engine.InitializationError: Failed to obtain response to command
'CMD_READ_STATION_MAC'
</code>

Now it is :
<code>
weewx.engine.InitializationError: Failed to obtain response to command
'CMD_READ_FIRMWARE_VERSION'
</code>

I have attached the output of weectl debug & the startup part of the
syslog filtered for weewx - it seemed no point in more as it just repeats.

Also a screen shot of the WSView-plus screen - but I notice now that the
port is set at 8000 (it defaulted to that) not 45000 - but a few minutes
later - on changing it, it still fails

The station is found if I set ipaddress & port to auto in the conf file.

Ideas please...

Any more info - just ask, but I think I've covered everything

Many thanks

Nick
M0HGU
weewx.log
weewx.info
Screenshot_20250613_125720_WSView Plus.png

vince

unread,
Jun 13, 2025, 11:38:21 AMJun 13
to weewx-user
The weewx.info file says your port is 46000.  Your log says 45000. Your post says 8000. 

Nick

unread,
Jun 13, 2025, 3:22:23 PMJun 13
to weewx...@googlegroups.com
On 13/06/2025 16:38, vince wrote:

Here's how to test it manually....make sure you have the ip address correct
in weewx.conf

# for a venv installation (tested)
PYTHONPATH=~/weewx/src python3 ~/weewx-data/bin/user/gw1000.py
--test-driver --ip-address=192.168.2.87

# for a dpkg installation (found in an old google search)
PYTHONPATH=/etc/weewx/bin python3 -m user.gw1000 --test-driver
--ip-address=192.168.2.87

Vince,

Vince,

That was not a success ... :-(

<code>
pi@RpiPP:~ $ PYTHONPATH=/etc/weewx/bin python -m user.gw1000
--test-driver --ip-address=192.168.1.104
Traceback (most recent call last):
File "/usr/lib/python3.9/runpy.py", line 197, in _run_module_as_main
return _run_code(code, main_globals, None,
File "/usr/lib/python3.9/runpy.py", line 87, in _run_code
exec(code, run_globals)
File "/etc/weewx/bin/user/gw1000.py", line 380, in <module>
import weecfg
ModuleNotFoundError: No module named 'weecfg'
</code>

There is a conf file in /etc/weewx

Running with auto for IP & Port I see

<code>
Jun 13 20:13:52 RpiPP weewxd[8000]: INFO user.gw1000: 'unknown model'
was found at 192.168.1.104:45000
Jun 13 20:13:52 RpiPP weewxd[8000]: INFO user.gw1000: Using
discovered address 192.168.1.104:45000
</code>

So 45000 & the IP are correct, the IP of the RPI is 192.168.1.68 as per
the WSView-Plus application.

I am stumped

Regards & thanks

Nick

vince

unread,
Jun 13, 2025, 3:58:10 PMJun 13
to weewx-user
The old PYTHONPATH needs to look in two places now - one where user stuff goes, one where weewx core goes.

Try the following (tests ok here):
PYTHONPATH=/etc/weewx/bin:/usr/share/weewx python3 -m user.gw1000 --test-driver --ip-address=192.168.1.104

Nick

unread,
Jun 13, 2025, 4:07:30 PMJun 13
to weewx...@googlegroups.com
On 13/06/2025 20:58, vince wrote:
> The old PYTHONPATH needs to look in two places now - one where user stuff
> goes, one where weewx core goes.
>
> Try the following (tests ok here):
> PYTHONPATH=/etc/weewx/bin:/usr/share/weewx python3 -m user.gw1000
> --test-driver --ip-address=192.168.1.104
>
>

Vince,

Some good & some bad news, no funny errors but still no joy.

Here is the output & a ping to show that the station is on the network

<code>
pi@RpiPP:~ $ PYTHONPATH=/etc/weewx/bin:/usr/share/weewx python3 -m
user.gw1000 --test-driver --ip-address=192.168.1.104
Using configuration file /etc/weewx/weewx.conf
debug level is '1'

IP address obtained from command line options
Port number set to default port number
Battery state filtering is 'False' (using the default)

Unable to connect to device: Failed to obtain response to command
'CMD_READ_FIRMWARE_VERSION' after 3 attempts

Things to check include that the correct device IP address is being
used,
the device is powered on and the device is not otherwise
disconnected from
the local network.
pi@RpiPP:~ $ ping 192.168.1.104
PING 192.168.1.104 (192.168.1.104) 56(84) bytes of data.
64 bytes from 192.168.1.104: icmp_seq=1 ttl=128 time=7.44 ms
64 bytes from 192.168.1.104: icmp_seq=2 ttl=128 time=2.64 ms
64 bytes from 192.168.1.104: icmp_seq=3 ttl=128 time=5.67 ms
^C
--- 192.168.1.104 ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 2004ms
rtt min/avg/max/mdev = 2.641/5.247/7.435/1.979 ms
</code>

I am sure this _did_ work with a V4.xxx install so I may just, for
giggles, nuke the V5 install & go for a V4 install that ran as root
rather than the unprivileged user. Though it looks like the firmware
version returned is either miss-coded by the station or the checksum is
wrong or ... so that may not work out any better.

Ho Hum

Regards

Nick

vince

unread,
Jun 13, 2025, 4:59:38 PMJun 13
to weewx-user
I know of no v4 vs v5 issues. I run v5 here. Tests ok for me on both venv and dpkg installations.

I guess I would suggest trying to nmap the gateway from the pi and check the port seems open. If you want to post your current weewx.info I can take a look. But it sounds like a typo or something networky to me, assuming  you have no firewalls in between the pi and the gateway…

Nick

unread,
Jun 14, 2025, 5:34:55 AMJun 14
to weewx...@googlegroups.com
Vince,

Many thanks for all your help yesterday, I have resolved the issue, it
was a combination of a very minor typo that got missed by me & sleeping
on it!

I ditched the gw1000 route as even though I am sure it did work, I was
going crazy.

I'm now using the interceptor (ecowitt-client) and data is flowing as
expected.

Many thanks again

Regards

Nick
CT7/M0HGU
Reply all
Reply to author
Forward
0 new messages