Re: [weewx-user] Problem with GW1000 driver

2021-08-08 Thread William Borrelli
OK, I am new to this GW1000 and Ambient WS-2000 thingy.
I stumbled across this thread while trying to figure out why I am having 
problems.

I would truly appreciate some help figuring this one out.

Thanks.

-Bill


First the initial trouble shooting you will ask for.

=
@raspberrypi:/usr/share/weewx# PYTHONPATH=/usr/share/weewx python -m 
user.gw1000 --live-data --ip-address=10.0.0.51 --debug=3
Using configuration file /etc/weewx/weewx.conf
debug level is '3'

IP address obtained from command line options
Port number obtained from station config

Interrogating GW1000 at 10.0.0.51:45000

GW1000 live sensor data (2021-08-08 20:49:26 EDT (1628470166)): 
absbarometer: 994.7hPa, daymaxwind: 5kph, gustspeed: 0kph, inhumid: 64%, 
intemp: 28.4°C, light: 0lx, outhumid: 76%, outtemp: 24.9°C, rainday: 0.0mm, 
rainevent: 0.0mm, rainmonth: 0.0mm, rainrate: 0.0mm/h, rainweek: 0.0mm, 
rainyear: 0.0mm, relbarometer: 994.7hPa, uv: 0W/m², uvi: 0.0, wh65_batt: 0, 
wh65_sig: 3, winddir: 130°, windspeed: 0kph
=
--@raspberrypi:/usr/share/weewx# PYTHONPATH=/usr/share/weewx python -m 
user.gw1000 --firmware-version --debug=3
Using configuration file /etc/weewx/weewx.conf
debug level is '3'

IP address obtained from station config
Port number obtained from station config

Interrogating GW1000 at 10.0.0.51:45000

GW1000 firmware version string: GW1000B_V1.6.8

=
And then what I am seeing in the messages log after systemctl restart 
weewx  (apt install version)

