Hi Glenn
so I use weewx 3.7.1 and meso 0.4.0 with raw_0.4.1-lh.py.
But my section of def newLoop Packet looks different
def newLoopPacket(self, event):
packet = event.packet
prune_period = 300
# It's possible for records with duplicate dateTimes - this occurs
when an archive packet
# is processed since the LOOP packets are queued up and then
returned immediately when
# looping resumes, coupled with the fact that for Vantage Pro
consoles the dateTime value is
# added by weewx. So, for database storage, skip the duplicates
until we get a new one to
# avoid a duplicate key error, but publish them all to redis
regardless.
dateTime = packet['dateTime']
if dateTime != self.lastLoopDateTime:
self.dbm.addRecord(packet)
self.lastLoopDateTime = dateTime
if dateTime > (self.lastPrunedDateTime + prune_period):
if self.dataLimit is not None:
ts = ((dateTime - (self.dataLimit * 3600)) / prune_period)
* prune_period # preset on 5-min boundary
self.prune_rawdata(self.dbm, ts, 2, 5)
self.lastPrunedDateTime = dateTime
but this is not my main problem :-)
If I start index-example the come tools tell me this errors :
Element could not be found for fieldId: dayRain
meso.MesoConsole.MesoConsole._initializeFieldValueDisplayManager @
MesoConsole.js:69
(anonymous) @ MesoConsole.js:18
MesoConsole @ MesoConsole.js:16
MesoWxConsole @ MesoWxConsole.js:7
MesoWxApp.start @ MesoWxApp.js:20
(anonymous) @ index-example.html:32
l @ jquery-2.0.3.min.js:4
fireWith @ jquery-2.0.3.min.js:4
ready @ jquery-2.0.3.min.js:4
S @ jquery-2.0.3.min.js:4
AbstractHighstockChart.js:314 Uncaught TypeError: Cannot read property
'getData' of undefined
at
RawChart.meso.AbstractHighstockChart.AbstractHighstockChart._loadInitialDataAndCreate
(AbstractHighstockChart.js:314)
at RawChart.meso.AbstractHighstockChart.AbstractHighstockChart._create
(AbstractHighstockChart.js:307)
at RawChart.AbstractHighstockChart (AbstractHighstockChart.js:121)
at new RawChart (RawChart.js:29)
at createTodayChart (MesoWxApp.js:52)
at selectChart (MesoWxApp.js:45)
at MesoWxApp.start (MesoWxApp.js:28)
at HTMLDocument.<anonymous> (index-example.html:32)
at l (jquery-2.0.3.min.js:4)
at Object.fireWith [as resolveWith] (jquery-2.0.3.min.js:4)
meso.AbstractHighstockChart.AbstractHighstockChart._loadInitialDataAndCreate
@ AbstractHighstockChart.js:314
meso.AbstractHighstockChart.AbstractHighstockChart._create @
AbstractHighstockChart.js:307
AbstractHighstockChart @ AbstractHighstockChart.js:121
RawChart @ RawChart.js:29
createTodayChart @ MesoWxApp.js:52
selectChart @ MesoWxApp.js:45
MesoWxApp.start @ MesoWxApp.js:28
(anonymous) @ index-example.html:32
l @ jquery-2.0.3.min.js:4
fireWith @ jquery-2.0.3.min.js:4
ready @ jquery-2.0.3.min.js:4
S @ jquery-2.0.3.min.js:4
jquery-2.0.3.min.js:6 GET
http://192.168.1.17/Wetter/mesowx/web/meso/data.php?entity_id=weewx_raw&data=outTemp%3A%3Ac%3A%2Cdewpoint%3A%3Ac%3A%2CrainRate%3A%3AmmHr%3A%2CoutHumidity%3A%3Aperc%3A%2Cheatindex%3A%3Ac%3A%2Cwindchill%3A%3Ac%3A%2Cbarometer%3A%3Amb%3A%2CdateTime%3A%3Ams%3A%2CwindDir%3A%3Adeg%3A%2CwindSpeed%3A%3Akph%3A%2C&order=desc&limit=1
500 (Internal Server Error)
send @ jquery-2.0.3.min.js:6
ajax @ jquery-2.0.3.min.js:6
x.(anonymous function) @ jquery-2.0.3.min.js:6
getJSON @ jquery-2.0.3.min.js:6
meso.AggregateDataProvider.AggregateDataProvider.getData @
AggregateDataProvider.js:13
meso.PollingRealTimeRawDataProvider.PollingRealTimeRawDataProvider._poll @
PollingRealTimeRawDataProvider.js:44
(anonymous) @ meso.js:14
setTimeout (async)
meso.PollingRealTimeRawDataProvider.PollingRealTimeRawDataProvider._schedulePoll
@ PollingRealTimeRawDataProvider.js:40
meso.PollingRealTimeRawDataProvider.PollingRealTimeRawDataProvider._poll @
PollingRealTimeRawDataProvider.js:52
PollingRealTimeRawDataProvider @ PollingRealTimeRawDataProvider.js:19
(anonymous) @ Config.js:82
(anonymous) @ Config.js:678
MesoWxApp.js:14 An unexpected error occurred during and HTTP request (3)
[{…}, "error", "Internal Server Error", callee: ƒ, Symbol(Symbol.iterator):
ƒ]
I think i have a problem with my databases....???
Am Mittwoch, 11. Oktober 2017 00:41:13 UTC+2 schrieb Glenn McKechnie:
>
> Hi Hajo,
>
> On 10 October 2017 at 21:58, Hajo Harms <[email protected] <javascript:>>
> wrote:
>
>> Hi Glenn
>> thanks for response. My english is basic, so some information will be
>> lost in translation....
>>
>
> Your english is fine.
>
> I'm still curious, but only if you remember. What version of weewx was
> your last version and were you using Luc's raw.py with that (
> raw_0.4.x-lh.py from the linked weewx-user thread), or was it the
> original that came with mesowx?
>
>
>> I have changed the StdQC.. barometer. So no more over/underflow... :-)
>>
>
> Yes, That's good. That means the Davis driver is fine! (Phew!) :-))
>
> And was the original missing the units entry on that line?
>
>
>> Tha database meso is only for one day, correct ? Because the datavolume...
>>
>
> 24 hours by default. That matches the time span for the 24-hour graphs.
>
> The [Raw] section in your weewx.conf file has the following
>
> # The max amount of raw data to retain specified in hours (set to 0 to
> retain all data)
> # This will in effect keep a rolling window of the data removing old
> data based on·
> # the time of the most recent record. It is recommended to set this to
> at least 24.
> #
> # NOTE: if increasing this value (or setting to unlimited), keep in
> mind that raw data·
> # may consume VERY large amounts of space!
> data_limit = 24
>
> Once it's been running for a while (data_limit) you'll see the following
> style of message every 5 minutes, that's raw.py cleaning up the old data.
>
> raw: deleted rawdata prior to 2017-09-27 08:10:00 AEST (1506463800)
>
>>
>> The other thing is, my NAS is near by, so i have many noise (writing
>> ervery 2 sec).. I think 5 or 10 sec will be also ok ?
>> Or is there a way to cache the data?
>>
>
> Nothing simple that I know of, however.
>
> Looking at the code (in my case that's raw_0.4.1-lh.py, around line 128)
> , you could tweak the time value in
>
> def newLoopPacket(self, event):
> [...]
> if dateTime > (self.lastLoopDateTime + 2):
>
> where that last figure, 2 refers to seconds. If you change that value to
> 10
>
> if dateTime > (self.lastLoopDateTime + 10):
>
> then it should ignore anything falling within that 10 second span. You'll
> get the timestamps that are > 10 seconds apart and the ones in-between will
> not make it into the database.
> And, I've just tested it on mine and that appears to work.
>
> If you go down this path, save a copy of the file first, then make your
> edits to the working copy. Better safe than sorry.
>
> After those edits, you'll need to restart weewx
>
> /etc/init.d/weewx restart
>
>
>>
>> And what's the different between pressure and barometer ?
>>
>>
> Probably best to visit the docs for that one.
>
> http://www.weewx.com/docs/usersguide.htm#Meteorological_problems
>
> and I'll go and read the MinMax section
>
> http://www.weewx.com/docs/usersguide.htm#StdQC
>
>
>
>> I have a Vantage pro 2 plus and a Qnap Nas 219P++
>>
>> thanks for all the response :-)
>>
>
> :-))
>
>
>> Hajo
>>
>>
> Cheers
> Glenn
>
> rorpi - read only raspberry pi & various weewx addons
> https://github.com/glennmckechnie
>
>
--
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.