Weewx uses Unix Epoch Time <https://en.wikipedia.org/wiki/Unix_time>, which
is basically UTC. The fields dateTime in the databases are also in Unix
Epoch Time.

However, most of the plots and reports are done in local time. This means
there is a lot of code dedicated to switching back and forth under various
scenarios.

Looking at other drivers is a great way to learn how to write one. The
fileparse driver is a good place to start because it is so simple. The
Customization guide also has some tips
<http://weewx.com/docs/customizing.htm#porting>.

-tk

On Tue, Jan 24, 2017 at 3:24 PM, <[email protected]> wrote:

> Hopefully this is a dumb question, but are the time for DB records for
> sensor readings in UTC or local time?
> I was playing with time conversions in python and noticed the difference
> and now not
> sure what weewx is doing.
>
> Follow-on question; I'm working on a driver for some alternate sensors
> (not exactly weather) that come in over
> a tcp/ip socket (not intercepter, but similar and more simple since I
> control both ends of the conversation :^).
> I'm assuming I can figure out what that all looks like from the other
> drivers and the Customization docs?
> I'll have to add some value types to the DB.
>
> Thx, Chris
>
>
>

Reply via email to