This is definitely a bug. Weewx may not be able to read from the station,
but it should never crash.

Matthew is the FO expert. It looks to me the most likely culprit is that
the 'read_period' key in the fixed block was None for some reason.

Matthew?

-tk

On Sun, Sep 18, 2016 at 2:24 AM, Macha <nougueir...@gmail.com> wrote:

> Hello,
>
> It's me again ....
>
> I don't know if this helps in understanding FO USB lockups (just ignore if
> not ... )
>
> I have a W1080-type station (actually marked "WEA22") connected to a RPi
> V2. The station console is connected directly to the RPi's USB, together
> with 2 webcams.
>
> From time to time (twice a week about) I get what could be described as a
> "lockout" where weewx can't get data from the console. It always starts
> with syslog showing ...
>
> Sep 18 10:57:53 meteopi weewx[13587]: fousb: get_observations failed: bad
> pointer: 0x0000
> Sep 18 10:57:53 meteopi weewx[13587]: engine: Shutting down StdReport
> thread
> Sep 18 10:57:53 meteopi weewx[13587]: engine: Caught WeeWxIOError: Max
> retries exceeded while fetching observations
> Sep 18 10:57:53 meteopi weewx[13587]:     ****  Waiting 60 seconds then
> retrying...
>
> I then get ...
>
> Sep 18 10:58:53 meteopi weewx[13587]: engine: retrying...
> Sep 18 10:58:53 meteopi weewx[13587]: engine: Using configuration file
> /home/weewx-3.5.0/weewx.conf
> Sep 18 10:58:53 meteopi weewx[13587]: engine: Loading station type
> FineOffsetUSB (weewx.drivers.fousb)
> Sep 18 10:58:53 meteopi weewx[13587]: fousb: driver version is 1.8
> Sep 18 10:58:53 meteopi weewx[13587]: fousb: polling mode is PERIODIC
> Sep 18 10:58:53 meteopi weewx[13587]: fousb: polling interval is 60
> Sep 18 10:58:53 meteopi weewx[13587]: fousb: found station on USB bus=001
> device=006
> Sep 18 10:58:53 meteopi weewx[13587]: engine: StdConvert target unit is 0x1
> Sep 18 10:58:53 meteopi weewx[13587]: wxcalculate: The following values
> will be calculated: barometer=prefer_hardware,windchill=prefer_hardware,
> dewpoint=prefer_hardware,appTemp=prefer_hardware,rainRate=prefer_hardware,
> windrun=prefer_hardware,heatindex=prefer_hardware,
> maxSolarRad=prefer_hardware,humidex=prefer_hardware,
> pressure=prefer_hardware,inDewpoint=prefer_hardware,ET=
> prefer_hardware,altimeter=prefer_hardware,cloudbase=prefer_hardware
> Sep 18 10:58:53 meteopi weewx[13587]: wxcalculate: The following
> algorithms will be used for calculations: altimeter=aaNOAA,maxSolarRad=RS
> Sep 18 10:58:53 meteopi weewx[13587]: engine: Archive will use data
> binding wx_binding
> Sep 18 10:58:53 meteopi weewx[13587]: engine: Record generation will be
> attempted in 'software'
> Sep 18 10:58:53 meteopi weewx[13587]: fousb: unstable read: blocks differ
> for ptr 0x000000
> Sep 18 10:58:53 meteopi weewx[13587]: fousb: unstable read: blocks differ
> for ptr 0x000020
> Sep 18 10:58:53 meteopi weewx[13587]: fousb: unstable read: blocks differ
> for ptr 0x000040
> Sep 18 10:58:54 meteopi weewx[13587]: fousb: unstable read: blocks differ
> for ptr 0x000060
> Sep 18 10:58:54 meteopi weewx[13587]: fousb: unstable read: blocks differ
> for ptr 0x000080
> Sep 18 10:58:54 meteopi weewx[13587]: fousb: unstable read: blocks differ
> for ptr 0x0000a0
> Sep 18 10:58:54 meteopi weewx[13587]: fousb: unstable read: blocks differ
> for ptr 0x0000c0
> Sep 18 10:58:54 meteopi weewx[13587]: fousb: unstable read: blocks differ
> for ptr 0x0000e0
> Sep 18 10:58:54 meteopi weewx[13587]: fousb: unrecognised magic number 0000
> Sep 18 10:58:54 meteopi weewx[13587]: engine: Caught unrecoverable
> exception in engine:
> Sep 18 10:58:54 meteopi weewx[13587]:     ****  unsupported operand
> type(s) for *: 'NoneType' and 'int'
> Sep 18 10:58:54 meteopi weewx[13587]:     ****  Traceback (most recent
> call last):
> Sep 18 10:58:54 meteopi weewx[13587]:     ****    File
> "/home/weewx-3.5.0/bin/weewx/engine.py", line 853, in main
> Sep 18 10:58:54 meteopi weewx[13587]:     ****      engine =
> EngineClass(config_dict)
> Sep 18 10:58:54 meteopi weewx[13587]:     ****    File
> "/home/weewx-3.5.0/bin/weewx/engine.py", line 75, in __init__
> Sep 18 10:58:54 meteopi weewx[13587]:     ****
>  self.loadServices(config_dict)
> Sep 18 10:58:54 meteopi weewx[13587]:     ****    File
> "/home/weewx-3.5.0/bin/weewx/engine.py", line 136, in loadServices
> Sep 18 10:58:54 meteopi weewx[13587]:     ****
>  self.service_obj.append(weeutil.weeutil._get_object(svc)(self,
> config_dict))
> Sep 18 10:58:54 meteopi weewx[13587]:     ****    File
> "/home/weewx-3.5.0/bin/weewx/engine.py", line 484, in __init__
> Sep 18 10:58:54 meteopi weewx[13587]:     ****      if software_interval
> != self.engine.console.archive_interval:
> Sep 18 10:58:54 meteopi weewx[13587]:     ****    File
> "/home/weewx-3.5.0/bin/weewx/drivers/fousb.py", line 993, in
> archive_interval
> Sep 18 10:58:54 meteopi weewx[13587]:     ****      return
> self._archive_interval_minutes() * 60
> Sep 18 10:58:54 meteopi weewx[13587]:     ****  TypeError: unsupported
> operand type(s) for *: 'NoneType' and 'int'
> Sep 18 10:58:54 meteopi weewx[13587]:     ****  Exiting
>
> In a way this is fortunate, in the sense that I run a cron job to check if
> weewx is running, if not I reboot and the problem goes away until the next
> time.
>
> I don't get the "lockup" in the way where I have to "restart" the console
> (batteries out, etc.), but I haven't found any way to get USB going again
> other than a reboot.
>
> Not really looking for a fix, just adding my experience ...
>
> --
> 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 weewx-user+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 weewx-user+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to