Aug  8 20:53:57 raspberrypi weewx[14209] INFO __main__: Initializing weewx 
version 4.5.1
Aug  8 20:53:57 raspberrypi weewx[14209] INFO __main__: Using Python 3.7.3 
(default, Jan 22 2021, 20:04:44) #012[GCC 8.3.0]
Aug  8 20:53:57 raspberrypi weewx[14209] INFO __main__: Platform 
Linux-5.10.52-v7+-armv7l-with-debian-10.10
Aug  8 20:53:57 raspberrypi weewx[14209] INFO __main__: Locale is 
'en_US.UTF-8'
Aug  8 20:53:57 raspberrypi weewx[14209] INFO __main__: PID file is 
/var/run/weewx.pid
Aug  8 20:53:57 raspberrypi weewx[14214] INFO __main__: Using configuration 
file /etc/weewx/weewx.conf
Aug  8 20:53:57 raspberrypi weewx[14214] INFO __main__: Debug is 1
Aug  8 20:53:57 raspberrypi weewx[14214] INFO weewx.engine: Loading station 
type GW1000 (user.gw1000)
Aug  8 20:53:57 raspberrypi weewx[14214] INFO user.gw1000: field map is 
{'co2': 'co2', 'co2_24h_avg': 'co2_24h_avg', 'dateTime': 'datetime', 
'daymaxwind': 'daymaxwind', 'dayRain': 'rainday', 'dewpoint': 'dewpoint', 
'extraHumid1': 'humid1', 'extraHumid2': 'humid2', 'extraHumid3': 'humid3', 
'extraHumid4': 'humid4', 'extraHumid5': 'humid5', 'extraHumid6': 'humid6', 
'extraHumid7': 'humid7', 'extraHumid8': 'humid8', 'extraHumid17': 
'humid17', 'extraTemp1': 'temp1', 'extraTemp2': 'temp2', 'extraTemp3': 
'temp3', 'extraTemp4': 'temp4', 'extraTemp5': 'temp5', 'extraTemp6': 
'temp6', 'extraTemp7': 'temp7', 'extraTemp8': 'temp8', 'extraTemp9': 
'temp9', 'extraTemp10': 'temp10', 'extraTemp11': 'temp11', 'extraTemp12': 
'temp12', 'extraTemp13': 'temp13', 'extraTemp14': 'temp14', 'extraTemp15': 
'temp15', 'extraTemp16': 'temp16', 'extraTemp17': 'temp17', 'heatindex': 
'heatindex', 'hourRain': 'rainhour', 'inHumidity': 'inhumid', 'inTemp': 
'intemp', 'leafWet1': 'leafwet1', 'leafWet2': 'leafwet2', 'leafWet3': 
'leafwet3', 'leafWet4': 'leafwet4', 'leafWet5': 'leafwet5', 'leafWet6': 
'leafwet6', 'leafWet7': 'leafwet7', 'leafWet8': 'leafwet8', 'leak1': 
'leak1', 'leak2': 'leak2', 'leak3': 'leak3', 'leak4': 'leak4', 
'lightning_distance': 'lightningdist', 'lightning_last_det_time': 
'lightningdettime', 'lightning_strike_count': 'lightning_strike_count', 
'lightningcount': 'lightningcount', 'luminosity': 'light', 'monthRain': 
'rainmonth', 'outHumidity': 'outhumid', 'outTemp': 'outtemp', 'pm2_5': 
'pm251', 'pm2_51_24h_avg': 'pm251_24h_avg', 'pm2_52': 'pm252', 
'pm2_52_24h_avg': 'pm252_24h_avg', 'pm2_53': 'pm253', 'pm2_53_24h_avg': 
'pm253_24h_avg', 'pm2_54': 'pm254', 'pm2_54_24h_avg': 'pm254_24h_avg', 
'pm2_55': 'pm255', 'pm2_55_24h_avg': 'pm255_24h_avg', 'pm10': 'pm10', 
'pm10_24h_avg': 'pm10_24h_avg', 'pressure': 'absbarometer', 'rain': 'rain', 
'rainRate': 'rainrate', 'relbarometer': 'relbarometer', 'soilMoist1': 
'soilmoist1', 'soilMoist2': 'soilmoist2', 'soilMoist3': 'soilmoist3', 
'soilMoist4': 'soilmoist4', 'soilMoist5': 'soilmoist5', 'soilMoist6': 
'soilmoist6', 'soilMoist7': 'soilmoist7', 'soilMoist8': 'soilmoist8', 
'soilMoist9': 'soilmoist9', 'soilMoist10': 'soilmoist10', 'soilMoist11': 
'soilmoist11', 'soilMoist12': 'soilmoist12', 'soilMoist13': 'soilmoist13', 
'soilMoist14': 'soilmoist14', 

Re: [weewx-user] Re: BME280 Sensor Missing Inside Temp Readings

2021-08-08 Thread Gazza
I had a similar issue in July last year and it was discussed in these 
threads:
https://groups.google.com/g/weewx-user/c/-azmKGA3q_U/m/j8i9ih20BwAJ
https://groups.google.com/g/weewx-user/c/MycfgX74P1Y

The  "*_must_have" lines need to contain the value of a valid sensor for 
the bme280 readings to be added to the loop data. In my setup I use 
"outTemp" from my rtlsdr in all of these lines and it works fine.


The other Gary


On Monday, August 9, 2021 at 12:30:33 AM UTC+10 mksm...@gmail.com wrote:

> can you try this
>
> [Bme280wx]
> i2c_port = 1
> i2c_address = 0x76
> usUnits = US
> pressureKeys = pressure
> pressure_must_have = outTemp
> humidityKeys = inHumidity
> humidity_must_have = outTemp
> temperatureKeys = inTemp
> temperature_must_have = outTemp
>
> On Sunday, August 8, 2021 at 3:49:48 PM UTC+3 gjr80 wrote:
>
>> OK. Let's put a bit more logging in bme280wx.py, we'll just look at 
>> pressure for now. Move aside your existing 
>> /usr/share/weewx/user/bme280wx.py by renaming it as bme280wx_orig.py. 
>> Download the attached bme280wx.py and save it in it's place in the /
>> usr/share/weewx/user directory. Leave debug = 1 and restart WeeWX. Post 
>> the log including WeeWX startup and the first half dozen loop packets.
>>
>> Gary
>> On Sunday, 8 August 2021 at 21:47:36 UTC+10 wxwatching wrote:
>>
>>> Ok, here's the current section from config file:
>>>
>>> [Engine]
>>>
>>> # The following section specifies which services should be run and 
>>> in what order.
>>> [[Services]]
>>> prep_services = weewx.engine.StdTimeSynch
>>> data_services = user.bme280wx.Bme280wx,
>>> process_services = weewx.engine.StdConvert, 
>>> weewx.engine.StdCalibrate, weewx.engine.StdQC, 
>>> weewx.wxservices.StdWXCalculate
>>> xtype_services = weewx.wxxtypes.StdWXXTypes, 
>>> weewx.wxxtypes.StdPressureCooker, weewx.wxxtypes.StdRainRater, 
>>> weewx.wxxtypes.StdDelta
>>> archive_services = weewx.engine.StdArchive
>>> restful_services = weewx.restx.StdStationRegistry, 
>>> weewx.restx.StdWunderground, weewx.restx.StdPWSweather, 
>>> weewx.restx.StdCWOP, weewx.restx.StdWOW, weewx.restx.StdAWEKAS
>>> report_services = weewx.engine.StdPrint, weewx.engine.StdReport
>>>
>>> [Bme280wx]
>>> i2c_port = 1
>>> i2c_address = 0x76
>>> usUnits = US
>>> pressureKeys = pressure
>>> pressure_must_have = ""
>>> humidityKeys = inHumidity
>>> humidity_must_have = ""
>>> temperatureKeys = inTemp
>>> temperature_must_have = ""
>>>
>>> New problem now is that the loop apparently hangs and WeeWX quits 
>>> reporting weather data.
>>>
>>> sudo weewxd
>>> LOOP:   2021-08-08 07:36:29 EDT (1628422589) dateTime: 1628422589, lux: 
>>> 13470, maxSolarRad: None, outTempBatteryStatus: 0, radiation: 
>>> 106.314127861, rainRate: 0, usUnits: 1, UV: 1, windSpeed: 0.0
>>> LOOP:   2021-08-08 07:36:29 EDT (1628422589) dateTime: 1628422589, lux: 
>>> 13470, maxSolarRad: None, outTempBatteryStatus: 0, radiation: 
>>> 106.314127861, rainRate: 0, usUnits: 1, UV: 1, windSpeed: 0.0
>>> LOOP:   2021-08-08 07:36:29 EDT (1628422589) dateTime: 1628422589, lux: 
>>> 13470, maxSolarRad: None, outTempBatteryStatus: 0, radiation: 
>>> 106.314127861, rainRate: 0, usUnits: 1, UV: 1, windSpeed: 0.0
>>> LOOP:   2021-08-08 07:36:39 EDT (1628422599) appTemp: 78.5400076483, 
>>> cloudbase: 229.659363466, dateTime: 1628422599, dewpoint: 70.6, heatindex: 
>>> 72.06, humidex: 86.4663612495, maxSolarRad: None, outHumidity: 100.0, 
>>> outTemp: 70.6, outTempBatteryStatus: 0, rainRate: 0, usUnits: 1, windchill: 
>>> 70.6, windSpeed: 0.0
>>> LOOP:   2021-08-08 07:36:39 EDT (1628422599) appTemp: 78.5400076483, 
>>> cloudbase: 229.659363466, dateTime: 1628422599, dewpoint: 70.6, heatindex: 
>>> 72.06, humidex: 86.4663612495, maxSolarRad: None, outHumidity: 100.0, 
>>> outTemp: 70.6, outTempBatteryStatus: 0, rainRate: 0, usUnits: 1, windchill: 
>>> 70.6, windSpeed: 0.0
>>> LOOP:   2021-08-08 07:36:39 EDT (1628422599) appTemp: 78.5400076483, 
>>> cloudbase: 229.659363466, dateTime: 1628422599, dewpoint: 70.6, heatindex: 
>>> 72.06, humidex: 86.4663612495, maxSolarRad: None, outHumidity: 100.0, 
>>> outTemp: 70.6, outTempBatteryStatus: 0, rainRate: 0, usUnits: 1, windchill: 
>>> 70.6, windSpeed: 0.0
>>> LOOP:   2021-08-08 07:36:49 EDT (1628422609) dateTime: 1628422609, 
>>> maxSolarRad: None, outTempBatteryStatus: 0, rain: None, rainRate: 0, 
>>> rain_total: 2.07, usUnits: 1, windDir: None, windSpeed: 0.0
>>> LOOP:   2021-08-08 07:36:49 EDT (1628422609) dateTime: 1628422609, 
>>> maxSolarRad: None, outTempBatteryStatus: 0, rain: 0.0, rainRate: 0, 
>>> rain_total: 2.07, usUnits: 1, windDir: None, windSpeed: 0.0
>>> LOOP:   2021-08-08 07:36:49 EDT (1628422609) dateTime: 1628422609, 
>>> maxSolarRad: None, outTempBatteryStatus: 0, rain: 0.0, rainRate: 0, 
>>> rain_total: 2.07, usUnits: 1, windDir: None, windSpeed: 0.0
>>>
>>> And the output from the syslog is:
>>>

Re: [weewx-user] Re: recommend IP cameras that are easy to grab a single frame from?

2021-08-08 Thread Eric Koester
I have been working with the ESP32-CAM wifi camera today.

In weewx, I'm using the Belchertown webpage skin.
In its stock setup, you get a weather RADAR image from Windy.com, that
updates every 5 minutes.
This afternoon, I replaced the Windy.com RADAR plot with the webcam image.
I don't really want to trade the RADAR for the webcam, but I'm not sure of
a slick way to have both, yet.

It takes about 10 seconds to transfer an image frame from the ESP32-CAM to
the Raspberry Pi.
To remove this delay from the webpage, I wrote a simple executable bash
script to grab the webcam image and store it on the Raspberry Pi micro-SD
card.
Then, I have the weewx webpage fetch the webcam.jpg file from the "hard
drive" so it loads instantly.

fetch script:
#!/bin/bash
wget http://192.168.8.122/snapshot.jpg -O
/home/weewx/public_html/images/webcam.jpg

Then I have the Belchertown skin put the webcam.jpg file into the page,

from the Belchertown index.html.tmpl file:







I'd like to polish this a bit, but it is working.



On Sat, Aug 7, 2021 at 5:32 PM p q  wrote:

> Please continue to post your results. Particularly which hardware you
> choose. I'm interested in doing the same with my own skin.
>
> As a side note, I'm playing around with Grafana to see what advantages it
> has compared to the standard graphs. It was easy to install on my raspberry
> pi and fairly easy to hook up to the SQLite DB.
>
> On Sat, Aug 7, 2021 at 3:24 PM Eric K  wrote:
>
>> I also want to check out your perl scripts, @mwall!
>>
>> On Saturday, August 7, 2021 at 5:18:33 PM UTC-5 Eric K wrote:
>>
>>> Thanks for all the responses.
>>>
>>> Shortly after posting this I got a couple of the ESP32-CAM modules and
>>> loaded Tasmota firmware into them.
>>> see:  https://cgomesu.com/blog/Esp32cam-tasmota-webcam-server/
>>> You have to use the specific Tasmota32 webcam firmware:
>>> tasmota32-webcam.bin
>>> 
>>> The maximum resolution of these is only 1600x1200.
>>> The upside is that you can easily grab a single frame using a simple URL
>>> command:  http://192.168.8.122/snapshot.jpg
>>> The only downsides I see:  with the plastic lens and jpeg compression,
>>> the images are not great for fine detail.
>>>
>>> Given the low cost, small size, MIPI camera interface, and wifi
>>> capability of the RPi Zero W board, I reconsidered an RPi camera.
>>> I'm currently assembling a RPi Zero camera with a 5mp camera module.
>>> I am getting single images out of it with the raspistill application:
>>> raspistill -v -o /home/pi/Pictures/pi-cam-test.jpg
>>>
>>> I'd like to grab an image every 5-10 minutes and have the current image
>>> show up in the Belchertown weewx page.
>>> I'd also like to create a daily time lapse movie like others have done.
>>> I recall seeing some webcam script examples in this weewx-user group to
>>> do these 2 things.
>>> I need to search for them again.
>>>
>>>

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/CADh_oriswwSQKSTxtpWjMDjQJciRihV_B95ZxN%3DZ0nVK18Gbnw%40mail.gmail.com.


[weewx-user] Re: How is calculated rainrate if no rain data before sudden rain.

2021-08-08 Thread gjr80
When I looked at the ws28xx driver code I see the likes of data._Rain1H 
used in the rainRate calculation so that lends weight to the use of one 
hour rainfall data. If you are a glutton for punishment search the forums 
(weewx-user I think, but could be weewx-development) for calculation of 
rainRate - a few years ago we were revising the rainRate calculation in 
StdWXCalculate (or were we pulling the calculation out of some drivers, I 
cannot remember) and there was quite a thread on it. There are various 
methods of calculation each with their own pluses and minuses, eg reducing 
the ‘window’ used reduces the taper period, using a simple rain in the last 
hour based calculation can give a non-zero rainRate for up to one hour 
after the last rain fell.

Gary
On Monday, 9 August 2021 at 03:22:17 UTC+10 michael.k...@gmx.at wrote:

> Yes, the station in question is still the WS28xx, yes, there is a rainRate 
> = prefer_hardware setting in the config. Thanks, that explains it.
> My best guess how the WS28xx driver calculates the rainRate is in some 
> kind "hour-based rolling average": the Super Cell event brought about 25mm 
> in one hour, a couple of weeks later another event brought ~38mm in one 
> hour:
>
> dateTimerain  rainRate
> 1626545100  4.127879  37.173
> 1626544800  3.095955  36.3272727272727
> 1626544500  7.481997  32.737
> 1626544200  3.87008   27.97444
> 1626543900  2.837974  25.2572727272727
> 1626543600  3.869898  22.004
> 1626543300  3.87008   17.978
> 1626543000  1.290087  15.296
> 1626542700  1.548068  13.953
> 1626542400  1.031924  12.716
> 1626542100  3.095955  10.96
> 1626541800  2.579993  8.253
>
>
> gjr80 schrieb am Samstag, 7. August 2021 um 03:41:49 UTC+2:
>
>> I believe the answer will depend on your WeeWX configuration and the 
>> station/driver you use. A default WeeWX install is set to obtain rainRate 
>> from the driver but if the driver does not provide rainRate then WeeWX 
>> will calculate it (rainRate = prefer_hardware under [StdWXCalculate] 
>> [[Calculations]] in weewx.conf). I see in a previous thread you referred 
>> to 'your WS28xx' - if you are still using the WS28xx then the answer is 
>> likely in the WS28xx driver as the WS28xx driver is one of the few that 
>> does provide rainRate. I had a brief look at the WS28xx driver and it is 
>> not evident to me how it derives rainRate, but it is clear it does not 
>> use the same algorithm as WeeWX - that is also evident in the archive data 
>> you presented. 
>>
>> If you wanted to use the WeeWX algorithm then you could change the rainRate 
>> = prefer_hardware to rainRate = software, I'm not saying the WS28xx is 
>> wrong, it just appears to use a different algorithm. On the face of it I 
>> don't really see anything wrong with your figures, though granted the 25.02 
>> values are quite high given there was no rainfall for at least five minutes 
>> for the second 25.02 value, that could be because the WS28xx tapers the 
>> rainRate at a different rate to WeeWX.
>>
>> Gary
>> On Saturday, 7 August 2021 at 05:47:40 UTC+10 michael.k...@gmx.at wrote:
>>
>>> Thanks Gary. Do you have an explanation for this:
>>>
>>> I got hit by a Super Cell thunderstorm some weeks ago which delivered 
>>> ~25mm in about 15 mins. Max rain rate for this month was those 25mm:
>>>
>>> archive_day_rainrate
>>> dateTimemin  mintime  maxmaxtime sum  
>>>  count  wsum  sumtime
>>> 1624312800  0.0  1624312803   25.28  1624395078  376.134682539682  
>>> 288112840.404761905  86400
>>>
>>> select datetime, rain, rainrate from archive where datetime between 
>>> 1624384800 and 1624399200 ORDER by datetime DESC
>>> dateTimerainrainRate
>>> 1624393200  0.0 25.02
>>> 1624392900  0.0 25.02
>>> 1624392600  1.03192424.737
>>> 1624392300  6.19209221.512
>>> 1624392000  17.286018.48545454545454
>>> 1624391700  0.5157803   0.076
>>> 1624391400  0.0 0.0
>>>
>>> gjr80 schrieb am Mittwoch, 28. Juli 2021 um 14:30:52 UTC+2:
>>>
 WeeWX calculates rainRate by summing the rain seen in the last 900 
 seconds (15 minutes) and scales this to a per hour figure by multiplying 
 by 
 3600/900. So your 21.8 mm appearing in one packet/record would have 
 resulted in 21.8. * 4 = 87.2mm/hr; exactly what you saw. Due to the 900 
 second window being used the 87.2 mm/hr value would have persisted for up 
 to 15 minutes. The 34.9 value may have been the result of when the 21.8mm 
 value arrived, impossible to say without seeing the exact loop 
 packet/archive record history. You can change the 900 second window to 
 some 
 other value, say 600 seconds (10 minutes) and WeeWX would then take the 
 rainfall seen in the last 10 minutes and scale that 

[weewx-user] Re: Trying to gee AS3935 to work with weewx 4.5.1

2021-08-08 Thread philip....@gmail.com
Is the Calibration figure in weewx.conf the same as the tuning capacitance 
of the chip on the lightning detector
Why I ask is the dfrobot = 8 - 120 pf and has to be in multiple of 8's
They suggest 96 to start with but the Calibration figure in weewx.conf will 
only except 0-15
Or does that relate to some other figure
Thanks in anticipation
Phil

On Sunday, August 8, 2021 at 4:32:05 PM UTC+1 philip@gmail.com wrote:

> Im using python2 so as to get a lightning detector to work to that
> Just had several lightning strikes overhead but it only recorded 1 strike 
> 10km away and nothing else
> Can anybody recommend a lightning detector that does work connected to a 
> raspberry pi via weewx
> The mod 1016 from EMBEDDED ADVENTURES has been mentioned but they dont 
> seem to be in business anymore  
> Thanks
> Phil
>
> On Sunday, August 8, 2021 at 8:08:59 AM UTC+1 ian.r...@gmail.com wrote:
>
>> I think I have found the remaining Python 2 issue - 2to3 didnt find it 
>> when I tried
>>
>> In as3935.py on line 73 change from:
>>
>> from RPi_AS3935 import RPi_AS3935
>>
>> to:
>>
>> from RPi_AS3935.RPi_AS3935 import RPi_AS3935
>>
>> Seems to be related to the situation discussed here
>>
>> https://stackoverflow.com/questions/4534438/typeerror-module-object-is-not-callable
>> On Saturday, 7 August 2021 at 02:06:07 UTC+12 philip@gmail.com wrote:
>>
>>> Lightning all round today but the only log entries were when the 
>>> lightning was over head 7 in total
>>> as3935: strike at 1.0 km
>>> Calibration = 6 , changed to 2 didn't seem to make any difference
>>> Storms now gone and still not sure if the dfrobot works that well
>>>
>>>
>>>
>>> On Saturday, July 31, 2021 at 1:06:06 PM UTC+1 philip@gmail.com 
>>> wrote:
>>>
 In the as3935.py I noticed for LOOP working I have to put that in the 
 weewx.conf file which then showed lightning_strikes = 0
 When checking the weewx.sdb it didnt have a lightning_strikes field its 
 called lightning_strikes_count
 When I added lighnting_strikes it now has a zero (0) in. 
 So has the field names changed ??
 The test will be when I get any lightning I shall keep you posted.


 On Saturday, July 31, 2021 at 12:59:38 PM UTC+1 philip@gmail.com 
 wrote:

> In the as3935.py
>
> On Saturday, July 31, 2021 at 10:45:17 AM UTC+1 philip@gmail.com 
> wrote:
>
>> Thanks Doug but it didnt make any difference
>> As Im trying to use a DFRobot AS3935 I started again but this time on 
>> Python2
>> The i2cdetect -y 1 shows 03 show it appears the Raspberry Pi can see 
>> the AS3935
>> Using the simulator driver weewx now starts
>> Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Initializing weewx 
>> version 3.9.2
>> Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Using Python 2.7.16 
>> (default, Oct 10 2019, 22:02:15) #012[GCC 8.3.0]
>> Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Platform 
>> Linux-5.10.52-v7+-armv7l-with-debian-10.10
>> Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Locale is 
>> 'en_GB.UTF-8'
>> Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Using configuration 
>> file /home/weewx/weewx.conf
>> Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Loading station type 
>> Simulator (weewx.drivers.simulator)
>> Jul 31 10:17:47 raspberrypi weewx[2241]: engine: StdConvert target 
>> unit is 0x1
>> Jul 31 10:17:47 raspberrypi weewx[2241]: wxcalculate: The following 
>> values will be calculated: barometer=prefer_hardware, 
>> windchill=prefer_hardware, dewpoint=prefer_hardware, 
>> appTemp=prefer_hardware, rainRate=prefer_hardware, 
>> windrun=prefer_hardware, 
>> heatindex=prefer_hardware, maxSolarRad=prefer_hardware, 
>> humidex=prefer_hardware, pressure=prefer_hardware, 
>> inDewpoint=prefer_hardware, ET=prefer_hardware, 
>> altimeter=prefer_hardware, 
>> cloudbase=prefer_hardware
>> Jul 31 10:17:47 raspberrypi weewx[2241]: wxcalculate: The following 
>> algorithms will be used for calculations: altimeter=aaNOAA, 
>> maxSolarRad=RS
>> Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: service version is 
>> 0.6
>> Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: address=0x03
>> Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: bus=1
>> Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: indoors=True
>> Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: noise_floor=0
>> Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: calibration=0x06
>> Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: pin=17
>> Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: data_binding=None
>> Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: binding=archive
>> Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Archive will use 
>> data binding wx_binding
>> Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Record generation 
>> will be attempted in 

[weewx-user] How to generate report like downld08.txt from weatherlink?

2021-08-08 Thread Juk74
I am Spanish and I am in an association called avamet www.avamet.org.

When uploading the data, they recommend a file like the Weatherlink 
downld08.txt, in order to recover the possible data lost due to connection 
failures.

Could you create something similar in weewx?

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/52587501-24a0-4e64-97fc-951ef696ac2en%40googlegroups.com.


[weewx-user] Re: How is calculated rainrate if no rain data before sudden rain.

2021-08-08 Thread michael.k...@gmx.at
Yes, the station in question is still the WS28xx, yes, there is a rainRate 
= prefer_hardware setting in the config. Thanks, that explains it.
My best guess how the WS28xx driver calculates the rainRate is in some kind 
"hour-based rolling average": the Super Cell event brought about 25mm in 
one hour, a couple of weeks later another event brought ~38mm in one hour:

dateTimerain  rainRate
1626545100  4.127879  37.173
1626544800  3.095955  36.3272727272727
1626544500  7.481997  32.737
1626544200  3.87008   27.97444
1626543900  2.837974  25.2572727272727
1626543600  3.869898  22.004
1626543300  3.87008   17.978
1626543000  1.290087  15.296
1626542700  1.548068  13.953
1626542400  1.031924  12.716
1626542100  3.095955  10.96
1626541800  2.579993  8.253


gjr80 schrieb am Samstag, 7. August 2021 um 03:41:49 UTC+2:

> I believe the answer will depend on your WeeWX configuration and the 
> station/driver you use. A default WeeWX install is set to obtain rainRate 
> from the driver but if the driver does not provide rainRate then WeeWX 
> will calculate it (rainRate = prefer_hardware under [StdWXCalculate] 
> [[Calculations]] in weewx.conf). I see in a previous thread you referred 
> to 'your WS28xx' - if you are still using the WS28xx then the answer is 
> likely in the WS28xx driver as the WS28xx driver is one of the few that 
> does provide rainRate. I had a brief look at the WS28xx driver and it is 
> not evident to me how it derives rainRate, but it is clear it does not 
> use the same algorithm as WeeWX - that is also evident in the archive data 
> you presented. 
>
> If you wanted to use the WeeWX algorithm then you could change the rainRate 
> = prefer_hardware to rainRate = software, I'm not saying the WS28xx is 
> wrong, it just appears to use a different algorithm. On the face of it I 
> don't really see anything wrong with your figures, though granted the 25.02 
> values are quite high given there was no rainfall for at least five minutes 
> for the second 25.02 value, that could be because the WS28xx tapers the 
> rainRate at a different rate to WeeWX.
>
> Gary
> On Saturday, 7 August 2021 at 05:47:40 UTC+10 michael.k...@gmx.at wrote:
>
>> Thanks Gary. Do you have an explanation for this:
>>
>> I got hit by a Super Cell thunderstorm some weeks ago which delivered 
>> ~25mm in about 15 mins. Max rain rate for this month was those 25mm:
>>
>> archive_day_rainrate
>> dateTimemin  mintime  maxmaxtime sum  
>>  count  wsum  sumtime
>> 1624312800  0.0  1624312803   25.28  1624395078  376.134682539682  
>> 288112840.404761905  86400
>>
>> select datetime, rain, rainrate from archive where datetime between 
>> 1624384800 and 1624399200 ORDER by datetime DESC
>> dateTimerainrainRate
>> 1624393200  0.0 25.02
>> 1624392900  0.0 25.02
>> 1624392600  1.03192424.737
>> 1624392300  6.19209221.512
>> 1624392000  17.286018.48545454545454
>> 1624391700  0.5157803   0.076
>> 1624391400  0.0 0.0
>>
>> gjr80 schrieb am Mittwoch, 28. Juli 2021 um 14:30:52 UTC+2:
>>
>>> WeeWX calculates rainRate by summing the rain seen in the last 900 
>>> seconds (15 minutes) and scales this to a per hour figure by multiplying by 
>>> 3600/900. So your 21.8 mm appearing in one packet/record would have 
>>> resulted in 21.8. * 4 = 87.2mm/hr; exactly what you saw. Due to the 900 
>>> second window being used the 87.2 mm/hr value would have persisted for up 
>>> to 15 minutes. The 34.9 value may have been the result of when the 21.8mm 
>>> value arrived, impossible to say without seeing the exact loop 
>>> packet/archive record history. You can change the 900 second window to some 
>>> other value, say 600 seconds (10 minutes) and WeeWX would then take the 
>>> rainfall seen in the last 10 minutes and scale that figure to a per hour 
>>> figure (in that case multiply by 3600/600).
>>>
>>> This is covered in the [[RainRater]] 
>>> stanza 
>>> in the User’s Guide. Note the Userks Guide states that 1800 seconds (30 
>>> minutes) is used by default for the window but the code actually uses 900 
>>> seconds. Must fix the documentation.
>>>
>>> Gary
>>>
>>> On Wednesday, 28 July 2021 at 22:10:21 UTC+10 wysiwyg wrote:
>>>
 Hi !

 I have a situation where I'm not sure about weewx behavior and how to 
 deal with it :-).

 I have made my own rain sensors: It reports rain every 2min30 and 
 reports 0mm when there's no rain.
 Rainrate calculation is not done and not emitted by the sensor: Weewx 
 has to handle it.

 Now come a situation: My sensor crashed yesterday and did not reported 
 anything over the night (it was raining).
 I rebooted it a few 

