--
You received this message because you are subscribed to a topic in the Google Groups "weewx-user" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/weewx-user/YSz_IWnzOjE/unsubscribe.
To unsubscribe from this group and all its topics, send an email to weewx-user+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Thanks for your response. If necessary I am willing to downgrade to ubuntu 14.04I am on Ubuntu 16.04 with Kernel 4.4.0-45-genericI havepython-usb 1.0.0~b2libusb-1.0-0 1.0.20-1libusb-0.1-4 0.1.23-28
Downgrade to python-usb 0.4.3 did not change the behavior. Clean install of Ubuntu 14.04.5 followed by a clean install of weewx 3.6.1 did not change the behavior. No I took a brand new Raspberry, put weewx on it, but I have exactly the same issue. In the past I was running my station on a Raspberry with weewx 3.5.0 successfully.
Thank you
I have had the same problem and I have solve it with the same solution. Using 3.5.0 wmr 300 driver.
Thank you very much for your answer.I have tested the new driver and report me this error:
I gave it a try, but I had the following errors in the log with debug = 0
Nov 3 18:01:42 lin01 weewx[19698]: wmr300: usb failure: could not detach kernel driver from interface 0: Keine Daten verfügbar
Nov 3 18:01:42 lin01 weewx[19698]: engine: Caught WeeWxIOError: could not detach kernel driver from interface 0: Keine Daten verfügbar
Nov 3 18:01:42 lin01 weewx[19698]: **** Waiting 60 seconds then retrying..
I just test the new driver and I have the same Roland error. Thank you very much.
Hi,I just test the new driver and I have the same Roland error. Thank you very much.
On Sunday, November 6, 2016 at 8:58:36 AM UTC-5, Thomas O wrote:I see the same issue with 0.15rc1 from master and WMR300.
Any data you need to further debug ; I am trying to diff 0.9 and 0.15rc1 but I didn't find anything obvious yet.
Can i provide some more traces ?
thomas,
please post your usb configuration 'dpkg -l | grep usb'
also, please post the exception stack when you run 0.15rc1
this is rather perplexing. i thought the localization that alberto (es) and roland (de) are using might be causing the problem, but i'm not sure. the driver checks for 'No data available' and 'No error' messages from libusb. (i have not yet figured out a way to check for an error code that works across different libusb versions)
PYTHONPATH=. python weewx/drivers/wmr300.pyNov 12 13:55:19 x wmr300[13744]: wmr300: driver version is 0.15rc2
Nov 12 13:55:19 x wmr300[13744]: wmr300: Found station at bus= device=
Nov 12 13:55:19 x wmr300[13744]: wmr300: usb failure: [Errno 110] Operation timed out
I copied in wrm300.py v0.15rc2, as described above, and, runningPYTHONPATH=. python weewx/drivers/wmr300.py
I now get:Nov 12 13:55:19 x wmr300[13744]: wmr300: driver version is 0.15rc2
Nov 12 13:55:19 x wmr300[13744]: wmr300: Found station at bus= device=
Nov 12 13:55:19 x wmr300[13744]: wmr300: usb failure: [Errno 110] Operation timed out
The null entries for bus and filename look to be from usb.legacy, where they are simply populated with empty strings.
Note, the timeout (and exit) is almost immediate - always the same second.
if you try starting a second time, does everything work?
on a test system i sometimes see the timeout when starting weewx for the very first time, i.e., when there has been no communication with the station for some time (an hour? a day? a week?). but a subsequent start works. i suspect it is a case of getting the station to start spitting out data on the usb - the driver must not be using the right protocol to get communication started. but once the station is spitting out data, the driver works fine - there is a heartbeat command that keeps communication going.
could you sniff the usb when running the windows software to communicate with the hardware? we need a capture that covers this:
1) station is already plugged in to usb
2) start the windows software
3) record one or two intervals of current data
i also suspect that we are dealing with two issues here - one is the driver's check for 'No error' and 'No data available' (that would be affected by localization) and the other is the timeout failures (due to startup/initialization protocol).
of course, this is all reverse engineering a system for which we get zero help from the manufacturer or vendor, so i could be completely wrong.
m
Hi,I had initially tried several times, and then started using the debug method of running the driver directly.
I have now got it to work - by adding a test for "timed out" in the error string. This seems to come from libusb1 being mapped from LIBUSB_ERROR_TIMEOUT.
I cannot understand how an error message of "No data available" could be created instead of a timeout message.
I also recoded the driver in the non-legacy pyusb api, but that was a waste of time (except that I could then understand a bit better what was happening).
I will do a bit of packet sniffing of the windows version while I still have the sensors on the ground.
I will even put the hose into it and see what the software does when I "overflow" the raingauge counter.
i suspect that different versions of libusb assemble the errors differently. afaict, some of the strerror messages are coming from the operating system, not libusb. i do not yet know a reliable way to extract the error intent using pyusb.
when you test, please set debug in weewx.conf:
debug=1
...
[WMR300]
...
debug_rain = 1
debug_decode = 1
Hmm, more debugging needed.
Hi mwallYou said that our error is related to the location of the operating system. If we change the location (I don`t know how yet), will the new drivers work?
station_type = WMR300c
[WMR300c]
# This section is for WMR300 weather stations. modified by cameron
# The station model, e.g., WMR300A
model = WMR300c
# The driver to use:
driver = user.wmr300c
debug_decode=1
debug_rain=1
sudo /etc/init.d/weewx status -l● weewx.service - LSB: weewx weather system Loaded: loaded (/etc/init.d/weewx) Active: active (exited) since mar 2016-11-15 19:47:20 CET; 2s ago Process: 19541 ExecStop=/etc/init.d/weewx stop (code=exited, status=0/SUCCESS) Process: 19588 ExecStart=/etc/init.d/weewx start (code=exited, status=0/SUCCESS)
nov 15 19:47:20 raspberrypi weewx[19603]: **** File "/usr/share/weewx/weewx/engine.py", line 70, in __init__nov 15 19:47:20 raspberrypi weewx[19603]: **** self.setupStation(config_dict)nov 15 19:47:20 raspberrypi weewx[19603]: **** File "/usr/share/weewx/weewx/engine.py", line 88, in setupStationnov 15 19:47:20 raspberrypi weewx[19603]: **** driver = config_dict[stationType]['driver']nov 15 19:47:20 raspberrypi weewx[19603]: **** File "/usr/lib/python2.7/dist-packages/configobj.py", line 554, in __getitem__nov 15 19:47:20 raspberrypi weewx[19603]: **** val = dict.__getitem__(self, key)nov 15 19:47:20 raspberrypi weewx[19603]: **** KeyError: 'WMR300c'nov 15 19:47:20 raspberrypi weewx[19603]: **** Exiting.
Introducir código aquí...sudo /etc/init.d/weewx status● weewx.service - LSB: weewx weather system Loaded: loaded (/etc/init.d/weewx) Active: active (exited) since mar 2016-11-15 19:51:25 CET; 6min ago Process: 19794 ExecStop=/etc/init.d/weewx stop (code=exited, status=0/SUCCESS) Process: 20014 ExecReload=/etc/init.d/weewx reload (code=exited, status=0/SUCCESS) Process: 19841 ExecStart=/etc/init.d/weewx start (code=exited, status=0/SUCCESS)
nov 15 19:51:25 raspberrypi systemd[1]: Started LSB: weewx weather system.nov 15 19:51:41 raspberrypi systemd[1]: Reloading LSB: weewx weather system.nov 15 19:51:41 raspberrypi weewx[19906]: Reloading weewx weather system: weewxstart-stop-daemon: warning: failed to kill 19856: No such processnov 15 19:51:41 raspberrypi weewx[19906]: .nov 15 19:51:41 raspberrypi systemd[1]: Reloaded LSB: weewx weather system.nov 15 19:55:23 raspberrypi systemd[1]: Reloading LSB: weewx weather system.nov 15 19:55:23 raspberrypi weewx[20014]: Reloading weewx weather system: weewxstart-stop-daemon: warning: failed to kill 19856: No such processnov 15 19:55:23 raspberrypi weewx[20014]: .nov 15 19:55:23 raspberrypi systemd[1]: Reloaded LSB: weewx weather system.nov 15 19:55:28 raspberrypi systemd[1]: Started LSB: weewx weather system.
sudo /etc/init.d/weewx status -l● weewx.service - LSB: weewx weather system Loaded: loaded (/etc/init.d/weewx) Active: active (exited) since mar 2016-11-15 20:11:54 CET; 8min ago Process: 1752 ExecReload=/etc/init.d/weewx reload (code=exited, status=0/SUCCESS) Process: 424 ExecStart=/etc/init.d/weewx start (code=exited, status=0/SUCCESS)
nov 15 20:11:54 raspberrypi weewx[1007]: **** File "/usr/share/weewx/weewx/engine.py", line 88, in setupStationnov 15 20:11:54 raspberrypi weewx[1007]: **** driver = config_dict[stationType]['driver']nov 15 20:11:54 raspberrypi weewx[1007]: **** File "/usr/lib/python2.7/dist-packages/configobj.py", line 554, in __getitem__nov 15 20:11:54 raspberrypi weewx[1007]: **** val = dict.__getitem__(self, key)nov 15 20:11:54 raspberrypi weewx[1007]: **** KeyError: 'wmr300'nov 15 20:11:54 raspberrypi weewx[1007]: **** Exiting.nov 15 20:19:16 raspberrypi systemd[1]: Reloading LSB: weewx weather system.nov 15 20:19:16 raspberrypi weewx[1752]: Reloading weewx weather system: weewxstart-stop-daemon: warning: failed to kill 1007: No such processnov 15 20:19:16 raspberrypi weewx[1752]: .nov 15 20:19:16 raspberrypi systemd[1]: Reloaded LSB: weewx weather system.pi@raspberrypi:~ $ ^C
Have been following this thread with interest as I am having the same issues. Current setup is a WMR300 connected to a RPi 3 running Rasbian Jessie. Installed 3.6.2 and had the same usb issue. Tried installing the 0.15RC2 driver but had a different error. As it was a new setup I downgraded to 3.5.0 to ensure that all was working ok. This was successful so I'm happy the hardware is ok.I will try and put 3.6.2 back on and retry the updated driver. If anybody has any further info about this it would be much appreciated,
More pain...
File "weewx/drivers/wmr300-v09.py", line 1045, in readMore pain...When I start usb capture and directly run either v0.9 or the v0.15rc3 I get the same immediate crashThe last lines of the stack trace areFile "weewx/drivers/wmr300-v09.py", line 1045, in readif not e.args[0].find('No data available'):AttributeError: 'int' object has no attribute 'find'
This happens on the very first read.
If I precede that line by "print e" I get: "[Errno 110] Operation timed out"The only other thing I noticed in the capture was a control packet :USBHID SET_IDLE requestand an acknowledgement that it was successful.This only happens the first time - when the kernel detach succeeds. However, I have sometimes seen it on a windows capture as well, so I don't think it is significant.
the timeouts seem to happen when the station has stopped spewing on the usb. if that is the root cause of timeouts, then the question is "how do we get it to start spewing again?" i have only seen the timeout when starting weewx. starting weewx a second time resulted in normal behavior. so using loop_on_init is a workaround for that, but it does not tell us what part of the driver initialization causes the station to start usb spewage. more significantly, there might be cases where someone is getting timeouts, and multiple attempts at starting weewx does not make the timeouts go away.
localization comes into play in the detection of the USBError type. when we get a 'no data available' or 'no error' USBError, we ignore them. these are not really errors (especially not the 'no error' "error"), so we do not want to raise exceptions. when localization changes the string from 'No data available' to the equivalent in de, es, or fr, an exception is raised instead of being ignored.
so there are two things to sort out:
1) how to determine the USBError type without:
a) using the member args, which is dependent on libusb/pyusb version
b) parsing for a 'no data available' string that depends on locale
2) how to get the station to start jabbering (assuming that the timeouts are because the station is not jabbering). of course, this might be more complicated if the root cause is a more subtle usb comm issue rather than just getting the station to start talking.
so what do we do?
- for each test, we need to know:
- what version of libusb
- what version of pyusb
- what version of weewx
- what version of wmr300
- test the following:
- start up weewx
- test permutations
- weewx versions: 3.5.0, 3.6.2
- wmr300 versions: 0.9, 0.15rc2, 0.15rc3
- libusb versions: 1.0.x, 0.1.x
- pyusb versions: 0.4, 1.0
The solution mainly involved looking again at Zahlii's code and, because the wmr300 would not listed to me, I would not talk to it.It is quite happy to send data without a single ACK response, so long as the heartbeat occurs every so often.
The history reread might still have some gaps in it.
I have tested RC2 driver and it starts correctly, thamk you very much for your job. But I have other problem now, I lose a lot of pressure data, temperature ... (example https://www.wunderground.com/personal-weather-station/dashboard?ID=IULTZAMA2#history/tdata/s20161211/e20161211/mdaily)
Weewx 3.6.1
Driver 0.15RC3
Locale English
Thanks for the information, I've changed the location of my console and I no longer date. I agree with you on reading barometer data.
I only have to wait until it rains, to see that the readings are correct as well.
Thank you very much
--
You received this message because you are subscribed to a topic in the Google Groups "weewx-user" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/weewx-user/YSz_IWnzOjE/unsubscribe.
To unsubscribe from this group and all its topics, send an email to weewx-user+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
It has rained tonight. The console has registered the rain and weewx has recorded the rain rate well but has not calculated the total rain. Example: Today's Rain 0.0 mm
High Rain Rate 1.3 mm / hr at 05:19:22 AM
Weewx 3.6.1
Driver 0,15RC3
| RainRate | Rain | |
| 1482207600 | 0.0048387097 | 0 |
| 1482207900 | 0.0499999999 | 0 |
| 1482208200 | 0.0499999999 | 0 |
| 1482208500 | 0.0478787878 | 0 |
| 1482208800 | 0.0091428571 | 0 |
In the rain counter of the console appeared "HHH mm". I just reset and has been zeroed.
Hi Cameron,
I have had erroneous rain readings (9000mm or even more), I think due to communication failures and in some cases I found cobwebs in the rain gauge. Because of this I think I have reached the limit. At the moment I am in tests, as soon as the weather station works correctly I will erase all the data of wunderground and I will start again. The anticyclone we have in Europe does not help me to speed up the tests xD
Many thanks to all for the help.
Mwall,
At the moment I do not have enough knowledge to help you capture packages for the driver, but if you need me to do some test you can ask me.
> For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to a topic in the Google Groups "weewx-user" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/weewx-user/YSz_IWnzOjE/unsubscribe.
To unsubscribe from this group and all its topics, send an email to weewx-user+unsubscribe@googlegroups.com.
I installed 3.6.2 today on Ubuntu (old HP laptop) attached to a WMR300a. I am having the same problem described in this thread: no data from the console. I installed using apt-get which gave me version 0.13 of the driver. After reading this thread, I went to github and got 0.16rc2. Should I use version in this zip file? It says something about WMR300C. Does that matter?
--
You received this message because you are subscribed to a topic in the Google Groups "weewx-user" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/weewx-user/YSz_IWnzOjE/unsubscribe.
To unsubscribe from this group and all its topics, send an email to weewx-user+unsubscribe@googlegroups.com.
Feb 05 13:29:16 raspberrypi weewx[1369]: wmr300: e.errno=None e.strerror=None e.message=could not detach kernel driver from interface 0: No data available repr=USBError('could not detach kernel driver from...ata available',)Feb 05 13:29:17 raspberrypi weewx[1369]: wmr300: e.errno=None e.strerror=None e.message=could not detach kernel driver from interface 0: No data available repr=USBError('could not detach kernel driver from...ata available',)Feb 05 13:29:17 raspberrypi weewx[1369]: wmr300: e.errno=None e.strerror=None e.message=could not detach kernel driver from interface 0: No data available repr=USBError('could not detach kernel driver from...ata available',)Feb 05 13:29:17 raspberrypi weewx[1369]: wmr300: e.errno=None e.strerror=None e.message=could not detach kernel driver from interface 0: No data available repr=USBError('could not detach kernel driver from...ata available',)Feb 05 13:29:17 raspberrypi weewx[1369]: wmr300: e.errno=None e.strerror=None e.message=could not detach kernel driver from interface 0: No data available repr=USBError('could not detach kernel driver from...ata available',)
ii libusb-0.1-4:armhf 2:0.1.12-25 armhf userspace USB programming libraryii libusb-1.0-0:armhf 2:1.0.19-1 armhf userspace USB programming libraryii libusbmuxd2:armhf 1.0.9-1 armhf USB multiplexor daemon for iPhone and iPod Touch devices - libraryii python-usb 0.4.3-1 armhf USB interface for Pythonii usb-modeswitch 2.2.0+repack0-2 armhf mode switching tool for controlling "flip flop" USB devicesii usb-modeswitch-data 20150115-1 all mode switching data for usb-modeswitchii usbutils 1:007-2 armhf Linux USB utilities
--
You received this message because you are subscribed to a topic in the Google Groups "weewx-user" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/weewx-user/YSz_IWnzOjE/unsubscribe.
To unsubscribe from this group and all its topics, send an email to weewx-user+unsubscribe@googlegroups.com.
Hello,
I am testing the new versions and unfortunately they do not work for me.
No data from the station but also no error message it seems.
Any help please?
Hi m,
After that line, there is nothing else in the log related to weewx: No errors or any activity recorded.
At that moment, there was just 5 hours of data to read because, as I could not find any error message, I thought it was a station problem so I deleted the station's data log records.
A restart has not solved the problem.
This is the new error message (twice per second):
weewx.service - LSB: weewx weather system
Loaded: loaded (/etc/init.d/weewx)
Active: active (running) since dom 2017-02-12 18:17:30 CET; 3min 10s ago
Process: 4043 ExecStart=/etc/init.d/weewx start (code=exited, status=0/SUCCESS)
CGroup: /system.slice/weewx.service
└─4058 /usr/bin/python /home/weewx/bin/weewxd --daemon --pidfile=/var/run/weewx.pid /home/weewx/weewx.conf
feb 12 18:20:39 raspberrypi weewx[4058]: wmr300: e.errno=None e.strerror=None e.message=could not detach kernel driver from interface 0: No data available repr=USBError('could not detach kernel driver from interface 0: No data available',)
feb 12 18:20:39 raspberrypi weewx[4058]: wmr300: e.errno=None e.strerror=None e.message=could not detach kernel driver from interface 0: No data available repr=USBError('could not detach kernel driver from interface 0: No data available',)
Hi m,
This is the new error message (twice per second):
weewx.service - LSB: weewx weather system
Loaded: loaded (/etc/init.d/weewx)
Active: active (running) since dom 2017-02-12 18:17:30 CET; 3min 10s ago
Process: 4043 ExecStart=/etc/init.d/weewx start (code=exited, status=0/SUCCESS)
CGroup: /system.slice/weewx.service
└─4058 /usr/bin/python /home/weewx/bin/weewxd --daemon --pidfile=/var/run/weewx.pid /home/weewx/weewx.conf
feb 12 18:20:39 raspberrypi weewx[4058]: wmr300: e.errno=None e.strerror=None e.message=could not detach kernel driver from interface 0: No data available repr=USBError('could not detach kernel driver from interface 0: No data available',)
feb 12 18:20:39 raspberrypi weewx[4058]: wmr300: e.errno=None e.strerror=None e.message=could not detach kernel driver from interface 0: No data available repr=USBError('could not detach kernel driver from interface 0: No data available',)
...
On Monday, 13 February 2017 03:26:27 UTC+10, Miguel Iniesta wrote:feb 12 18:20:39 raspberrypi weewx[4058]: wmr300: e.errno=None e.strerror=None e.message=could not detach kernel driver from interface 0: No data available repr=USBError('could not detach kernel driver from interface 0: No data available',)
feb 12 18:20:39 raspberrypi weewx[4058]: wmr300: e.errno=None e.strerror=None e.message=could not detach kernel driver from interface 0: No data available repr=USBError('could not detach kernel driver from interface 0: No data available',)
...This is actually an error in libusb0. From my testing, the error message about "could not detach..." is never cleared from the error string buffer because the condition "no data available" is not regarded as an error condition at some level.
The first time you run weewx after plugging the USB device in, the kernel automatically attaches it (at least it does on my system) and the weewx driver has to detach it to access it in a different mode.The next time (and subsequent times) weewx is run, the detach operation fails because it is no longer attached. This is OK, except for the spurious error message.You should still be getting data occasionally - if not then the wmr300 console has gotten itself tied up in knots and you need to disconnect the USB and start again.
--
You received this message because you are subscribed to a topic in the Google Groups "weewx-user" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/weewx-user/YSz_IWnzOjE/unsubscribe.
To unsubscribe from this group and all its topics, send an email to weewx-user+unsubscribe@googlegroups.com.
A lot of thank's
My stations has been running 40 days and data has nos been transfered to PC.
Weewx has detected ok wmr300 but it is reading records.
I can only read on log: "reading records since *NA**
Is this ok?
how many time could it take?
My stations has been running 40 days and data has nos been transfered to PC.
It is connected to a raspberry pi
Running now fine with last driver.
I has readed data from the datalogger from the wmr-300 installation.
This is OK, but if i disconnect it some time (for example 30 minutes) after starting weewx it begins to log real time data but looses these 30 minutes.
Is this Ok?