On Thursday, August 25, 2016 at 11:23:49 PM UTC-4, Andy wrote:
>
> Installed weewx on the Chip Computer <https://getchip.com/pages/chip>
> connected
> to my Acurite 2032c which can be viewed here
> <http://www.andylittle.us/weewxdev/>. Seems to be working ok for the
> last couple hours. The backup battery connector is a nice feature. Wonder
> how long the permanently attached storage will hold up.
>
at only $9 per board you could burn out a few to find out. if you do,
please let us know!
> cmon is not happy with the new hardware
> Aug 25 19:42:16 chip weewx[17756]: ****
> self.engine.dispatchEvent(weewx.Event(weewx.NEW_ARCHIVE_RECORD,
> record=record, origin='software'))
> Aug 25 19:42:16 chip weewx[17756]: **** File
> "/home/weewx/bin/weewx/engine.py", line 218, in dispatchEvent
> Aug 25 19:42:16 chip weewx[17756]: **** callback(event)
> Aug 25 19:42:16 chip weewx[17756]: **** File
> "/home/weewx/bin/user/cmon.py", line 581, in new_archive_record
> Aug 25 19:42:16 chip weewx[17756]: ****
> self.save_data(self.get_data(now, self.last_ts))
> Aug 25 19:42:16 chip weewx[17756]: **** File
> "/home/weewx/bin/user/cmon.py", line 601, in get_data
> Aug 25 19:42:16 chip weewx[17756]: **** record =
> self.collector.get_data(now_ts)
> Aug 25 19:42:16 chip weewx[17756]: **** File
> "/home/weewx/bin/user/cmon.py", line 474, in get_data
> Aug 25 19:42:16 chip weewx[17756]: **** s =
> self._readproc_line(tfile)
> Aug 25 19:42:16 chip weewx[17756]: **** File
> "/home/weewx/bin/user/cmon.py", line 371, in _readproc_line
> Aug 25 19:42:16 chip weewx[17756]: **** info = fp.read()
> Aug 25 19:42:16 chip weewx[17756]: **** IOError: [Errno 22] Invalid
> argument
> Aug 25 19:42:16 chip weewx[17756]: **** Exiting.
>
in cmon.py line 371 try changing this:
with open(filename) as fp:
info = fp.read()
return info
to this:
with open(filename) as fp:
info = fp.readline().strip()
return info
> The Chip Computer has a connection for a 3.6v battery and a script which
pulls the stats. If the Chip proves
> to be stable, on the to do list is get the battery into cmon or adapt the
APC UPS monitor in cmon.
you'll probably want to add the battery info as a parameter specific to the
chip rather than adapting the apc ups code. it is quite possible that
someone could have an apc ups attached to a chip, in which case you would
want to monitor both the chip battery and the apc ups status.
the 'hardware' option is designed to specify explicitly which hardware cmon
should monitor. ideally cmon would automatically detect all of the
hardware, but until the autodetect code is fully implemented (and for the
cases where autodetect is not possible), use 'hardware' to specify what you
want to monitor.
so you could implement a _get_chip_info() method analogous to the
_get_rpi_info() method, with a 'chip' option for hardware that enables the
chip-specific parameters.
if/when there is autodetection, the autodetector simply sets the value of
the 'hardware' option based on what it finds.
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].
For more options, visit https://groups.google.com/d/optout.