[weewx-user] Re: Trying to gee AS3935 to work with weewx 4.5.1

2021-08-08 Thread philip....@gmail.com
Im using python2 so as to get a lightning detector to work to that
Just had several lightning strikes overhead but it only recorded 1 strike 
10km away and nothing else
Can anybody recommend a lightning detector that does work connected to a 
raspberry pi via weewx
The mod 1016 from EMBEDDED ADVENTURES has been mentioned but they dont seem 
to be in business anymore  
Thanks
Phil

On Sunday, August 8, 2021 at 8:08:59 AM UTC+1 ian.r...@gmail.com wrote:

> I think I have found the remaining Python 2 issue - 2to3 didnt find it 
> when I tried
>
> In as3935.py on line 73 change from:
>
> from RPi_AS3935 import RPi_AS3935
>
> to:
>
> from RPi_AS3935.RPi_AS3935 import RPi_AS3935
>
> Seems to be related to the situation discussed here
>
> https://stackoverflow.com/questions/4534438/typeerror-module-object-is-not-callable
> On Saturday, 7 August 2021 at 02:06:07 UTC+12 philip@gmail.com wrote:
>
>> Lightning all round today but the only log entries were when the 
>> lightning was over head 7 in total
>> as3935: strike at 1.0 km
>> Calibration = 6 , changed to 2 didn't seem to make any difference
>> Storms now gone and still not sure if the dfrobot works that well
>>
>>
>>
>> On Saturday, July 31, 2021 at 1:06:06 PM UTC+1 philip@gmail.com 
>> wrote:
>>
>>> In the as3935.py I noticed for LOOP working I have to put that in the 
>>> weewx.conf file which then showed lightning_strikes = 0
>>> When checking the weewx.sdb it didnt have a lightning_strikes field its 
>>> called lightning_strikes_count
>>> When I added lighnting_strikes it now has a zero (0) in. 
>>> So has the field names changed ??
>>> The test will be when I get any lightning I shall keep you posted.
>>>
>>>
>>> On Saturday, July 31, 2021 at 12:59:38 PM UTC+1 philip@gmail.com 
>>> wrote:
>>>
 In the as3935.py

 On Saturday, July 31, 2021 at 10:45:17 AM UTC+1 philip@gmail.com 
 wrote:

