*YAY MATT!! Success at long last :) THANK YOU MATT!!!*
[image: success at long last.PNG]
My notes along the way to success:
10:07 AM Sunday, April 7, 2019 (VKB)
Matt says:
for weewx installed via apt, you want:
PYTHONPATH=/usr/share/weewx python /usr/share/weewx/user/forecast.py
--action=parse --method=xtide --filename=/var/tmp/ellsworth.txt --debug
Results:
pi@raspberrypi:~ $ PYTHONPATH=/usr/share/weewx python
/usr/share/weewx/user/forecast.py --action=parse --method=xtide
--filename=/var/tmp/ellsworth.txt --debug
[{'event_ts': 1554590640, 'dateTime': 1554646140, 'location': None, 'hilo':
'L', 'offset': '0.64', 'issued_ts': 1554646140, 'method': 'XTide',
'usUnits': 1}, {'event_ts': 1554612480, 'dateTime': 1554646140, 'location':
None, 'hilo': 'H', 'offset': '11.10', 'issued_ts': 1554646140, 'method':
'XTide', 'usUnits': 1}, {'event_ts': 1554635100, 'dateTime': 1554646140,
'location': None, 'hilo': 'L', 'offset': '0.14', 'issued_ts': 1554646140,
'method': 'XTide', 'usUnits': 1}, {'event_ts': 1554657000, 'dateTime':
1554646140, 'location': None, 'hilo': 'H', 'offset': '10.76', 'issued_ts':
1554646140, 'method': 'XTide', 'usUnits': 1}, {'event_ts': 1554679020,
'dateTime': 1554646140, 'location': None, 'hilo': 'L', 'offset': '0.64',
'issued_ts': 1554646140, 'method': 'XTide', 'usUnits': 1}, {'event_ts':
1554700740, 'dateTime': 1554646140, 'location': None, 'hilo': 'H',
'offset': '11.33', 'issued_ts': 1554646140, 'method': 'XTide', 'usUnits':
1}, {'event_ts': 1554723720, 'dateTime': 1554646140, 'location': None,
'hilo': 'L', 'offset': '-0.03', 'issued_ts': 1554646140, 'method': 'XTide',
'usUnits': 1}, {'event_ts': 1554745500, 'dateTime': 1554646140, 'location':
None, 'hilo': 'H', 'offset': '10.73', 'issued_ts': 1554646140, 'method':
'XTide', 'usUnits': 1}, {'event_ts': 1554767640, 'dateTime': 1554646140,
'location': None, 'hilo': 'L', 'offset': '0.70', 'issued_ts': 1554646140,
'method': 'XTide', 'usUnits': 1}, {'event_ts': 1554789300, 'dateTime':
1554646140, 'location': None, 'hilo': 'H', 'offset': '11.48', 'issued_ts':
1554646140, 'method': 'XTide', 'usUnits': 1}, {'event_ts': 1554812640,
'dateTime': 1554646140, 'location': None, 'hilo': 'L', 'offset': '-0.10',
'issued_ts': 1554646140, 'method': 'XTide', 'usUnits': 1}, {'event_ts':
1554834360, 'dateTime': 1554646140, 'location': None, 'hilo': 'H',
'offset': '10.62', 'issued_ts': 1554646140, 'method': 'XTide', 'usUnits':
1}, {'event_ts': 1554856560, 'dateTime': 1554646140, 'location': None,
'hilo': 'L', 'offset': '0.83', 'issued_ts': 1554646140, 'method': 'XTide',
'usUnits': 1}, {'event_ts': 1554878280, 'dateTime': 1554646140, 'location':
None, 'hilo': 'H', 'offset': '11.52', 'issued_ts': 1554646140, 'method':
'XTide', 'usUnits': 1}, {'event_ts': 1554901860, 'dateTime': 1554646140,
'location': None, 'hilo': 'L', 'offset': '-0.08', 'issued_ts': 1554646140,
'method': 'XTide', 'usUnits': 1}]
pi@raspberrypi:~ $
==============================
Matt says:
you should probably put tide.sh in /usr/share/weewx/user/tide.sh
Then:
pi@raspberrypi:/opt/weewx/bin/user $ sudo mv tide.sh
/usr/share/weewx/user/tide.sh
=========
Matt says:
then adjust paths in weewx.conf appropriately
Then in /etc/weewx/weewx.conf
Looking @ line 639, et als
#####################################################
# Options for extension 'forecast'
[Forecast]
data_binding = forecast_binding
[[NWS]]
lid = MEZ029
foid = CAR
...
[[XTide]]
prog = /usr/share/weewx/user/tide.sh
location = Ellsworth
Success at long last! YAY Matt!
10:32 AM Sunday, April 7, 2019 (VKB)
On Saturday, April 6, 2019 at 8:17:13 PM UTC-4, mwall wrote:
>
>
> On Saturday, April 6, 2019 at 2:21:39 PM UTC-4, V. Kelly Bellis wrote:
>>
>> Trying next:
>> PYTHONPATH=bin python /usr/share/weewx/user/forecast.py --action=parse
>> --method=xtide --filename=/var/tmp/ellsworth.txt --debug
>>
>> Which then reults:
>> pi@raspberrypi:/ $ PYTHONPATH=bin python
>> /usr/share/weewx/user/forecast.py --action=parse --method=xtide
>> --filename=/var/tmp/ellsworth.txt --debug
>> Traceback (most recent call last):
>> File "/usr/share/weewx/user/forecast.py", line 566, in <module>
>> import weewx
>> ImportError: No module named weewx
>>
>
> for weewx installed via apt, you want:
>
> PYTHONPATH=/usr/share/weewx python /usr/share/weewx/user/forecast.py
> --action=parse --method=xtide --filename=/var/tmp/ellsworth.txt --debug
>
> you should probably put tide.sh in /usr/share/weewx/user/tide.sh
>
> or maybe create a directory /opt/tide and fill it with:
>
> /opt/tide/tide.sh
> /opt/tide/harmonics-dwf-20181227-free.tcd
>
> then adjust paths in tide.sh and weewx.conf appropriately
>
> i put it in /opt/weewx/bin/user/tide.sh because my weewx is installed at
> /opt/weewx
>
> m
>
>
>
--
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 [email protected].
For more options, visit https://groups.google.com/d/optout.