Two of Same/Similar Model AcuRite 5n1 on Single Host - Station Identification Conflict?

90 views
Skip to first unread message

Patrick Whaley

unread,
Feb 21, 2024, 2:17:24 PMFeb 21
to weewx-user
Hi. I have two AcuRite 5n1 weather stations (model #'s 01536 and 02064), each connected to it's own host computer and successfully running weewx 5.   Additionally they both are setup to upload data to Wunderground, and generate an MQTT topic. One also uploads to CWOP.  

The host computers obtain sensor data via the USB data on the AcuRite display units.

I would prefer to have both weather stations connected to a single host computer, so I attempted to do this via the 'How to run multiple instances of WeeWX' instructions in the link: https://github.com/weewx/weewx/wiki/weewx-multi

Per the instructions I was able to configure weewx to successfully run the stations with the same functionality as when they are connected to dedicated hosts, albeit only one station can be connected to the host computer at a time or I have the issues described below. 

One station's configuration is named 'yardA' (the AcuRite model# 01536 unit) and the other is named 'yardB' (the AcuRite model #02064 unit).

With both stations plugged into the host computers USB ports:
1. When running both 'yardA' and 'yardB' at the same time, both stations report data, but the data that is reported for both stations is exactly the same.

2. When starting only 'yardA', weewx cannot 'pick' the model# 01536 unit versus 'picking' the  model# 02064 unit.  

3. Likewise when starting only 'yardB', weewx cannot 'pick' the model# 02064 unit versus 'picking' the  model# 01536 unit.

I have some suspicion the issue is being caused by using two of the exact same AcuRite sensor units and both connected via USB.

I unplugged/re-plugged both units to USB and ran 'dmesg' to see if there is any distinguishing device information between the two units. Based on this simple test I'm not seeing anything specific that would let weewx distinguish between these two AcuRite's as different devices (although I am far from being knowledgeable on most anything weewx/linux/python/etc.)


[   78.637352] usb 1-1.3: new low-speed USB device number 5 using xhci_hcd
[   78.743717] usb 1-1.3: New USB device found, idVendor=24c0, idProduct=0003, bcdDevice= 0.20
[   78.743738] usb 1-1.3: New USB device strings: Mfr=0, Product=2, SerialNumber=0
[   78.743750] usb 1-1.3: Product: Chaney Instrument
[   78.754195] input: Chaney Instrument as /devices/platform/scb/fd500000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/usb1/1-1/1-1.3/1-1.3:1.0/0003:24C0:0003.0004/input/input5
[   78.754819] hid-generic 0003:24C0:0003.0004: input,hidraw0: USB HID v1.11 Device [Chaney Instrument] on usb-0000:01:00.0-1.3/input0

[   94.512418] usb 1-1.2: new low-speed USB device number 6 using xhci_hcd
[   94.619178] usb 1-1.2: New USB device found, idVendor=24c0, idProduct=0003, bcdDevice= 0.20
[   94.619201] usb 1-1.2: New USB device strings: Mfr=0, Product=2, SerialNumber=0
[   94.619213] usb 1-1.2: Product: Chaney Instrument
[   94.629809] input: Chaney Instrument as /devices/platform/scb/fd500000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/usb1/1-1/1-1.2/1-1.2:1.0/0003:24C0:0003.0005/input/input6
[   94.630554] hid-generic 0003:24C0:0003.0005: input,hidraw3: USB HID v1.11 Device [Chaney Instrument] on usb-0000:01:00.0-1.2/input0  

 I'm grateful in advance for suggestions anyone has on how make my multiple AcuRite station setup work on a single host computer. 
   

vince

unread,
Feb 21, 2024, 2:58:41 PMFeb 21
to weewx-user
Probably depends on your os, but see if you can get there via some os magic. 

pi@pi4:~$ lsusb
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 004: ID 0557:2008 ATEN International Co., Ltd UC-232A Serial Port [pl2303] <=== my serial2usb
Bus 001 Device 002: ID 2109:3431 VIA Labs, Inc. Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub


pi@pi4:~$ ls -lgd /dev/serial/*/*
lrwxrwxrwx 1 root 13 Dec 14 15:55 /dev/serial/by-path/platform-fd500000.pcie-pci-0000:01:00.0-usb-0:1.2:1.0-port0 -> ../../ttyUSB0

I only have one connected usb device but dmesg when I unplug/plug it in looks like:

# run 'dmesg | grep -i usb' and look at the output
[504700.602816] usb 1-1.2: new full-speed USB device number 4 using xhci_hcd
[504700.707235] usb 1-1.2: New USB device found, idVendor=0557, idProduct=2008, bcdDevice= 3.00
[504700.707250] usb 1-1.2: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[504700.707257] usb 1-1.2: Product: USB-Serial Controller
[504700.707263] usb 1-1.2: Manufacturer: Prolific Technology Inc.
[504700.719949] usb 1-1.2: pl2303 converter now attached to ttyUSB0  <=== my serial2usb


My 'guess' is that if you run the same commands you will find two things under /dev/serial with enough differences to tell them apart.  You might need to do this a little experimentally and compare 'dmesg' outputs with one then the other connected.  But you should find unique stable identifiers under /dev/serial to try.

On my ubuntu box I see /dev/serial/by-path used and I use that device in my Home Assistant setup.  Works well there.  I 'suspect' that weewx.conf could handle a /dev/serial/<something> if you could map what's where.

I did find one reference that might help in cooking up udev rules, but it's pretty cryptic unless you read through it a few times.  Then it's only kinda cryptic :-)

matthew wall

unread,
Feb 21, 2024, 3:02:00 PMFeb 21
to weewx-user
hi patrick,

unfortunately, every acurite station looks the same - there is no unique identifier that lets you distinguish one station from another via the USB interface.

if chaney instruments had done it right, they would have burned a serial number into each device, not just idProduct and idVendor.

in lieu of an identifier for each device, another approach is to distinguish devices based on their locations in the usb tree.  if you could do that, then you could conceivably plug them into a usb hub that has ports whose addresses are repeatable across reboots (that might even apply to the usb 'hub' built in to the computer).

i am not sure whether this is possible, but it would be a fun little project to determine the feasibility.  and it is probably easier now that libusb is not as volatile as it was 10 years ago.

when you initiate communication with a HID (which is how the acurite and other usb-based stations present themselves), you specify idProduct and idVendor, then take the first one that shows up.  if a device has a unique identifier, you can match on that too (the ws28xx transceviers are an example of this.  some, but not all, USB-to-serial converters are too, but they are not HID).  it *might* be possible to use the usb tree information to distinguish devices.  or maybe the HID interface lets you enumerate them - not sure whether the libusb and pyusb layers even let you determine whether there are multiple devices that match.

m

p q

unread,
Feb 21, 2024, 3:36:46 PMFeb 21
to weewx...@googlegroups.com
I wonder if it would be easier to use SDR on one sensor unit and USB for the other so that way you know which you're getting. I am not familiar with weewx-multi, so maybe I'm talking crap.



--
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.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/1ef9de61-4b62-4818-8dd1-eec25bade230n%40googlegroups.com.


--
Peter Quinn
(415)794-2264

Patrick Whaley

unread,
Feb 24, 2024, 5:31:25 PMFeb 24
to weewx-user
Thank you all for your quick responses with useful information as you've definitely help direct my efforts.

I spent the last few days setting up a hypervisor ('pimox' aka ProxMox 7) on my raspberry pi 400 (since it's the only spare computer I have that is capable of running VM's), with the intent of running two debian linux VM's, each with their own install of weewx and hopefully being constricted to 'seeing' a single/specified AcuRite system on USB.

ProxMox & debian work/run great, but unfortunately it seems I'm back at/near square one as this does not seem to be able to solve the original problem.

Turns out there are multiple ways to setup USB ports in the VM's , and ways to turn USB ports on/off in linux - I tried all the conventional options and some hacks, but ultimately if I have both AcuRite's hooked to teh pi, and both VM's running weewx, one VM weewx will work and the other VM weewx will not, as it claims it's not receiving USB data from an AcuRite.  Shutting down the working VM frees up (or whatever is going on) the AcuRite usb data for the other VM and it starts working.

I'm going to put this one on the back burner for now but am not throwing in the towel just yet ;-)

-pw   

sab...@gmail.com

unread,
Feb 24, 2024, 5:58:03 PMFeb 24
to weewx-user
While the RPi is not as cheap as they once were, they are perfect little devices to dedicated to a weather station.  I have been using a RPi3B with an acurite console since 2016.  I recently started to move to weewx5 and in the process upgrade it to a 4GB RPi4.  While the RPi3b still works fine, I was impressed with how much faster the RPi4 is.  Building the reasons skin took about half the time.  Currently I still have both Pis set up with different consoles both reading frome the same station until I get the new Pi and Weewx5 set up just how I want it.

Personally I would set up a dedicated pi per acurite station.  😁

vince

unread,
Feb 24, 2024, 6:46:30 PMFeb 24
to weewx-user
Not a proxmix user but this link might be worth a read https://www.wundertech.net/how-to-pass-through-usb-devices-in-proxmox/

Graham Eddy

unread,
Feb 24, 2024, 7:25:07 PMFeb 24
to WeeWX User
i tried proxmox on RPi 4 briefly but it was too unstable for a reliable weather station - proxmox (pimox) is not supported on RPi and known to have problems and limitations (don’t get me started on overlay driver!)

proxmox 8 runs extremely well on bookworm on my mac mini. i pass through a usb-serial adapter to a container running several instances of weewx; my adapter is actually two serial ports not one, but i happily pass through two devices from the one usb port into one container. for encapsulation reasons i do not want and have not tried management of serial ports in a second container
(yes, i could have a container for each weewx instance, but i have some co-dependencies between the instances that make it easier to treat as a group e.g. shared venv, ‘master’ report that binds to all the instance databases, …)
mqtt broker has a container

on mac/proxmox i have had one glitch where the passthrough broke - the perms for the pass-through devices suddenly set to 000 - but until it happens again i don’t have a good handle on it. rebooting the container did not work, rebooting proxmox did work, i was too focussed on getting the station up to properly analyse (these things only happen at very interesting data-gathering moments such as the peaks of storms…)
⊣GE⊢
Reply all
Reply to author
Forward
0 new messages