My fineOffset weather station loses connection sometimes when lightening is
around.
I check this parameter.
rxCheckPercent 100.0
If it is not 100.0 then it has dropped off and then I have a normally
closed switch in the USB 5V line and I make the home automation turn it on
so the 5V drops and that resets the console.
It is in the weewx database as well.
I have the below in a bash script which I run via cron
RXCHECK=$(mysql --batch --column-names=0 -uweewx -pweewx --database=weewx
--execute="select rxCheckPercent from archive WHERE dateTime=(select
MAX(dateTime) from archive); ");
RXCHECK=`echo $RXCHECK | awk '{printf("%.1f", $1)}'`
echo $RXCHECK
I don't know if that helps you or not but it works in my case.
Cheers
On Sunday, 7 April 2019 21:12:25 UTC+10, Pietro Benotto wrote:
>
> Hello everyone, I hope this discussion is in the right group.
> I have a PCE-FWS 20 connected to a RaspberryPI with weewx.
> Sometimes during stormy days, the connection between the console and the
> weather station breaks.
> I noticed that it is sufficient to restart the console in order to
> re-establish the connection, but I'd like this operation was made
> automatically.
> I found a small program that it's able to interrupt the supply to the USB,
> so I'm able to switch-off and switch-on the console from the Raspberry.
> What I want to do now is make a check up on data from the weather station
> and if outHumidity, outTemp and Wind are all "None" (or N/A or 0, really
> I'm not sure what weewx "see" if there is no connection to a sensor) then
> I'd like the restart-console-program started.
> What I'm not able to do is make this control. It would be easy if I could
> use tags in PY programs, but they are only available from the templates
> because I understood they are not simple variables.
> So I need to have access to the current condition of the sensors from a
> python program.
> Could someone help me?
>
> 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].
For more options, visit https://groups.google.com/d/optout.