> Thanks Doug but it didnt make any difference
> As Im trying to use a DFRobot AS3935 I started again but this time on 
> Python2
> The i2cdetect -y 1 shows 03 show it appears the Raspberry Pi can see 
> the AS3935
> Using the simulator driver weewx now starts
> Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Initializing weewx 
> version 3.9.2
> Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Using Python 2.7.16 
> (default, Oct 10 2019, 22:02:15) #012[GCC 8.3.0]
> Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Platform 
> Linux-5.10.52-v7+-armv7l-with-debian-10.10
> Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Locale is 
> 'en_GB.UTF-8'
> Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Using configuration 
> file /home/weewx/weewx.conf
> Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Loading station type 
> Simulator (weewx.drivers.simulator)
> Jul 31 10:17:47 raspberrypi weewx[2241]: engine: StdConvert target 
> unit is 0x1
> Jul 31 10:17:47 raspberrypi weewx[2241]: wxcalculate: The following 
> values will be calculated: barometer=prefer_hardware, 
> windchill=prefer_hardware, dewpoint=prefer_hardware, 
> appTemp=prefer_hardware, rainRate=prefer_hardware, 
> windrun=prefer_hardware, 
> heatindex=prefer_hardware, maxSolarRad=prefer_hardware, 
> humidex=prefer_hardware, pressure=prefer_hardware, 
> inDewpoint=prefer_hardware, ET=prefer_hardware, 
> altimeter=prefer_hardware, 
> cloudbase=prefer_hardware
> Jul 31 10:17:47 raspberrypi weewx[2241]: wxcalculate: The following 
> algorithms will be used for calculations: altimeter=aaNOAA, maxSolarRad=RS
> Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: service version is 0.6
> Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: address=0x03
> Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: bus=1
> Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: indoors=True
> Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: noise_floor=0
> Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: calibration=0x06
> Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: pin=17
> Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: data_binding=None
> Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: binding=archive
> Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Archive will use data 
> binding wx_binding
> Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Record generation 
> will be attempted in 'hardware'
> Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Using archive 
> interval of 300 seconds (specified in weewx configuration)
> Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Using binding 
> 'wx_binding' to database 'weewx.sdb'
> Jul 31 10:17:47 raspberrypi weewx[2241]: manager: Starting backfill of 
> daily summaries
> Jul 31 10:17:47 raspberrypi weewx[2241]: restx: StationRegistry: 
> Registration not requested.
> Jul 31 10:17:47 raspberrypi weewx[2241]: restx: Wunderground: Posting 
> not 

