Re: [weewx-user] Re: nogo: driver "ws23xx" and Python V3
On Friday, February 7, 2020 at 4:13:03 PM UTC-6, Thomas Keffer wrote: > > Thank goodness it's not that common a station! > > > Yeah, mine was a gift from a neighbor, received a few years ago. He doesn't live out here full time. I watch over his property, and he wants me to keep him apprised of local conditions. The closest NWS location is 50+ miles away, has different topology, and rarely has the same readings as we do. When I get one of the grandkids out here, I hope to install the wind sensors (I'm not supposed to get on a ladder or the roof these days). If I had the funds, I'd get a more serious station (but it'd have to be supported under weewx, of course). I'd also get a reliable 'net connection (HughesNot is... well... NOT). Thank you again for this project, and thanks to ALL who contribute! Paul -- 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. To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/216b8a77-6df4-4152-b5d8-5b0515e193bb%40googlegroups.com.
Re: [weewx-user] Re: nogo: driver "ws23xx" and Python V3
On Friday, February 7, 2020 at 2:28:34 PM UTC-6, mwall wrote: > > confirmed that the ws23xx driver is now working with both python3 and > python2. tested with: > > station: lacrosse 2310 > os: debian7 > python: 3.7.4 and 2.7.3 > weewx: 4.0.0b11 > ws23xx driver: 0.41 > > i just bumped the driver version number to 0.41 > > sorry so late to the party... > > No worries (on my end). We probably owe TK some primo beers - I know I do! All the contributors are the best I've ever witnessed. What a great project! Paul -- 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. To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/89b69e43-3de5-4354-ad64-f8c490543482%40googlegroups.com.
Re: [weewx-user] Re: nogo: driver "ws23xx" and Python V3
On Friday, February 7, 2020 at 6:46:40 AM UTC-6, Thomas Keffer wrote: > > I'm going to need an aspirin. > > > > Hold the aspirin... methinks you've found/fixed it! The driver output looks normal (to me), and the reports are updating. Kudos! Paul -- 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. To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/c3d8392d-db5a-4134-890a-40f5dbaa845a%40googlegroups.com. root@gummo:/home/weewx# update-alternatives --config python There are 2 choices for the alternative python (providing /usr/bin/python). SelectionPathPriority Status 0/usr/bin/python3.5 2 auto mode * 1/usr/bin/python2.7 1 manual mode 2/usr/bin/python3.5 2 manual mode Press to keep the current choice[*], or type selection number: 2 update-alternatives: using /usr/bin/python3.5 to provide /usr/bin/python (python) in manual mode root@gummo:/home/weewx# PYTHONPATH=bin python3 bin/weewx/drivers/ws23xx.py --readings --port=/dev/ttyS0 {'dp': -4.7, 'it': 32.5, 'ot': 16.1, 'ih': 19.0, 'pa': 918.1, 'wc': -18.9, 'wind': (51.0, 0.0, 5, 0), 'rh': 0.0, 'oh': 24.0, 'cn': 15, 'rt': 1156.69} root@gummo:/home/weewx# update-alternatives --config python There are 2 choices for the alternative python (providing /usr/bin/python). SelectionPathPriority Status 0/usr/bin/python3.5 2 auto mode 1/usr/bin/python2.7 1 manual mode * 2/usr/bin/python3.5 2 manual mode Press to keep the current choice[*], or type selection number: 1 update-alternatives: using /usr/bin/python2.7 to provide /usr/bin/python (python) in manual mode root@gummo:/home/weewx# PYTHONPATH=bin python2 bin/weewx/drivers/ws23xx.py --readings --port=/dev/ttyS0 {'rt': 1156.69, 'wc': -18.9, 'cn': 15, 'oh': 24.0, 'it': 32.5, 'ih': 19.0, 'pa': 918.2, 'dp': -4.7, 'ot': 16.1, 'rh': 0.0, 'wind': (51.0, 0.0, 5, 0)} root@gummo:/home/weewx#
Re: [weewx-user] Re: nogo: driver "ws23xx" and Python V3
On Friday, February 7, 2020 at 6:46:40 AM UTC-6, Thomas Keffer wrote: > > I'm going to need an aspirin. > > > On Thu, Feb 6, 2020 at 3:01 PM P Simmons > > wrote: > >> Sorry for delay, needed a nap. |-) >> >> # PYTHONPATH=bin python3 bin/weewx/drivers/ws23xx.py --readings >> --port=/dev/ttyS0 >> Traceback (most recent call last): >> File "bin/weewx/drivers/ws23xx.py", line 2117, in >> data = s.get_raw_data(SENSOR_IDS) >> File "bin/weewx/drivers/ws23xx.py", line 790, in get_raw_data >> raw_data = read_measurements(self.ws, measures) >> File "bin/weewx/drivers/ws23xx.py", line 2030, in read_measurements >> nybbles = ws2300.read_batch(batches) >> File "bin/weewx/drivers/ws23xx.py", line 1202, in read_batch >> response = self.read_data(address + start_pos, bytes_) >> File "bin/weewx/drivers/ws23xx.py", line 1180, in read_data >> return reduce(flatten, response, ())[:nybble_count] >> File "bin/weewx/drivers/ws23xx.py", line 1179, in >> flatten = lambda a,b: a + (ord(b) % 16, ord(b) / 16) >> TypeError: ord() expected string of length 1, but int found >> >> -- >> 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...@googlegroups.com . >> To view this discussion on the web visit >> https://groups.google.com/d/msgid/weewx-user/dc7b9510-1c6b-4230-9441-86746c46fb73%40googlegroups.com >> >> <https://groups.google.com/d/msgid/weewx-user/dc7b9510-1c6b-4230-9441-86746c46fb73%40googlegroups.com?utm_medium=email_source=footer> >> . >> > I may have inadvertently munged an earlier reply... The latest ws23xx.py is happily running, outputting acceptable records, and weewx is showing the results. Kudos! I appreciate your patience and assistance. Paul -- 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. To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/8d5d31af-1b22-41a1-989f-04dff6e13123%40googlegroups.com.
Re: [weewx-user] Re: nogo: driver "ws23xx" and Python V3
Sorry for delay, needed a nap. |-) # PYTHONPATH=bin python3 bin/weewx/drivers/ws23xx.py --readings --port=/dev/ttyS0 Traceback (most recent call last): File "bin/weewx/drivers/ws23xx.py", line 2117, in data = s.get_raw_data(SENSOR_IDS) File "bin/weewx/drivers/ws23xx.py", line 790, in get_raw_data raw_data = read_measurements(self.ws, measures) File "bin/weewx/drivers/ws23xx.py", line 2030, in read_measurements nybbles = ws2300.read_batch(batches) File "bin/weewx/drivers/ws23xx.py", line 1202, in read_batch response = self.read_data(address + start_pos, bytes_) File "bin/weewx/drivers/ws23xx.py", line 1180, in read_data return reduce(flatten, response, ())[:nybble_count] File "bin/weewx/drivers/ws23xx.py", line 1179, in flatten = lambda a,b: a + (ord(b) % 16, ord(b) / 16) TypeError: ord() expected string of length 1, but int found -- 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. To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/dc7b9510-1c6b-4230-9441-86746c46fb73%40googlegroups.com.
Re: [weewx-user] Re: nogo: driver "ws23xx" and Python V3
# PYTHONPATH=bin python3 bin/weewx/drivers/ws23xx.py --readings --port=/dev/ttyS0 Traceback (most recent call last): File "bin/weewx/drivers/ws23xx.py", line 2120, in data = s.get_raw_data(SENSOR_IDS) File "bin/weewx/drivers/ws23xx.py", line 790, in get_raw_data raw_data = read_measurements(self.ws, measures) File "bin/weewx/drivers/ws23xx.py", line 2033, in read_measurements nybbles = ws2300.read_batch(batches) File "bin/weewx/drivers/ws23xx.py", line 1205, in read_batch response = self.read_data(address + start_pos, bytes_) File "bin/weewx/drivers/ws23xx.py", line 1177, in read_data checksum += six.byte2int(b) TypeError: 'int' object is not subscriptable -- 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. To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/4f95799a-fb13-4299-bd27-f15518c43402%40googlegroups.com.
Re: [weewx-user] Re: nogo: driver "ws23xx" and Python V3
On Thursday, February 6, 2020 at 11:36:40 AM UTC-6, Thomas Keffer wrote: > > Steady progress. > > > > # PYTHONPATH=bin python3 bin/weewx/drivers/ws23xx.py --readings --port=/dev/ttyS0 Traceback (most recent call last): File "bin/weewx/drivers/ws23xx.py", line 2117, in data = s.get_raw_data(SENSOR_IDS) File "bin/weewx/drivers/ws23xx.py", line 790, in get_raw_data raw_data = read_measurements(self.ws, measures) File "bin/weewx/drivers/ws23xx.py", line 2030, in read_measurements nybbles = ws2300.read_batch(batches) File "bin/weewx/drivers/ws23xx.py", line 1202, in read_batch response = self.read_data(address + start_pos, bytes_) File "bin/weewx/drivers/ws23xx.py", line 1175, in read_data checksum = sum([six.byte2int(b) for b in response]) % 256 File "bin/weewx/drivers/ws23xx.py", line 1175, in checksum = sum([six.byte2int(b) for b in response]) % 256 TypeError: 'int' object is not subscriptable -- 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. To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/28f95110-020a-4ffb-ae78-0a548e16c16f%40googlegroups.com.
Re: [weewx-user] Re: nogo: driver "ws23xx" and Python V3
On Thursday, February 6, 2020 at 11:13:28 AM UTC-6, Thomas Keffer wrote: > > I guess that's progress. Try this one. > > I'm just blinding replacing python 2 idioms with six idioms. No idea about > the underlying logic. > > -tk > > Result: # PYTHONPATH=bin python3 bin/weewx/drivers/ws23xx.py --readings --port=/dev/ttyS0 Traceback (most recent call last): File "bin/weewx/drivers/ws23xx.py", line 2117, in data = s.get_raw_data(SENSOR_IDS) File "bin/weewx/drivers/ws23xx.py", line 790, in get_raw_data raw_data = read_measurements(self.ws, measures) File "bin/weewx/drivers/ws23xx.py", line 2030, in read_measurements nybbles = ws2300.read_batch(batches) File "bin/weewx/drivers/ws23xx.py", line 1202, in read_batch response = self.read_data(address + start_pos, bytes_) File "bin/weewx/drivers/ws23xx.py", line 1175, in read_data checksum = sum([ord(b) for b in response]) % 256 File "bin/weewx/drivers/ws23xx.py", line 1175, in checksum = sum([ord(b) for b in response]) % 256 TypeError: ord() expected string of length 1, but int found -- 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. To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/586925c3-625c-435f-93de-903ac781ec69%40googlegroups.com.
Re: [weewx-user] Re: nogo: driver "ws23xx" and Python V3
On Thursday, February 6, 2020 at 10:20:53 AM UTC-6, Thomas Keffer wrote: > > This remote debugging is hard! > > Give this version a try. > > -tk > > > I can appreciate the difficulty, having done remote development (in assembly language, on an obscure Sharp platform, in the distant past). Thank you for your diligence. Here's the output from the latest driver. -- 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. To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/7b25f8c9-ed63-42b7-b094-ebbbde2afccd%40googlegroups.com. # PYTHONPATH=bin python3 bin/weewx/drivers/ws23xx.py --readings --port=/dev/ttyS0 Traceback (most recent call last): File "bin/weewx/drivers/ws23xx.py", line 2116, in data = s.get_raw_data(SENSOR_IDS) File "bin/weewx/drivers/ws23xx.py", line 789, in get_raw_data raw_data = read_measurements(self.ws, measures) File "bin/weewx/drivers/ws23xx.py", line 2029, in read_measurements nybbles = ws2300.read_batch(batches) File "bin/weewx/drivers/ws23xx.py", line 1201, in read_batch response = self.read_data(address + start_pos, bytes_) File "bin/weewx/drivers/ws23xx.py", line 1148, in read_data if not self.write_address(nybble_address): File "bin/weewx/drivers/ws23xx.py", line 1071, in write_address self.write_byte(byte) File "bin/weewx/drivers/ws23xx.py", line 1012, in write_byte self.serial_port.write(data) File "bin/weewx/drivers/ws23xx.py", line 947, in write os.write(self.serial_port, data) TypeError: a bytes-like object is required, not 'str'
Re: [weewx-user] Re: nogo: driver "ws23xx" and Python V3
Appended a "testing bookmark" in /var/log/syslog with "echo". Repeated testing command series. No additional entries in /var/log/syslog either. -- 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. To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/1279b4df-1c31-4d9e-8ee1-87677cdbcc44%40googlegroups.com.
Re: [weewx-user] Re: nogo: driver "ws23xx" and Python V3
On Wednesday, February 5, 2020 at 6:54:41 PM UTC-6, Thomas Keffer wrote: > > /var/log/weewx.log? What's that? Did you try /var/log/syslog? > > On Wed, Feb 5, 2020 at 4:46 PM P Simmons > > wrote: > >> >> >> On Wednesday, February 5, 2020 at 5:53:34 PM UTC-6, Thomas Keffer wrote: >>> >>> Guess I forgot to mention one important detail: send the log! >>> >>> -tk >>> >>> >> Repeated test... no log entries in /var/log/weewx.log during driver >> runs... only console results. Next? >> >> - >> > Whoops... loose nut on keyboard... wilco. p. -- 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. To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/b001f415-d873-460b-a262-f6acd278fdd4%40googlegroups.com.
Re: [weewx-user] Re: nogo: driver "ws23xx" and Python V3
On Wednesday, February 5, 2020 at 5:53:34 PM UTC-6, Thomas Keffer wrote: > > Guess I forgot to mention one important detail: send the log! > > -tk > > Repeated test... no log entries in /var/log/weewx.log during driver runs... only console results. Next? -- 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. To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/ad4c5b6f-b521-4939-b25e-8e43f5ebf125%40googlegroups.com.
Re: [weewx-user] Re: nogo: driver "ws23xx" and Python V3
On Wednesday, February 5, 2020 at 9:03:44 AM UTC-6, Thomas Keffer wrote: > > Could you please go into the file ws23xx.py and change the global variable > DEBUG_SERIAL to True (line 803)? Then try running the driver directly. For > example: > > *PYTHONPATH=bin python3 bin/weewx/drivers/ws23xx.py --readings* > > While you're at it, try both python2 and python3. > > -tk > > Here are the results for both versions. Note: I overrode the port setting, as it defaulted to USB, but mine is serial (/dev/ttyS0). Thanks! Paul -- 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. To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/0b622079-5955-4efd-bbc0-305bac967075%40googlegroups.com. root@gummo:~# /etc/init.d/weewx stop [ ok ] Stopping weewx weather system: weewx. root@gummo:~# cd /home/weewx root@gummo:/home/weewx# python -V Python 2.7.13 root@gummo:/home/weewx# PYTHONPATH=bin python2 bin/weewx/drivers/ws23xx.py --readings --port=/dev/ttyS0 {'rt': 1156.69, 'wc': -18.9, 'cn': 15, 'oh': 61.0, 'it': 30.4, 'ih': 19.0, 'pa': 915.9, 'dp': -7.78, 'ot': -1.2, 'rh': 0.0, 'wind': (51.0, 0.0, 5, 0)} root@gummo:/home/weewx# update-alternatives --config python There are 2 choices for the alternative python (providing /usr/bin/python). SelectionPathPriority Status 0/usr/bin/python3.5 2 auto mode * 1/usr/bin/python2.7 1 manual mode 2/usr/bin/python3.5 2 manual mode Press to keep the current choice[*], or type selection number: 2 update-alternatives: using /usr/bin/python3.5 to provide /usr/bin/python (python) in manual mode root@gummo:/home/weewx# python -V Python 3.5.3 root@gummo:/home/weewx# PYTHONPATH=bin python3 bin/weewx/drivers/ws23xx.py --readings --port=/dev/ttyS0 Traceback (most recent call last): File "bin/weewx/drivers/ws23xx.py", line 2116, in data = s.get_raw_data(SENSOR_IDS) File "bin/weewx/drivers/ws23xx.py", line 789, in get_raw_data raw_data = read_measurements(self.ws, measures) File "bin/weewx/drivers/ws23xx.py", line 2029, in read_measurements nybbles = ws2300.read_batch(batches) File "bin/weewx/drivers/ws23xx.py", line 1193, in read_batch self.reset_06() File "bin/weewx/drivers/ws23xx.py", line 1062, in reset_06 raise self.Ws2300Exception(msg) __main__.Ws2300Exception: Reset failed, 100 retries, no response
[weewx-user] Re: nogo: driver "ws23xx" and Python V3
Well, weewx doesn't terminate with the new driver under Python3, but there seems to be another issue. The reports don't update under Python3. It's been a long time since I modified the weewx.conf (and I'm sure I have done so); don't discount the possibility that I've munged something! Here are the outputs from the gitlog of the version that I used, weewx_debug, and the weewx.log from the time I stopped the daemon, switched Python to "3", restarted, then stopped and switched back to Python "2" (and restarted). Sorry if I'm being a "pain". I love this software! I'm very grateful for all the effort you folks put into it. This issue isn't "mission critical", so feel free to move on to more serious problems. p. -- 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. To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/e2c78b92-725e-4b16-a12a-953abd01e6c0%40googlegroups.com. commit 6e31430d1e998c0a526fb4b2b0b594a9084efb08 Merge: bd04120b 223fafc8 Author: Tom Keffer Date: Tue Feb 4 18:06:47 2020 -0800 Merge branch 'development' Usage: wee_debug --help wee_debug --info [CONFIG_FILE|--config=CONFIG_FILE] [--output|--output DEBUG_PATH] [--verbosity=0|1|2] wee_debug --version Description: Generate a standard suite of system/weewx information to aid in remote debugging. The wee_debug output consists of two parts, the first part containing a snapshot of relevant system/weewx information and the second part a parsed and obfuscated copy of weewx.conf. This output can be redirected to file and posted when seeking assistance via forums or email. Actions: --info Generate a debug report. Options: -h, --helpshow this help message and exit --config=CONFIG_FILE Use configuration file CONFIG_FILE. --infoGenerate weewx debug output. --output Write wee_debug output to DEBUG_PATH. DEBUG_PATH includes path and file name. Default is /var/tmp/weewx.debug. --verbosity=N How much detail to display, 0-2, default=1. --version Display wee_debug version number. wee_debug will attempt to obfuscate obvious personal/private information in weewx.conf such as user names, passwords and API keys; however, the user should thoroughly check the generated output for personal/private information before posting the information publicly. Feb 4 22:54:10 gummo weewx[9134] INFO __main__: Received signal TERM (15). Feb 4 22:54:10 gummo weewx[9134] INFO weewx.engine: Main loop exiting. Shutting engine down. Feb 4 22:54:10 gummo weewx[9134] INFO weewx.engine: Shutting down StdReport thread Feb 4 22:54:10 gummo weewx[9134] INFO __main__: Terminating weewx version 4.0.0b11 Feb 4 22:54:10 gummo weewx[9134] INFO __main__: Traceback (most recent call last): Feb 4 22:54:10 gummo weewx[9134] INFO __main__: File "/home/weewx/bin/weewxd", line 154, in main Feb 4 22:54:10 gummo weewx[9134] INFO __main__: engine.run() Feb 4 22:54:10 gummo weewx[9134] INFO __main__: File "/home/weewx/bin/weewx/engine.py", line 186, in run Feb 4 22:54:10 gummo weewx[9134] INFO __main__: for packet in self.console.genLoopPackets(): Feb 4 22:54:10 gummo weewx[9134] INFO __main__: File "/home/weewx/bin/weewx/drivers/ws23xx.py", line 485, in genLoopPackets Feb 4 22:54:10 gummo weewx[9134] INFO __main__: time.sleep(self._poll_wait) Feb 4 22:54:10 gummo weewx[9134] INFO __main__: File "/home/weewx/bin/weewxd", line 257, in sigTERMhandler Feb 4 22:54:10 gummo weewx[9134] INFO __main__: raise Terminate Feb 4 22:54:10 gummo weewx[9134] INFO __main__: Terminate Feb 4 22:58:44 gummo weewx[4570] INFO __main__: Initializing weewx version 4.0.0b11 Feb 4 22:58:44 gummo weewx[4570] INFO __main__: Using Python 3.5.3 (default, Sep 27 2018, 17:25:39) #012[GCC 6.3.0 20170516] Feb 4 22:58:44 gummo weewx[4570] INFO __main__: Platform Linux-4.9.0-11-amd64-x86_64-with-debian-9 Feb 4 22:58:44 gummo weewx[4570] INFO __main__: Locale is 'en_US.UTF-8' Feb 4 22:58:44 gummo weewx[4570] INFO __main__: PID file is /var/run/weewx.pid Feb 4 22:58:45 gummo weewx[4574] INFO __main__: Using configuration file /home/weewx/weewx.conf Feb 4 22:58:45 gummo weewx[4574] DEBUG __main__: Initializing engine Feb 4 22:58:45 gummo weewx[4574] INFO weewx.engine: Loading station type WS23xx (weewx.drivers.ws23xx) Feb 4 22:58:45 gummo weewx[4574] INFO weewx.drivers.ws23xx: driver version is 0.40 Feb 4 22:58:45 gummo weewx[4574] INFO weewx.drivers.ws23xx: serial port is /dev/ttyS0 Feb 4 22:58:45 gummo weewx[4574] INFO weewx.drivers.ws23xx: polling interval is None Feb
[weewx-user] nogo: driver "ws23xx" and Python V3
I've attempted to move from Python2 to Python3, and have encountered a problem with ws23xx.py Thank you, Paul -- 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. To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/2cfe7671-0233-4197-aecc-c0f5d6b0b7d0%40googlegroups.com. Feb 3 16:22:42 gummo weewx[9021] INFO __main__: Initializing weewx version 4.0.0b11 Feb 3 16:22:42 gummo weewx[9021] INFO __main__: Using Python 3.5.3 (default, Sep 27 2018, 17:25:39) #012[GCC 6.3.0 20170516] Feb 3 16:22:42 gummo weewx[9021] INFO __main__: Platform Linux-4.9.0-11-amd64-x86_64-with-debian-9 Feb 3 16:22:42 gummo weewx[9021] INFO __main__: Locale is 'en_US.UTF-8' Feb 3 16:22:42 gummo weewx[9021] INFO __main__: PID file is /var/run/weewx.pid Feb 3 16:22:42 gummo weewx[9025] INFO __main__: Using configuration file /home/weewx/weewx.conf Feb 3 16:22:42 gummo weewx[9025] INFO weewx.engine: Loading station type WS23xx (weewx.drivers.ws23xx) Feb 3 16:22:42 gummo weewx[9025] INFO weewx.drivers.ws23xx: driver version is 0.40 Feb 3 16:22:42 gummo weewx[9025] INFO weewx.drivers.ws23xx: serial port is /dev/ttyS0 Feb 3 16:22:42 gummo weewx[9025] INFO weewx.drivers.ws23xx: polling interval is None Feb 3 16:22:42 gummo weewx[9025] ERROR weewx.engine: Import of driver failed: tcsetattr: elements of attributes must be characters or integers () Feb 3 16:22:42 gummo weewx[9025] CRITICAL weewx.engine: Traceback (most recent call last): Feb 3 16:22:42 gummo weewx[9025] CRITICAL weewx.engine: File "/home/weewx/bin/weewx/engine.py", line 103, in setupStation Feb 3 16:22:42 gummo weewx[9025] CRITICAL weewx.engine: self.console = loader_function(config_dict, self) Feb 3 16:22:42 gummo weewx[9025] CRITICAL weewx.engine: File "/home/weewx/bin/weewx/drivers/ws23xx.py", line 271, in loader Feb 3 16:22:42 gummo weewx[9025] CRITICAL weewx.engine: return WS23xxDriver(config_dict=config_dict, **config_dict[DRIVER_NAME]) Feb 3 16:22:42 gummo weewx[9025] CRITICAL weewx.engine: File "/home/weewx/bin/weewx/drivers/ws23xx.py", line 438, in __init__ Feb 3 16:22:42 gummo weewx[9025] CRITICAL weewx.engine: self.station = WS23xx(self.port) Feb 3 16:22:42 gummo weewx[9025] CRITICAL weewx.engine: File "/home/weewx/bin/weewx/drivers/ws23xx.py", line 640, in __init__ Feb 3 16:22:42 gummo weewx[9025] CRITICAL weewx.engine: self.serial_port = LinuxSerialPort(port) Feb 3 16:22:42 gummo weewx[9025] CRITICAL weewx.engine: File "/home/weewx/bin/weewx/drivers/ws23xx.py", line 920, in __init__ Feb 3 16:22:42 gummo weewx[9025] CRITICAL weewx.engine: tty.tcsetattr(self.serial_port, tty.TCSAFLUSH, setup) Feb 3 16:22:42 gummo weewx[9025] CRITICAL weewx.engine: TypeError: tcsetattr: elements of attributes must be characters or integers Feb 3 16:22:42 gummo weewx[9025] CRITICAL __main__: Unable to load driver: tcsetattr: elements of attributes must be characters or integers Feb 3 16:22:42 gummo weewx[9025] CRITICAL __main__: Exiting...
Re: [weewx-user] cheetah error a/ upgrade to v4.0.0b9 commit a85e320c
On Friday, January 24, 2020 at 5:34:14 PM UTC-6, Thomas Keffer wrote: > > Could you all do a pull and give it another try? The flow path between > byte strings and unicode are more controlled now, making the results less > prone to decode errors. > > At least, that's the theory! > > -tk > My weewx machine defaults to Python 2.7.13 . I pulled and installed weewx-4.0.0b10 at commit 00609bf . Everything still fine. Thanks for your work, tk... Thanks for your testing, Gary! Paul -- 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. To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/652fd118-d462-4617-a812-59e97da9f060%40googlegroups.com.
Re: [weewx-user] cheetah error a/ upgrade to v4.0.0b9 commit a85e320c
Updated to db1b41e, problem solved. Thanks! Paul -- 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. To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/a7dc4e3c-a223-4344-ba8e-f4fd58a23168%40googlegroups.com.
Re: [weewx-user] cheetah error a/ upgrade to v4.0.0b9 commit a85e320c
On Wednesday, January 22, 2020 at 8:20:57 PM UTC-6, Thomas Keffer wrote: > > Thanks, Paul > > Could you temporarily replace your copy of units.py with the attached? It > will log some clues about what's causing the decode error. > > > > TK: Wilco - but tomorrow (sorry for delay). Thanks! P. -- 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. To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/572b1491-e19f-48e0-a7be-163dbff5b9ca%40googlegroups.com.
[weewx-user] cheetah error a/ upgrade to v4.0.0b9 commit a85e320c
Howdy! I had no problems using v4.0.0b6 but decided to upgrade to v4.0.0b9. I'm now having problems with report generation. Here are my (sanitized) conf and log files. Thank you, Paul -- 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. To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/09a70440-5968-43ba-a1ef-6ee23306f2d2%40googlegroups.com. Using configuration file /home/weewx/weewx.conf Using database binding 'wx_binding', which is bound to database 'archive_mysql' System info Platform: Linux-4.9.0-11-amd64-x86_64-with-debian-9 Python Version: 2.7.13 Load Information 1 minute load average: 0.01 5 minute load average: 0.02 15 minute load average: 0.00 General Weewx info Weewx version 4.0.0b9 detected. Station info Station type: WS23xx Driver: weewx.drivers.ws23xx Driver info [WS23xx] # This section is for the La Crosse WS-2300 series of weather stations. # Serial port such as /dev/ttyS0, /dev/ttyUSB0, or /dev/cuaU0 port = /dev/ttyS0 # The station model, e.g., 'LaCrosse WS2317' or 'TFA Primus' model = LaCrosse WS23xx # The driver to use: driver = weewx.drivers.ws23xx Currently installed extensions No extensions installed Archive info Database name:weewx Table name: archive Version 2.0 Unit system: 1 (US) First good timestamp: 2016-07-08 03:33:26 CDT (1467966806) Last good timestamp: 2020-01-22 19:20:00 CST (1579742400) Number of records:370171 weewx (weewx.conf) is set to use an archive interval of 300 seconds. The station hardware was not interrogated in determining archive interval. Databases configured in weewx.conf Database name:weewx.sdb Database driver: weedb.sqlite Database name:weewx Database driver: weedb.mysql Database host:localhost Parsed and obfuscated weewx.conf # WEEWX CONFIGURATION FILE # # Copyright (c) 2009-2015 Tom Keffer # See the file LICENSE.txt for your rights. ## # This section is for general configuration information. # Set to 1 for extra debug info, otherwise comment it out or set to zero debug = 1 # Root directory of the weewx data file hierarchy for this station WEEWX_ROOT = /home/weewx # Whether to log successful operations log_success = True # Whether to log unsuccessful operations log_failure = True # How long to wait before timing out a socket (FTP, HTTP) connection socket_timeout = 20 # Do not modify this. It is used when installing and updating weewx. version = 4.0.0b9 ## # This section is for information about the station. [Station] # Description of the station location location = MBAT (meanwhile, back at the) Ranch # Latitude and longitude in decimal degrees latitude = 30.934306 longitude = -101.775556 # Altitude of the station, with unit it is in. This is downloaded from # from the station if the hardware supports it. altitude = 2667, foot# Choose 'foot' or 'meter' for unit # Set to type of station hardware. There must be a corresponding stanza # in this file with a 'driver' parameter indicating the driver to be used. station_type = WS23xx # If you have a website, you may specify an URL #station_url = http://www.example.com # The start of the rain year (1=January; 10=October, etc.). This is # downloaded from the station if the hardware supports it. rain_year_start = 1 # Start of week (0=Monday, 6=Sunday) week_start = 6 ## [WS23xx] # This section is for the La Crosse WS-2300 series of weather stations. # Serial port such as /dev/ttyS0, /dev/ttyUSB0, or /dev/cuaU0 port = /dev/ttyS0 # The station model, e.g., 'LaCrosse WS2317' or 'TFA Primus' model = LaCrosse WS23xx # The driver to use: driver = weewx.drivers.ws23xx ## # This section is for uploading data to Internet sites [StdRESTful] [[StationRegistry]] # To register this weather station with weewx, set this to true register_this_station = false [[AWEKAS]] # This section is for configuring posts to AWEKAS. # If you wish to do this, set the option 'enable' to true, # and specify a username and password. enable = false username = XXX obfuscated by wee_debug XXX password = XXX obfuscated by wee_debug XXX [[CWOP]] # This section is for configuring
Re: [weewx-user] Re: Beta testers for v3.9.0 needed
On Sunday, January 27, 2019 at 11:21:05 AM UTC-6, Thomas Keffer wrote: > > Take a look at permissions in /etc/logrotate.d: > > *ls -l /etc/logrotate.d* > > On Sun, Jan 27, 2019 at 9:06 AM P Simmons > > wrote: > >> After update to 3.9.0b2, anacron logged this: >> >> /etc/cron.daily/logrotate: >> error: Ignoring weewx because of bad file mode - must be 0644 or 0444. >> >> No other anomalies noted at this time. >> >> Thanks! >> >> Paul >> >> -- >> 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+...@googlegroups.com . >> For more options, visit https://groups.google.com/d/optout. >> > Found it... needed to edit contents of /home/weewx/util/logrotate.d/weewx for owner:group and permissions - didn't remember having to do that before! Thanks, Paul -- 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.
[weewx-user] Re: Beta testers for v3.9.0 needed
After update to 3.9.0b2, anacron logged this: /etc/cron.daily/logrotate: error: Ignoring weewx because of bad file mode - must be 0644 or 0444. No other anomalies noted at this time. Thanks! Paul -- 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.
[weewx-user] Re: One more option for Build Your Own enthusiasts
On Tuesday, December 11, 2018 at 9:53:25 PM UTC-6, Louis De Lange wrote: > > I recently came across a really excellent solution for putting together > your own weather station on the cheap with high quality sensors - and most > importantly a very useful weather HAT to use with a Raspberry PI to connect > all the sensors. > > It comes complete with a 4 part step by step tutorial to assemble the > whole station, and basic code to upload the data to and online service - > see link below: > > https://www.bc-robotics.com/tutorials/raspberry-pi-weather-station-part-1/ > > I completed my own installation based on the instructions in the tutorial > and my station running on weewx is active at the link below > > http://peachlandweather.ca/mystation/ > > For the outdoor portion I used a Raspberry Pi Zero W, with the weather > HAT. Weewx is running indoors in a FreeBSD jail, using a stock Interceptor > driver. I modified the basic upload code provided in the tutorial quite > extensively to generate upload loops that matched the Observer URLs > supported by the Interceptor driver, and also to produce derived > observations not included in the original code. > > The upload code is attached for anyone who might be interested in trying > to assemble their own. > > I tested the results from using the station against my Vantage Pro 2 and > so far it seems to be pretty close - for less than 20% of the cost of a > Vantage Pro. > Please define "pretty close". Thanks! -- 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.
[weewx-user] Re: Copy Weewx files to another SD card
I wonder if "cp -pr" was used? Permissions and subdirs may have complicated matters... -- 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.