Be careful here, for most observations the default avg extractor function is appropriate (that's why it is the default) as the extracted value is a representation of the observation over the entire archive period. The majority of observations handled by a default WeeWX install (ie outTemp, barometer, radiation etc) use the avg extractor function. The last extractor function is typically used for extensive observations such as day rainfall or perhaps a sensor state observation such as signal level that is either 0 or 1 where the latest value is of interest.
Ultimately though it is personal choice. Gary On Tuesday 9 January 2024 at 06:30:23 UTC+10 [email protected] wrote: > 1. There are defaults and you only have to configure any settings that you > want to be different. So in your example you would only have to override > the extractor. > [Accumulator] > ... > [[XField]] > extractor = last > > 2. I don’t know the answer, but they have a different meaning. See, > http://www.weewx.com/docs/4.10/devnotes.htm#value_None. > > If you are adding new observations be sure to read up on units and > unit_groups, > http://www.weewx.com/docs/4.10/customizing.htm#customizing_units. > > On Sunday 7 January 2024 at 04:34:28 UTC-5 Remy Lavabre wrote: > >> Thank you for the answer ! Perfect... >> >> Only two questions still bothers me: >> >> - 1/ I added an “XField” field to my weewx.sdb database. This XField >> corresponds to a simple parameter such as temperature or pressure. It is >> incorporated into the "PacketsLoop". >> >> Do we absolutely have to declare [Accumulator] in weewx.sdb as follows: >> >> >> >> >> >> >> >> *[Accumulator] ... [[XField]] accumulator = scalar >> adder = add merger = minmax extractor = last* >> >> or are there default parameters in weewx in a (new) field of unknown type >> in a database? >> >> >> - 2/ Concerning "PacketsLoop": the weewx documentation stipulates that >> they can be complete (all fields in the database) or partial. >> >> But are the two PacketsLoops below interpreted in the same way? >> >> data1 = {'dateTime': mydatetime, 'usUnits': 'METRIC', 'outTemp': '31',* >> 'outHumidity': None*, 'dewpoint': '28'} >> data2 = {'dateTime': mydatetime, 'usUnits': 'METRIC', 'outTemp': '31', >> 'dewpoint': '28'} >> >> Thank you for your help - Kind regards >> >> Le samedi 6 janvier 2024 à 22:34:41 UTC+1, [email protected] a écrit : >> >>> check out, https://github.com/weewx/weewx/wiki/Accumulators >>> >>> On Saturday 6 January 2024 at 10:27:48 UTC-5 Remy Lavabre wrote: >>> >>>> Good morning, >>>> >>>> Wishing to write a driver for WeeWX in order to automatically retrieve >>>> and integrate AWEKAS data into the weewx.sbd database, I have a question >>>> regarding the management of "PacketsLoop" data: >>>> >>>> The Weewx documentation states that for temperatures, it is an average >>>> of the "packetsloop" received during the time period set in weewx.conf >>>> (300 >>>> seconds for example), that for rain it is the maximum of packetsloop. -> OK >>>> >>>> But for the other data? What about it? >>>> >>>> If we add personal fields to the database, such as electricity >>>> consumption. What will be the value of this field in the database -> An >>>> average of packets received, the maximum value, the last? >>>> >>>> And is it possible to specify to wewx (and if so where and how...), >>>> what type of result we want to have with the aggregation of a field from >>>> several loop packets? >>>> >>>> thank you >>>> >>> -- 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 on the web visit https://groups.google.com/d/msgid/weewx-user/9fc3151e-9d2c-4705-b125-afcce340b246n%40googlegroups.com.