[weewx-user] Re: AcuRite 06045M lightning detector shows constant 12 miles distance when no detected lightning

2021-08-08 Thread Mks Mk
I use this line in weewx.conf and it works ok with seasons skin.. you can 
try it

[StdCalibrate]

[[Corrections]]

lightning_distance = lightning_distance if lightning_strike_count > 
0 else None

On Sunday, August 8, 2021 at 4:09:43 AM UTC+3 gle...@gmail.com wrote:

> I several questions about data and graphing of AcuRite 06045M lightning 
> detector.  I am using "rtl_433" and "rtl_4233 mqtt auto discover" addons in 
> home assistant to aquire data from AcuRite 06045M and  MQTTSubscribeDriver 
> to import data into weewx. Weewx is installed on raspberry pi.I have 
> set up belchertown skin for weewx, added lightning detector count and 
> distance to database and I can graph lightning count and distance using 
> belchertown skin.
>
>  Looking at passing thunderstorm today, I got nice uptick in lighting 
> counts which correlated with decreased lightning distance (fig enclosed).  
>  But the lightning distance reading before the storm and after the storm 
> was a steady 12.0 miles, like that is the default value when no lightning 
> is being detected.  I would like to remove those distracting 12-mile data 
> points, since they don't contribute to the graph.   I was wondering how I 
> [image: 
> Screenshot (9).png]can do that and why lightning distance reading goes to 
> exactly 12 when there is no lightning activity.   
>
> Here is my chart entry in belchertown graphs.conf file:
>
>
>  [[chart5]]
> title = Lightning data
> [[[lightning_distance]]]
>name = Lightning distance
>type = scatter
>lineWidth = 0
>yAxis = 1
>mirrored_value = true
>zIndex = 1
>aggregate_interval = 900 # 15 min
>aggregate_type = avg
>color = "#00ff00"
> [[[lightning_strike_count]]]
>name = Strike count / 15 mins
>type = column
>yAxis_label = "Strikes/15min"
>aggregate_interval = 900 # 15 min
>aggregate_type = sum
>color = "#BECC00"
>tooltip_date_format = " LL"
>
> I use "mirrored_value = true" for lightning distance rendering for two 
> reasons, first as lightning distance decreases there is higher chance of 
> approach thunderstorm (high ~ bad on chart) and second it minimizes the 
> overlay of the lighting strike distance data on the lightning strike 
> count.  
>
> Any ideas why there is a constant 12.0 miles in distance without lightning 
> activity and how can I remove the 12.0 mile values preferably easily.  
>

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/2a08a3cd-cbaa-445e-9e99-0ff588b3a0b1n%40googlegroups.com.


Re: [weewx-user] Re: BME280 Sensor Missing Inside Temp Readings

2021-08-08 Thread Mks Mk
can you try this

[Bme280wx]
i2c_port = 1
i2c_address = 0x76
usUnits = US
pressureKeys = pressure
pressure_must_have = outTemp
humidityKeys = inHumidity
humidity_must_have = outTemp
temperatureKeys = inTemp
temperature_must_have = outTemp

On Sunday, August 8, 2021 at 3:49:48 PM UTC+3 gjr80 wrote:

