Author Topic: Headless, wired hardware for Raspberry Pi WeeWx station  (Read 485 times)

0 Members and 1 Guest are viewing this topic.

Offline LordRatner

  • Member
  • *
  • Posts: 6
Headless, wired hardware for Raspberry Pi WeeWx station
« on: October 19, 2021, 06:45:22 AM »
Good morning!

Short version, I'm putting together an irrigation system for fruit trees that will use the cumulative rainfall over a set period to control how much and how often the trees are watered. So I want to track the actual rainfall at the tree's location. Because I'm already using Raspberry Pis for the irrigation control and home automation, WeeWx seems like a great fit.

For the hardware, I really only *need* the rain gauge, but I want to start with wind speed and direction, temp, and humidity as well, while retaining the option to expand the system in the future. Similarly, I'm willing to pay for a good product (let's say $500 for the hardware), but I only need strong accuracy from the rain gauge. If the wind speed is off by a couple knots or the temp is a degree or two off, I can live with that if it will save significant resources.

The whole system will be powered by a 20 watt solar panel and battery.

I'd like the hardware to be wired to minimize the number of wifi connections, since I'm borrowing wifi from a neighbor. As I understand it, the HW1000 uses it's own wifi connection to communicate with WeeWx, so that's probably out unless there aren't other good options. I would also want the hardware powered by a wired connection (DC, not AC) instead of an internal battery, since the solar system will power everything in the shed. Bonus points for hardware that easily connects to a Raspberry Pi Zero W. Powered by USB would be best, but not at all necessary. I can provide DC power from 3.3-12v.

I also don't need a display, since the home automation will cover that. If the ideal units include displays, so be it, but I'd rather apply the cost to the sensor hardware.

Thanks for the help, the hardware selection is a bit daunting on account of the many options.

-Seth
« Last Edit: October 19, 2021, 06:48:55 AM by LordRatner »

Offline davidmc36

  • He who dies with the most toys wins!
  • Forecaster
  • *****
  • Posts: 840
  • FN25ie61jw
    • MorewoodW34
Re: Headless, wired hardware for Raspberry Pi WeeWx station
« Reply #1 on: October 19, 2021, 07:09:46 AM »
Davis Wired Sensor Suite comes with like 100 foot "phone" cable through which it is powered and sends back data. But that is done hooked to the display console (not cheap). From there wired connection to a RPI is possible.

Not an inexpensive solution but covers some of your bigger points.

I'm a Davis guy so some others may have other ideas on other brands.

Offline LordRatner

  • Member
  • *
  • Posts: 6
Re: Headless, wired hardware for Raspberry Pi WeeWx station
« Reply #2 on: October 19, 2021, 02:54:00 PM »
I was looking at the Rainwise Wired Rain Gauge as a possible option, but I don't know how that would interface with WeeWx. Does anyone have experience with this?

Offline vinceskahan

  • Senior Member
  • **
  • Posts: 75
    • home site
Re: Headless, wired hardware for Raspberry Pi WeeWx station
« Reply #3 on: October 20, 2021, 06:12:39 PM »
Perhaps buy a Vue sensor suite and sniff the RF with weewx and a RTL-SDR dongle ?    That gets you a full station under $300 or so if you already have the pi.   (see the weewx-users and weewx-development google groups for mention of folks doing that)

Link to the driver is https://github.com/lheijst/weewx-rtldavis
WeeWX sites:
  Davis VP2+DFARS to a Seagate Dockstar (pogoplug)
  EcoWitt GW1000, WH32 outdoor T+H, multiple WH31 indoor T+H, WH51 soilMoisture (docker)
Home site:        https://www.skahan.net/
Wunderground: KWAFEDER15
PWS:                KWFEDER15
CWOP:             CW6881

Offline johnd

  • Forecaster
  • *****
  • Posts: 4256
    • www.weatherstations.co.uk
Re: Headless, wired hardware for Raspberry Pi WeeWx station
« Reply #4 on: October 21, 2021, 07:09:09 AM »
@LordRatner: I do think you're potentially overlooking what the various circuits in a weather station do. Configurations very of course among different makes/models, but in a Davis station (which is not atypical) there are 3 different locations in the data-handling chain where different circuits/devices etc are involved:

1. Where the sensors interface to a module responsible for collating the raw data reading, which it typically outside near to the sensors. The individual sensors may have an analogue interface or digital (eg I2C or SPI) interface - not sure whether you classify pulse/contact-closure such as from a rain gauge or anemometer speed sensor as analogue or digital, but digital perhaps since it's effectively pulse counting. This sensor interface module (SIM) then relays the data back to some other device (often indoors) via wireless or cable and in some defined, though not necessarily public, format, which is responsible for further processing.

2. The receiver unit for the raw data from [1], eg a console unit in a Davis set-up. This receiver unit has more power and more communications options and can process and store the raw data from the SIM in more familiar and digested or summary form. This receiver unit can also keep tracked of derived parameters such daily rainfall, rezeroed at midnight or whenever. The receiver (+logger) will also be able to pass data on request to an external computer in a public format and across a known interface such as serial or USB or Ethernet.

3. The external computer which, being more powerful again, can perform tasks like generating webpages, managing SQL databases for long-term data storage, uplaoding data to remote servers etc etc.

(Sometimes [2] and [3] can be combined into a single unit or as a console + enhanced logger. So the architecture can vary quite a lot in detail.)

So there's no problem in principle with interfacing sensors directly to a suitable computer (a Raspberry Pi maybe), but you're then responsible for writing the input code for that particular sensor. Existing weather station software such as weewx will not provide this low-level interface but will typically be designed to accept the output from console/logger, ie [2] in the description above. So what you want to do is certainly totally feasible, but I'm not aware of any software that has direct sensor inputs.
Prodata Weather Systems
Prodata's dedicated Davis EnviroMonitor website
UK Davis Premier Dealer - All Davis stations, accessories and spares
Cambridge UK

Sorry, but I have no time to help with individual issues by email. Please post your issue in the relevant forum section here & I will comment there if I have anything useful to add.

Offline LordRatner

  • Member
  • *
  • Posts: 6
Re: Headless, wired hardware for Raspberry Pi WeeWx station
« Reply #5 on: October 21, 2021, 11:16:01 AM »
@LordRatner: I do think you're potentially overlooking what the various circuits in a weather station do. Configurations very of course among different makes/models, but in a Davis station (which is not atypical) there are 3 different locations in the data-handling chain where different circuits/devices etc are involved:

1. Where the sensors interface to a module responsible for collating the raw data reading, which it typically outside near to the sensors. The individual sensors may have an analogue interface or digital (eg I2C or SPI) interface - not sure whether you classify pulse/contact-closure such as from a rain gauge or anemometer speed sensor as analogue or digital, but digital perhaps since it's effectively pulse counting. This sensor interface module (SIM) then relays the data back to some other device (often indoors) via wireless or cable and in some defined, though not necessarily public, format, which is responsible for further processing.

2. The receiver unit for the raw data from [1], eg a console unit in a Davis set-up. This receiver unit has more power and more communications options and can process and store the raw data from the SIM in more familiar and digested or summary form. This receiver unit can also keep tracked of derived parameters such daily rainfall, rezeroed at midnight or whenever. The receiver (+logger) will also be able to pass data on request to an external computer in a public format and across a known interface such as serial or USB or Ethernet.

3. The external computer which, being more powerful again, can perform tasks like generating webpages, managing SQL databases for long-term data storage, uplaoding data to remote servers etc etc.

(Sometimes [2] and [3] can be combined into a single unit or as a console + enhanced logger. So the architecture can vary quite a lot in detail.)

So there's no problem in principle with interfacing sensors directly to a suitable computer (a Raspberry Pi maybe), but you're then responsible for writing the input code for that particular sensor. Existing weather station software such as weewx will not provide this low-level interface but will typically be designed to accept the output from console/logger, ie [2] in the description above. So what you want to do is certainly totally feasible, but I'm not aware of any software that has direct sensor inputs.

Thank you for the detailed response! I've learned a bunch from posts like yours (and yours of course).

In a way I ended up with two problems to solve. I went with the Rainwise RAINEW111 wired rain gauge, which just has two wires coming out from it. This falls into [1] of the chain you described. I'm working on a service for WeeWx that should be able to count the pulses and add them to whatever driver I end up using for the rest of the weather station.

