On Monday, March 16, 2020 at 4:31:08 PM UTC-4, Geoff Harris wrote:
>
> My recollection is that abnormal code 4 is when it can't connect to the 
> USB. I can replicate the error by stopping weewx, unplugging the USB and 
> starting it back up. 
>
>>
>>
geoff,

if this is just a startup issue, then you might want to try the 
loop_on_init option.

the normal startup behavior for weewx is to exit if it does not find the 
resources that it needs to operate.  this is to make it easier to 
debug/diagnose when you are invoking weewx directly.

these resources might be the usb, a sane time (from ntpd or whatever), 
networking, database server, etc.

when running weewx as a daemon, there are often cases where these other 
resources are not ready.  typically you would use the system's init 
dependencies to ensure availability.  however, sometimes that is not 
possible.

when loop_on_init=true then weewx will loop continually instead of exiting.

the log should tell you whether this will help - in your case, you should 
see a driver warning/error when it cannot find the usb.

if you see such a warning/failure repeatedly (not just at startup), then 
there is probably something funky with your usb.  KeepAlive will restart 
weewx for you, but it won't fix the problem.

if you see such a warning only once (just at startup), then there is 
probably nothing wrong with weewx or your usb, just timing.  loop_on_init 
should solve that.

we are pretty hard-nosed about the 'just reboot to fix it' and the 
keepalive or nanny script approaches to keep weewx running.  we would much 
rather fix the problems instead of applying layer after layer of band-aid.

m

-- 
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/645b18d1-03da-4f0d-a802-8d001ed2d1c1%40googlegroups.com.

Reply via email to