> OK. Let's put a bit more logging in bme280wx.py, we'll just look at 
> pressure for now. Move aside your existing 
> /usr/share/weewx/user/bme280wx.py by renaming it as bme280wx_orig.py. 
> Download the attached bme280wx.py and save it in it's place in the /
> usr/share/weewx/user directory. Leave debug = 1 and restart WeeWX. Post 
> the log including WeeWX startup and the first half dozen loop packets.
>
> Gary
> On Sunday, 8 August 2021 at 21:47:36 UTC+10 wxwatching wrote:
>
>> Ok, here's the current section from config file:
>>
>> [Engine]
>>
>> # The following section specifies which services should be run and in 
>> what order.
>> [[Services]]
>> prep_services = weewx.engine.StdTimeSynch
>> data_services = user.bme280wx.Bme280wx,
>> process_services = weewx.engine.StdConvert, 
>> weewx.engine.StdCalibrate, weewx.engine.StdQC, 
>> weewx.wxservices.StdWXCalculate
>> xtype_services = weewx.wxxtypes.StdWXXTypes, 
>> weewx.wxxtypes.StdPressureCooker, weewx.wxxtypes.StdRainRater, 
>> weewx.wxxtypes.StdDelta
>> archive_services = weewx.engine.StdArchive
>> restful_services = weewx.restx.StdStationRegistry, 
>> weewx.restx.StdWunderground, weewx.restx.StdPWSweather, 
>> weewx.restx.StdCWOP, weewx.restx.StdWOW, weewx.restx.StdAWEKAS
>> report_services = weewx.engine.StdPrint, weewx.engine.StdReport
>>
>> [Bme280wx]
>> i2c_port = 1
>> i2c_address = 0x76
>> usUnits = US
>> pressureKeys = pressure
>> pressure_must_have = ""
>> humidityKeys = inHumidity
>> humidity_must_have = ""
>> temperatureKeys = inTemp
>> temperature_must_have = ""
>>
>> New problem now is that the loop apparently hangs and WeeWX quits 
>> reporting weather data.
>>
>> sudo weewxd
>> LOOP:   2021-08-08 07:36:29 EDT (1628422589) dateTime: 1628422589, lux: 
>> 13470, maxSolarRad: None, outTempBatteryStatus: 0, radiation: 
>> 106.314127861, rainRate: 0, usUnits: 1, UV: 1, windSpeed: 0.0
>> LOOP:   2021-08-08 07:36:29 EDT (1628422589) dateTime: 1628422589, lux: 
>> 13470, maxSolarRad: None, outTempBatteryStatus: 0, radiation: 
>> 106.314127861, rainRate: 0, usUnits: 1, UV: 1, windSpeed: 0.0
>> LOOP:   2021-08-08 07:36:29 EDT (1628422589) dateTime: 1628422589, lux: 
>> 13470, maxSolarRad: None, outTempBatteryStatus: 0, radiation: 
>> 106.314127861, rainRate: 0, usUnits: 1, UV: 1, windSpeed: 0.0
>> LOOP:   2021-08-08 07:36:39 EDT (1628422599) appTemp: 78.5400076483, 
>> cloudbase: 229.659363466, dateTime: 1628422599, dewpoint: 70.6, heatindex: 
>> 72.06, humidex: 86.4663612495, maxSolarRad: None, outHumidity: 100.0, 
>> outTemp: 70.6, outTempBatteryStatus: 0, rainRate: 0, usUnits: 1, windchill: 
>> 70.6, windSpeed: 0.0
>> LOOP:   2021-08-08 07:36:39 EDT (1628422599) appTemp: 78.5400076483, 
>> cloudbase: 229.659363466, dateTime: 1628422599, dewpoint: 70.6, heatindex: 
>> 72.06, humidex: 86.4663612495, maxSolarRad: None, outHumidity: 100.0, 
>> outTemp: 70.6, outTempBatteryStatus: 0, rainRate: 0, usUnits: 1, windchill: 
>> 70.6, windSpeed: 0.0
>> LOOP:   2021-08-08 07:36:39 EDT (1628422599) appTemp: 78.5400076483, 
>> cloudbase: 229.659363466, dateTime: 1628422599, dewpoint: 70.6, heatindex: 
>> 72.06, humidex: 86.4663612495, maxSolarRad: None, outHumidity: 100.0, 
>> outTemp: 70.6, outTempBatteryStatus: 0, rainRate: 0, usUnits: 1, windchill: 
>> 70.6, windSpeed: 0.0
>> LOOP:   2021-08-08 07:36:49 EDT (1628422609) dateTime: 1628422609, 
>> maxSolarRad: None, outTempBatteryStatus: 0, rain: None, rainRate: 0, 
>> rain_total: 2.07, usUnits: 1, windDir: None, windSpeed: 0.0
>> LOOP:   2021-08-08 07:36:49 EDT (1628422609) dateTime: 1628422609, 
>> maxSolarRad: None, outTempBatteryStatus: 0, rain: 0.0, rainRate: 0, 
>> rain_total: 2.07, usUnits: 1, windDir: None, windSpeed: 0.0
>> LOOP:   2021-08-08 07:36:49 EDT (1628422609) dateTime: 1628422609, 
>> maxSolarRad: None, outTempBatteryStatus: 0, rain: 0.0, rainRate: 0, 
>> rain_total: 2.07, usUnits: 1, windDir: None, windSpeed: 0.0
>>
>> And the output from the syslog is:
>>
>> Aug  8 07:36:23 raspberrypi weewx[2566] INFO __main__: Initializing weewx 
>> version 4.5.1
>> Aug  8 07:36:23 raspberrypi weewx[2566] INFO __main__: Using Python 
>> 2.7.16 (default, Oct 10 2019, 22:02:15) #012[GCC 8.3.0]
>> Aug  8 07:36:23 raspberrypi weewx[2566] INFO __main__: Platform 
>> Linux-5.10.52-v7+-armv7l-with-debian-10.10
>> Aug  8 07:36:23 raspberrypi weewx[2566] INFO __main__: Locale is 
>> 'en_US.UTF-8'
>> Aug  8 07:36:23 raspberrypi weewx[2566] INFO __main__: Using 
>> configuration file /etc/weewx/weewx.conf
>> Aug  8 07:36:23 raspberrypi weewx[2566] INFO __main__: Debug is 1
>> Aug  8 

Re: [weewx-user] Re: BME280 Sensor Missing Inside Temp Readings

2021-08-08 Thread gjr80
OK. Let's put a bit more logging in bme280wx.py, we'll just look at 
pressure for now. Move aside your existing /usr/share/weewx/user/bme280wx.py 
by renaming it as bme280wx_orig.py. Download the attached bme280wx.py and 
save it in it's place in the /usr/share/weewx/user directory. Leave debug = 
1 and restart WeeWX. Post the log including WeeWX startup and the first 
half dozen loop packets.

Gary
On Sunday, 8 August 2021 at 21:47:36 UTC+10 wxwatching wrote:

