Hi,
I want to import data from a netatmo station into the weewx database. Weewx
Version is 5.2 with sqlite database.
I used for import:
weectl import --import-config=/etc/weewx/tmp/import.conf --verbose
The import works so far, but when I look in the database I found a missing
value for the first Rain value. All other values in the first row are OK,
also all values in the following rows. Only the first Rain value is zero
but should be 1,8 inch!? Rebuilding the database has no effect.
The csv-file is:
datetime,Pressure,Temp,Humidity,WindAngle,Wind,Gust,GustAngle,Rain
2025/01/01 12:00:00,998.6,7.3,97,211,29,121,227,46.5
2025/01/02 12:00:00,1004.9,2.7,87,242,7,40,304,0.1
2025/01/03 12:00:00,1007.8,0.4,89,243,9,40,232,0.2
2025/01/04 12:00:00,1013.9,-0.4,95,218,11,33,227,0.7
.....
This is the database query:
echo "select
datetime(dateTime,'unixepoch','localtime'),windSpeed,barometer,rain from
archive WHERE dateTime>unixepoch('2025-01-01 00:00:00', 'utc') ORDER BY
rowid ASC LIMIT 31;" | sqlite3 /var/lib/weewx/weewx.sdb
(last value in the first row should not be zero)
2025-01-01 12:00:00|18.0198093628444|29.4886455175|0.0
2025-01-02 12:00:00|4.34960915654865|29.67468443875|0.00393700787401575
2025-01-03 12:00:00|5.59235462984826|29.7603214025|0.00393700787401575
2025-01-04 12:00:00|6.83510010314787|29.94045432625|0.0196850393700787
The conf file is:
source = CSV
[CSV]
file = /etc/weewx/tmp/import_01_25.txt
raw_datetime_format = %Y/%m/%d %H:%M:%S
calc_missing = True
ignore_invalid_data = True
solar_sensor = False
UV_sensor = False
interval = derive
delimiter = ','
qc = False
[[FieldMap]]
[[[dateTime]]]
source_field = datetime
unit = unix_epoch
[[[outTemp]]]
source_field = Temp
unit = degree_C
[[[outHumidity]]]
source_field = Humidity
unit = percent
[[[windSpeed]]]
source_field = Wind
unit = km_per_hour
[[[windDir]]]
source_field = WindAngle
unit = degree_compass
[[[windGust]]]
source_field = Gust
unit = km_per_hour
[[[windGustDir]]]
source_field = GustAngle
unit = degree_compass
[[[barometer]]]
source_field = Pressure
unit = mbar
[[[rain]]]
source_field = Rain
unit = mm
is_cumulative = True
Whats going wrong there?
Thanks for help
Frank
--
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].
To view this discussion visit
https://groups.google.com/d/msgid/weewx-user/7b0df795-91c0-4542-9a49-6ce7c53e7c29n%40googlegroups.com.