No data in outputs

26 weergaven
Naar het eerste ongelezen bericht

Graham Harris

ongelezen,
14 jan 2021, 04:29:4614-01-2021
aan pywws
Sorry, but I have searched high and low for an answer...
pywws appears to be running fine, and I have raw data being logged like this:
2021-01-14 08:00:54,5,65,21.9,,,874.1,,,,0,64
2021-01-14 08:05:54,5,65,21.8,,,874.2,,,,0,64
2021-01-14 08:10:54,5,65,21.7,,,874.2,,,,0,64
disconcertingly, the dates/times are not in my timezone (NZ Daylight Saving) even though the station is set to timezone -12 and the attached linux OS is set up correctly.

But the real problem is that no data is making it through to the output files. I get perfectly formed graphs, but with no data lines. And html-formed text output, with nothing between <td> and </td>

In weather.ini I have 
templates = /mnt/data/weather/templates/
graph_templates = /mnt/data/weather/graph_templates/

The files in  /mnt/data/weather/templates/ and /mnt/data/weather/graph_templates/ are copies of the templates included in the distribution package (20.1.0, installed with pip3 --user but otherwise as at https://pywws.readthedocs.io/en/latest/guides/getstarted.html). I have given the copied templates new names, which are listed in weather.ini and the output files' names match the templates I have named.  Since I am not using an outside sensor, I have edited the templates to use temp_in and hum_in instead of the _out variants.

There is probably something very simple I am doing wrong- but lots of hours in, I haven't spotted it. Can anyone please lead me to it?

Thanks
Graham

Jim Easterbrook

ongelezen,
14 jan 2021, 04:33:5214-01-2021
aan py...@googlegroups.com
On 14/01/2021 09:07, Graham Harris wrote:
> Sorry, but I have searched high and low for an answer...
> pywws appears to be running fine, and I have raw data being logged like
> this:
> 2021-01-14 08:00:54,5,65,21.9,,,874.1,,,,0,64
> 2021-01-14 08:05:54,5,65,21.8,,,874.2,,,,0,64
> 2021-01-14 08:10:54,5,65,21.7,,,874.2,,,,0,64

The 64 at the end is the status value. It shows your console is not
receiving data from the outside sensors. You should see the decoded
status in your log files every time it changes or when pywws starts.

> disconcertingly, the dates/times are not in my timezone (NZ Daylight
> Saving) even though the station is set to timezone -12 and the attached
> linux OS is set up correctly.

The stored data uses UTC timestamps. Using local time would cause
problems around the start and end of DST - the data would be unsortable.

> But the real problem is that no data is making it through to the output
> files. I get perfectly formed graphs, but with no data lines. And
> html-formed text output, with nothing between <td> and </td>

Because you have no data.

--
Jim Easterbrook <http://www.jim-easterbrook.me.uk/>

Graham Harris

ongelezen,
14 jan 2021, 13:37:3514-01-2021
aan pywws
Thank you Jim, that is very helpful ... but ...

I am not sure you considered the later notes in my message where I said that I changed the template copies to use temp_in etc instead of temp_out. Surely this would put the data that we are seeing in the raw file into the output?

It's probably my lack of understanding of how templates work. I have not yet found the documentation for templates. Could you lead me to that please and I can probably sort myself out.

Thanks
Graham

Jim Easterbrook

ongelezen,
14 jan 2021, 13:50:2714-01-2021
aan py...@googlegroups.com
On 14/01/2021 18:37, Graham Harris wrote:
>
> I am not sure you considered the later notes in my message where I said
> that I changed the template copies to use temp_in etc instead of
> temp_out. Surely this would put the data that we are seeing in the raw
> file into the output?

Ah, you're right I missed that. I was not firing on all cylinders this
morning. You can test templates directly from the command line, e.g.

python3 -m pywws.template data_dir template_file output_file

(No need to stop pywws while you do this.)

> It's probably my lack of understanding of how templates work. I have not
> yet found the documentation for templates. Could you lead me to that
> please and I can probably sort myself out.
The documentation is here:
https://pywws.readthedocs.io/en/latest/api/pywws.template.html

I suggest starting with something simple (perhaps just output the
current temperature) to see if you can get anything working, then build
up from there.

Graham Harris

ongelezen,
14 jan 2021, 14:22:1614-01-2021
aan pywws
Brilliant, thanks Jim. Hopefully up & flying soon!
Allen beantwoorden
Auteur beantwoorden
Doorsturen
0 nieuwe berichten