> Ok, here's the current section from config file:
>
> [Engine]
>
> # The following section specifies which services should be run and in 
> what order.
> [[Services]]
> prep_services = weewx.engine.StdTimeSynch
> data_services = user.bme280wx.Bme280wx,
> process_services = weewx.engine.StdConvert, 
> weewx.engine.StdCalibrate, weewx.engine.StdQC, 
> weewx.wxservices.StdWXCalculate
> xtype_services = weewx.wxxtypes.StdWXXTypes, 
> weewx.wxxtypes.StdPressureCooker, weewx.wxxtypes.StdRainRater, 
> weewx.wxxtypes.StdDelta
> archive_services = weewx.engine.StdArchive
> restful_services = weewx.restx.StdStationRegistry, 
> weewx.restx.StdWunderground, weewx.restx.StdPWSweather, 
> weewx.restx.StdCWOP, weewx.restx.StdWOW, weewx.restx.StdAWEKAS
> report_services = weewx.engine.StdPrint, weewx.engine.StdReport
>
> [Bme280wx]
> i2c_port = 1
> i2c_address = 0x76
> usUnits = US
> pressureKeys = pressure
> pressure_must_have = ""
> humidityKeys = inHumidity
> humidity_must_have = ""
> temperatureKeys = inTemp
> temperature_must_have = ""
>
> New problem now is that the loop apparently hangs and WeeWX quits 
> reporting weather data.
>
> sudo weewxd
> LOOP:   2021-08-08 07:36:29 EDT (1628422589) dateTime: 1628422589, lux: 
> 13470, maxSolarRad: None, outTempBatteryStatus: 0, radiation: 
> 106.314127861, rainRate: 0, usUnits: 1, UV: 1, windSpeed: 0.0
> LOOP:   2021-08-08 07:36:29 EDT (1628422589) dateTime: 1628422589, lux: 
> 13470, maxSolarRad: None, outTempBatteryStatus: 0, radiation: 
> 106.314127861, rainRate: 0, usUnits: 1, UV: 1, windSpeed: 0.0
> LOOP:   2021-08-08 07:36:29 EDT (1628422589) dateTime: 1628422589, lux: 
> 13470, maxSolarRad: None, outTempBatteryStatus: 0, radiation: 
> 106.314127861, rainRate: 0, usUnits: 1, UV: 1, windSpeed: 0.0
> LOOP:   2021-08-08 07:36:39 EDT (1628422599) appTemp: 78.5400076483, 
> cloudbase: 229.659363466, dateTime: 1628422599, dewpoint: 70.6, heatindex: 
> 72.06, humidex: 86.4663612495, maxSolarRad: None, outHumidity: 100.0, 
> outTemp: 70.6, outTempBatteryStatus: 0, rainRate: 0, usUnits: 1, windchill: 
> 70.6, windSpeed: 0.0
> LOOP:   2021-08-08 07:36:39 EDT (1628422599) appTemp: 78.5400076483, 
> cloudbase: 229.659363466, dateTime: 1628422599, dewpoint: 70.6, heatindex: 
> 72.06, humidex: 86.4663612495, maxSolarRad: None, outHumidity: 100.0, 
> outTemp: 70.6, outTempBatteryStatus: 0, rainRate: 0, usUnits: 1, windchill: 
> 70.6, windSpeed: 0.0
> LOOP:   2021-08-08 07:36:39 EDT (1628422599) appTemp: 78.5400076483, 
> cloudbase: 229.659363466, dateTime: 1628422599, dewpoint: 70.6, heatindex: 
> 72.06, humidex: 86.4663612495, maxSolarRad: None, outHumidity: 100.0, 
> outTemp: 70.6, outTempBatteryStatus: 0, rainRate: 0, usUnits: 1, windchill: 
> 70.6, windSpeed: 0.0
> LOOP:   2021-08-08 07:36:49 EDT (1628422609) dateTime: 1628422609, 
> maxSolarRad: None, outTempBatteryStatus: 0, rain: None, rainRate: 0, 
> rain_total: 2.07, usUnits: 1, windDir: None, windSpeed: 0.0
> LOOP:   2021-08-08 07:36:49 EDT (1628422609) dateTime: 1628422609, 
> maxSolarRad: None, outTempBatteryStatus: 0, rain: 0.0, rainRate: 0, 
> rain_total: 2.07, usUnits: 1, windDir: None, windSpeed: 0.0
> LOOP:   2021-08-08 07:36:49 EDT (1628422609) dateTime: 1628422609, 
> maxSolarRad: None, outTempBatteryStatus: 0, rain: 0.0, rainRate: 0, 
> rain_total: 2.07, usUnits: 1, windDir: None, windSpeed: 0.0
>
> And the output from the syslog is:
>
> Aug  8 07:36:23 raspberrypi weewx[2566] INFO __main__: Initializing weewx 
> version 4.5.1
> Aug  8 07:36:23 raspberrypi weewx[2566] INFO __main__: Using Python 2.7.16 
> (default, Oct 10 2019, 22:02:15) #012[GCC 8.3.0]
> Aug  8 07:36:23 raspberrypi weewx[2566] INFO __main__: Platform 
> Linux-5.10.52-v7+-armv7l-with-debian-10.10
> Aug  8 07:36:23 raspberrypi weewx[2566] INFO __main__: Locale is 
> 'en_US.UTF-8'
> Aug  8 07:36:23 raspberrypi weewx[2566] INFO __main__: Using configuration 
> file /etc/weewx/weewx.conf
> Aug  8 07:36:23 raspberrypi weewx[2566] INFO __main__: Debug is 1
> Aug  8 07:36:23 raspberrypi weewx[2566] DEBUG __main__: Initializing engine
> Aug  8 07:36:23 raspberrypi weewx[2566] INFO weewx.engine: Loading station 
> type SDR (user.sdr)
> Aug  8 07:36:23 raspberrypi weewx[2566] INFO user.sdr: driver version is 
> 0.78
> Aug  8 07:36:23 raspberrypi weewx[2566] INFO user.sdr: sensor map is 
> {u'outTempBatteryStatus': u'battery.0222.AcuriteAtlasPacket', u'outTemp': 
> 

Re: [weewx-user] Re: BME280 Sensor Missing Inside Temp Readings

2021-08-08 Thread wxwatching
Ok, here's the current section from config file:

[Engine]

# The following section specifies which services should be run and in 
what order.
[[Services]]
prep_services = weewx.engine.StdTimeSynch
data_services = user.bme280wx.Bme280wx,
process_services = weewx.engine.StdConvert, 
weewx.engine.StdCalibrate, weewx.engine.StdQC, 
weewx.wxservices.StdWXCalculate
xtype_services = weewx.wxxtypes.StdWXXTypes, 
weewx.wxxtypes.StdPressureCooker, weewx.wxxtypes.StdRainRater, 
weewx.wxxtypes.StdDelta
archive_services = weewx.engine.StdArchive
restful_services = weewx.restx.StdStationRegistry, 
weewx.restx.StdWunderground, weewx.restx.StdPWSweather, 
weewx.restx.StdCWOP, weewx.restx.StdWOW, weewx.restx.StdAWEKAS
report_services = weewx.engine.StdPrint, weewx.engine.StdReport

[Bme280wx]
i2c_port = 1
i2c_address = 0x76
usUnits = US
pressureKeys = pressure
pressure_must_have = ""
humidityKeys = inHumidity
humidity_must_have = ""
temperatureKeys = inTemp
temperature_must_have = ""

New problem now is that the loop apparently hangs and WeeWX quits reporting 
weather data.

sudo weewxd
LOOP:   2021-08-08 07:36:29 EDT (1628422589) dateTime: 1628422589, lux: 
13470, maxSolarRad: None, outTempBatteryStatus: 0, radiation: 
106.314127861, rainRate: 0, usUnits: 1, UV: 1, windSpeed: 0.0
LOOP:   2021-08-08 07:36:29 EDT (1628422589) dateTime: 1628422589, lux: 
13470, maxSolarRad: None, outTempBatteryStatus: 0, radiation: 
106.314127861, rainRate: 0, usUnits: 1, UV: 1, windSpeed: 0.0
LOOP:   2021-08-08 07:36:29 EDT (1628422589) dateTime: 1628422589, lux: 
13470, maxSolarRad: None, outTempBatteryStatus: 0, radiation: 
106.314127861, rainRate: 0, usUnits: 1, UV: 1, windSpeed: 0.0
LOOP:   2021-08-08 07:36:39 EDT (1628422599) appTemp: 78.5400076483, 
cloudbase: 229.659363466, dateTime: 1628422599, dewpoint: 70.6, heatindex: 
72.06, humidex: 86.4663612495, maxSolarRad: None, outHumidity: 100.0, 
outTemp: 70.6, outTempBatteryStatus: 0, rainRate: 0, usUnits: 1, windchill: 
70.6, windSpeed: 0.0
LOOP:   2021-08-08 07:36:39 EDT (1628422599) appTemp: 78.5400076483, 
cloudbase: 229.659363466, dateTime: 1628422599, dewpoint: 70.6, heatindex: 
72.06, humidex: 86.4663612495, maxSolarRad: None, outHumidity: 100.0, 
outTemp: 70.6, outTempBatteryStatus: 0, rainRate: 0, usUnits: 1, windchill: 
70.6, windSpeed: 0.0
LOOP:   2021-08-08 07:36:39 EDT (1628422599) appTemp: 78.5400076483, 
cloudbase: 229.659363466, dateTime: 1628422599, dewpoint: 70.6, heatindex: 
72.06, humidex: 86.4663612495, maxSolarRad: None, outHumidity: 100.0, 
outTemp: 70.6, outTempBatteryStatus: 0, rainRate: 0, usUnits: 1, windchill: 
70.6, windSpeed: 0.0
LOOP:   2021-08-08 07:36:49 EDT (1628422609) dateTime: 1628422609, 
maxSolarRad: None, outTempBatteryStatus: 0, rain: None, rainRate: 0, 
rain_total: 2.07, usUnits: 1, windDir: None, windSpeed: 0.0
LOOP:   2021-08-08 07:36:49 EDT (1628422609) dateTime: 1628422609, 
maxSolarRad: None, outTempBatteryStatus: 0, rain: 0.0, rainRate: 0, 
rain_total: 2.07, usUnits: 1, windDir: None, windSpeed: 0.0
LOOP:   2021-08-08 07:36:49 EDT (1628422609) dateTime: 1628422609, 
maxSolarRad: None, outTempBatteryStatus: 0, rain: 0.0, rainRate: 0, 
rain_total: 2.07, usUnits: 1, windDir: None, windSpeed: 0.0

And the output from the syslog is:

Aug  8 07:36:23 raspberrypi weewx[2566] INFO __main__: Initializing weewx 
version 4.5.1
Aug  8 07:36:23 raspberrypi weewx[2566] INFO __main__: Using Python 2.7.16 
(default, Oct 10 2019, 22:02:15) #012[GCC 8.3.0]
Aug  8 07:36:23 raspberrypi weewx[2566] INFO __main__: Platform 
Linux-5.10.52-v7+-armv7l-with-debian-10.10
Aug  8 07:36:23 raspberrypi weewx[2566] INFO __main__: Locale is 
'en_US.UTF-8'
Aug  8 07:36:23 raspberrypi weewx[2566] INFO __main__: Using configuration 
file /etc/weewx/weewx.conf
Aug  8 07:36:23 raspberrypi weewx[2566] INFO __main__: Debug is 1
Aug  8 07:36:23 raspberrypi weewx[2566] DEBUG __main__: Initializing engine
Aug  8 07:36:23 raspberrypi weewx[2566] INFO weewx.engine: Loading station 
type SDR (user.sdr)
Aug  8 07:36:23 raspberrypi weewx[2566] INFO user.sdr: driver version is 
0.78
Aug  8 07:36:23 raspberrypi weewx[2566] INFO user.sdr: sensor map is 
{u'outTempBatteryStatus': u'battery.0222.AcuriteAtlasPacket', u'outTemp': 
u'temperature.0222.AcuriteAtlasPacket', u'outHumidity': 
u'humidity.0222.AcuriteAtlasPacket', u'windSpeed': 
u'wind_speed.0222.AcuriteAtlasPacket', u'windDir': 
u'wind_dir.0222.AcuriteAtlasPacket', u'UV': u'uv.0222.AcuriteAtlasPacket', 
u'rain_total': u'rain_total.0222.AcuriteAtlasPacket', u'radiation': 
u'lux.0222.AcuriteAtlasPacket', u'strikes_total': 
u'strike_count.0222.AcuriteAtlasPacket', u'strike_distance': 
u'strike_distance.0222.AcuriteAtlasPacket', u'lux': 
u'lux.0222.AcuriteAtlasPacket', u'log_unknown_sensors': u'True', 
u'log_unmapped_sensors': u'True'}
Aug  8 07:36:23 raspberrypi weewx[2566] INFO user.sdr: deltas is {u'rain': 
u'rain_total', 

[weewx-user] Re: Trying to gee AS3935 to work with weewx 4.5.1

2021-08-08 Thread ian.r...@gmail.com
I think I have found the remaining Python 2 issue - 2to3 didnt find it when 
I tried

In as3935.py on line 73 change from:

from RPi_AS3935 import RPi_AS3935

to:

from RPi_AS3935.RPi_AS3935 import RPi_AS3935

Seems to be related to the situation discussed here
https://stackoverflow.com/questions/4534438/typeerror-module-object-is-not-callable
On Saturday, 7 August 2021 at 02:06:07 UTC+12 philip@gmail.com wrote:

> Lightning all round today but the only log entries were when the lightning 
> was over head 7 in total
> as3935: strike at 1.0 km
> Calibration = 6 , changed to 2 didn't seem to make any difference
> Storms now gone and still not sure if the dfrobot works that well
>
>
>
> On Saturday, July 31, 2021 at 1:06:06 PM UTC+1 philip@gmail.com wrote:
>
>> In the as3935.py I noticed for LOOP working I have to put that in the 
>> weewx.conf file which then showed lightning_strikes = 0
>> When checking the weewx.sdb it didnt have a lightning_strikes field its 
>> called lightning_strikes_count
>> When I added lighnting_strikes it now has a zero (0) in. 
>> So has the field names changed ??
>> The test will be when I get any lightning I shall keep you posted.
>>
>>
>> On Saturday, July 31, 2021 at 12:59:38 PM UTC+1 philip@gmail.com 
>> wrote:
>>
>>> In the as3935.py
>>>
>>> On Saturday, July 31, 2021 at 10:45:17 AM UTC+1 philip@gmail.com 
>>> wrote:
>>>
 Thanks Doug but it didnt make any difference
 As Im trying to use a DFRobot AS3935 I started again but this time on 
 Python2
 The i2cdetect -y 1 shows 03 show it appears the Raspberry Pi can see 
 the AS3935
 Using the simulator driver weewx now starts
 Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Initializing weewx 
 version 3.9.2
 Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Using Python 2.7.16 
 (default, Oct 10 2019, 22:02:15) #012[GCC 8.3.0]
 Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Platform 
 Linux-5.10.52-v7+-armv7l-with-debian-10.10
 Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Locale is 'en_GB.UTF-8'
 Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Using configuration 
 file /home/weewx/weewx.conf
 Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Loading station type 
 Simulator (weewx.drivers.simulator)
 Jul 31 10:17:47 raspberrypi weewx[2241]: engine: StdConvert target unit 
 is 0x1
 Jul 31 10:17:47 raspberrypi weewx[2241]: wxcalculate: The following 
 values will be calculated: barometer=prefer_hardware, 
 windchill=prefer_hardware, dewpoint=prefer_hardware, 
 appTemp=prefer_hardware, rainRate=prefer_hardware, 
 windrun=prefer_hardware, 
 heatindex=prefer_hardware, maxSolarRad=prefer_hardware, 
 humidex=prefer_hardware, pressure=prefer_hardware, 
 inDewpoint=prefer_hardware, ET=prefer_hardware, altimeter=prefer_hardware, 
 cloudbase=prefer_hardware
 Jul 31 10:17:47 raspberrypi weewx[2241]: wxcalculate: The following 
 algorithms will be used for calculations: altimeter=aaNOAA, maxSolarRad=RS
 Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: service version is 0.6
 Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: address=0x03
 Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: bus=1
 Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: indoors=True
 Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: noise_floor=0
 Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: calibration=0x06
 Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: pin=17
 Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: data_binding=None
 Jul 31 10:17:47 raspberrypi weewx[2241]: as3935: binding=archive
 Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Archive will use data 
 binding wx_binding
 Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Record generation will 
 be attempted in 'hardware'
 Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Using archive interval 
 of 300 seconds (specified in weewx configuration)
 Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Using binding 
 'wx_binding' to database 'weewx.sdb'
 Jul 31 10:17:47 raspberrypi weewx[2241]: manager: Starting backfill of 
 daily summaries
 Jul 31 10:17:47 raspberrypi weewx[2241]: restx: StationRegistry: 
 Registration not requested.
 Jul 31 10:17:47 raspberrypi weewx[2241]: restx: Wunderground: Posting 
 not enabled.
 Jul 31 10:17:47 raspberrypi weewx[2241]: restx: PWSweather: Posting not 
 enabled.
 Jul 31 10:17:47 raspberrypi weewx[2241]: restx: CWOP: Posting not 
 enabled.
 Jul 31 10:17:47 raspberrypi weewx[2241]: restx: WOW: Posting not 
 enabled.
 Jul 31 10:17:47 raspberrypi weewx[2241]: restx: AWEKAS: Posting not 
 enabled.
 Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Starting up weewx 
 version 3.9.2
 Jul 31 10:17:47 raspberrypi weewx[2241]: engine: Clock error is -0.20 
 seconds (positive is fast)
 Jul 31 10:17:47