What I was hoping for was a bit of a unicorn I suppose. Wired [2] --> RPi/Weewx [3] without the cost of a big (and unnecessary) console. I *love* the GW1100 [2] concept and price. And it works well with what seem to be reasonably effective and very affordable weather stations, such as the ECOWITT WS80 and WS68 (I only need the rain gauge to be very accurate). My only complaint is that it communicates with WeeWx (or anything else) over WiFi. I was hoping it could interface with WeeWx over USB, since it is powered that way anyhow. I want to limit the wifi connections from the system, but it looks like I may not have many options unless I want to spend a lot of money on the hardware.

I may just have to deal with the extra wifi connection of the GW1100. It's exactly what I want (affordable and simple [2] receiver unit, minus the wifi. And Ecowitt seem to be the go-to for reasonably accurate sensors at a very reasonable price.


Offline Mandrake

  • Forecaster
  • *****
  • Posts: 1052
Re: Headless, wired hardware for Raspberry Pi WeeWx station
« Reply #6 on: October 27, 2021, 11:21:58 AM »
If you are running the weewx on your RPi, then you can always have that as your hot spot for the wifi so that the GW1000/1100 is just talking to the RPi and not actually connected to a whole network/Internet if thats what you are trying to avoid!
Retired: Old Maplin N96Y/FO Weather station
G1ZFO

Ecowitt HP2551A + WH65 Tri-Wing (Wunderground: IGUILDFO67)
Ecowitt GW1000 (Wunderground: IGUILDFO68)
Ecowitt GW1000 (Mk2) test environment driving CumulusMX on a RPi 3b
Ecowitt WH51 (x6) Soil Moisture Sensor
Ecowitt WH41 PM2.5 AQM Sensor
Ecowitt WH31 (x8) Thermo/Hygro Sensor
Ecowitt WS80 Ultrasonic Anemometer (pre-prod test)
Ecowitt WH57 Lightning Sensor (pre-prod test)
Ecowitt WH32-EP (SHT35) + Davis 7714 Screen
Ecowitt WH45 CO2/PM2.5/PM10 (production Test)
Ecowitt WN34 Soil Temperature Sensor -Test
Ecowitt WN34 Water Temperature Sensor -Test

Offline jbroome

  • Member
  • *
  • Posts: 21
Re: Headless, wired hardware for Raspberry Pi WeeWx station
« Reply #7 on: November 01, 2021, 11:07:22 PM »
{ ... } I *love* the GW1100 [2] concept and price. And it works well with what seem to be reasonably effective and very affordable weather stations, such as the ECOWITT WS80 and WS68 (I only need the rain gauge to be very accurate). My only complaint is that it communicates with WeeWx (or anything else) over WiFi. I was hoping it could interface with WeeWx over USB, since it is powered that way anyhow. I want to limit the wifi connections from the system, but it looks like I may not have many options unless I want to spend a lot of money on the hardware.

I may just have to deal with the extra wifi connection of the GW1100. It's exactly what I want (affordable and simple [2] receiver unit, minus the wifi. And Ecowitt seem to be the go-to for reasonably accurate sensors at a very reasonable price.

You can let the GW1100 keep its own access point running, and then your Rapsberry Pi simply associates with the GW1100's access point, and you pull data over that Wi-Fi link.  To be more specific, if your GW1100 has (for example) the SSID "GW1100-WIFIC940", you set up your wpa_supplicant.conf file to connect to that SSID (with "key_mgmt=NONE").  Your Pi should get an IP address on the 192.168.4 network using DHCP, or you can manually configure it to a particular 192.168.4.x address.  From that point onward, your software can simply talk to the GW1100 at the IP address 192.168.4.1, and you should be good.  You don't need any additional hardware, and you're not using your neighbor for any of this.  (I use a similar method to perform initial configuration of a new GW1x00 device - manually connect to the SSID, then send the configuration commands to 192.168.4.1.)

   ---Jonathan
Collector of Ecowitt and related gizmos:
GW1000 x4 (both 915 MHz and 433 MHz)
GW1100 x1
WH31
WH31P
WH32E
WH32B
WH34BS
WH34BL
WN35
WH40
WH41
WH45
WH51
WH55
WH57
WH65B
WH68
(and probably more that I've forgotten)