Author Topic: Ecowitt + Home Assistant  (Read 12818 times)

0 Members and 1 Guest are viewing this topic.

Offline Daali

  • weather n00b
  • Senior Contributor
  • ****
  • Posts: 223
    • The weather in Jefferson, GA
Re: Ecowitt + Home Assistant
« Reply #25 on: February 07, 2022, 12:35:19 PM »
Log file shows the integration starting without an error. Does your log show ecowitt devices? Mine doesn't

You need to have a  /  in the path on WS-VIEW.  It doesn't matter what is in that line as long as it is terminated with a "/"

Offline Donnn

  • Member
  • *
  • Posts: 38
Re: Ecowitt + Home Assistant
« Reply #26 on: February 07, 2022, 12:57:16 PM »
Goooooooooal! I have a device and entities. Thanks.

Since I using the new app, and it shows the / on the page, I assumed it was included. Apparently not. Thanks.

I originally set up my GW1000 on the new Ecowitt iOS app. WS View only shows the mac of my GW1000. I didn't want to delete the pairings and start over.

Apparently the newer app works fine for setting the GW1000

Offline Daali

  • weather n00b
  • Senior Contributor
  • ****
  • Posts: 223
    • The weather in Jefferson, GA
Re: Ecowitt + Home Assistant
« Reply #27 on: February 07, 2022, 01:17:07 PM »
Hey if you are using PoppyPop's updated fork through HACS, for some reason mine did not install the latest.  I had to manually copy over the latest from git in custom components/ecowitt for it to see my soil temp.

Offline Autofill

  • Senior Contributor
  • ****
  • Posts: 290
Re: Ecowitt + Home Assistant
« Reply #28 on: April 18, 2022, 06:28:51 PM »
At the moment, I currently have my GW1100 integrated to HA via garbled1. It works pretty well, minus some log errors for unhandled sensors.

I'd now like to add a second device (while keeping my first device, GW1100, also connected). Do I simply add it via the custom server integration in the WS app (like how the GW1100 was setup)? Will HA recognize it as a a new, second device?

The second device I'd like to add is the GW2000.

Cheers
Ecowitt WH2320-E
Ecowitt HP2551-C (SOLD - replaced with Home Assistant Fully Kiosk FireTab HD10)
Ecowitt GW1000
Ecowitt GW1100
Ecowitt WH69E
Ecowitt WH32B
Ecowitt WH57 (x3)
Ecowitt WH51 (x6)
Ecowitt WH41
Ecowitt WH41 (Honeywell-based USB/Supercap modified)
Ecowitt WH31 (x8)
Ecowitt WH55 (x4)
Ecowitt WH45
Ecowitt WN34S (x2)
Ecowitt WN35
Ecowitt Wittboy running on 12VDC  solar power

Offline Autofill

  • Senior Contributor
  • ****
  • Posts: 290
Re: Ecowitt + Home Assistant
« Reply #29 on: April 30, 2022, 12:10:34 PM »
just wanted to bump this again, the Wittboy box says its "Home Assistant Ready", so, has anybody been able to get the Wittboy to report to Home Assistant, yet?

At the moment, I currently have my GW1100 integrated to HA via garbled1. It works pretty well, minus some log errors for unhandled sensors.

I'd now like to add a second device (while keeping my first device, GW1100, also connected). Do I simply add it via the custom server integration in the WS app (like how the GW1100 was setup)? Will HA recognize it as a a new, second device?

The second device I'd like to add is the GW2000.

Cheers
Ecowitt WH2320-E
Ecowitt HP2551-C (SOLD - replaced with Home Assistant Fully Kiosk FireTab HD10)
Ecowitt GW1000
Ecowitt GW1100
Ecowitt WH69E
Ecowitt WH32B
Ecowitt WH57 (x3)
Ecowitt WH51 (x6)
Ecowitt WH41
Ecowitt WH41 (Honeywell-based USB/Supercap modified)
Ecowitt WH31 (x8)
Ecowitt WH55 (x4)
Ecowitt WH45
Ecowitt WN34S (x2)
Ecowitt WN35
Ecowitt Wittboy running on 12VDC  solar power

Offline Donnn

  • Member
  • *
  • Posts: 38
Re: Ecowitt + Home Assistant
« Reply #30 on: June 09, 2022, 08:30:31 AM »
What's a good solution for checking Ecowit availability in Home Assistant? My GW1000 seems to be reconnected to wifi every 3-6 months. Thanks.

Offline Mandrake

  • Forecaster
  • *****
  • Posts: 1102
Re: Ecowitt + Home Assistant
« Reply #31 on: June 09, 2022, 10:17:59 AM »
just wanted to bump this again, the Wittboy box says its "Home Assistant Ready", so, has anybody been able to get the Wittboy to report to Home Assistant, yet?

At the moment, I currently have my GW1100 integrated to HA via garbled1. It works pretty well, minus some log errors for unhandled sensors.

I'd now like to add a second device (while keeping my first device, GW1100, also connected). Do I simply add it via the custom server integration in the WS app (like how the GW1100 was setup)? Will HA recognize it as a a new, second device?

The second device I'd like to add is the GW2000.

Cheers

Apologies for delays.
I believe that you just need to add a second instance of the Integration into HA running on a different port and it will take the data from the GW2000

I am not sure why Ecowitt are saying Home assistant compatible unless they are writing an integration themselves! The custom integration I am currently importing data from my GW2000 does not understand the Wittboy or any of the newer sensors yet
« Last Edit: June 09, 2022, 10:19:52 AM by Mandrake »
G1ZFO

Ecowitt HP2551A + WH65 Tri-Wing (Wunderground: IGUILDFO67)
Ecowitt GW1000 (Wunderground: IGUILDFO68)
Ecowitt GW1000 (Mk2) test environment driving CumulusMX on a RPi 3b
Ecowitt GW2000 (Test)
Ecowitt WS90 Wittboy - Test
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 -test
Ecowitt WH32-EP (SHT35) + Davis 7714 Screen
Ecowitt WH45 CO2/PM2.5/PM10 -Test
Ecowitt WN34 Soil Temp Sensor -Test
Ecowitt WN34 Water Temp Sensor -Test
Ecowitt WN35 Leaf Moisture

Offline Autofill

  • Senior Contributor
  • ****
  • Posts: 290
Re: Ecowitt + Home Assistant
« Reply #32 on: June 09, 2022, 11:44:16 AM »
thanks @Mandrake for the reply.

Indeed you are correct. If I want more than 1 Ecowitt device reporting, I would have to use a different port.

I have not added the GW2000 to HA yet, for that reason that its not supported yet. Following the Github, it seems the have a semi-wroking PR for the Wittboy

https://github.com/garbled1/homeassistant_ecowitt/pulls

Does anyone know if this integration/script is maintained? It works well and super stable with my GW1100, with the exception of the unhandled sensors, and lightning sensor confirguration which floods my logs, it really just needs some tweaks.
Ecowitt WH2320-E
Ecowitt HP2551-C (SOLD - replaced with Home Assistant Fully Kiosk FireTab HD10)
Ecowitt GW1000
Ecowitt GW1100
Ecowitt WH69E
Ecowitt WH32B
Ecowitt WH57 (x3)
Ecowitt WH51 (x6)
Ecowitt WH41
Ecowitt WH41 (Honeywell-based USB/Supercap modified)
Ecowitt WH31 (x8)
Ecowitt WH55 (x4)
Ecowitt WH45
Ecowitt WN34S (x2)
Ecowitt WN35
Ecowitt Wittboy running on 12VDC  solar power

Offline Mandrake

  • Forecaster
  • *****
  • Posts: 1102
Re: Ecowitt + Home Assistant
« Reply #33 on: June 10, 2022, 06:38:53 AM »
yep, thats the custom integration I am using with my GW2000.
No issues other than the unsupported sensors which flood the logs

I am not sure how well its maintained as I have logged problems and not seen any response and there has no updates in a while
G1ZFO

Ecowitt HP2551A + WH65 Tri-Wing (Wunderground: IGUILDFO67)
Ecowitt GW1000 (Wunderground: IGUILDFO68)
Ecowitt GW1000 (Mk2) test environment driving CumulusMX on a RPi 3b
Ecowitt GW2000 (Test)
Ecowitt WS90 Wittboy - Test
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 -test
Ecowitt WH32-EP (SHT35) + Davis 7714 Screen
Ecowitt WH45 CO2/PM2.5/PM10 -Test
Ecowitt WN34 Soil Temp Sensor -Test
Ecowitt WN34 Water Temp Sensor -Test
Ecowitt WN35 Leaf Moisture

Offline Daali

  • weather n00b
  • Senior Contributor
  • ****
  • Posts: 223
    • The weather in Jefferson, GA
Re: Ecowitt + Home Assistant
« Reply #34 on: June 21, 2022, 02:00:43 AM »
do we just need to update const.py with the missing sensor consts and type defs?  It's currently over my head.

edit: yes.

If you just want to stop the logs from filling up, you can add your unknown sensor type to /ecowitt/const.py IGNORED_SENSORS = [] group after you define it.

my failing unknown type was [runtime].

# added to type definitions section in const.py:
TYPE_RUNTIME = "runtime"

#added to IGNORED_SENSORS = [] group:
    "runtime",

#example:
#   "dewpoint8f",
#    "runtime",
#    DATA_PASSKEY,

« Last Edit: June 21, 2022, 03:06:39 AM by Daali »

Offline Daali

  • weather n00b
  • Senior Contributor
  • ****
  • Posts: 223
    • The weather in Jefferson, GA
Re: Ecowitt + Home Assistant
« Reply #35 on: June 21, 2022, 05:54:43 AM »
I was able to set up runtime as a sensor and a template sensor for parsing the seconds. 

Code: [Select]
# added to type definitions section in \config\custom_components\ecowitt\const.py:
TYPE_RUNTIME = "runtime"

Code: [Select]
# added to SENSOR_TYPES =  section in \config\custom_components\ecowitt\const.py
#
# Name, unit_of_measure, type, device_class, icon, metric=1, state_class
#
    TYPE_RUNTIME: (
        "Runtime",
        None,
        TYPE_SENSOR,
        None,
        "mdi:run-fast",
        0,
        None,
    ),
#
#


This will get you a sensor.runtime with a running seconds total from the device's start.
To see it parsed in weeks, days, hours, minutes, and seconds you can use a template sensor.
Code: [Select]
template:
  - sensor:
      - name: "Ecowitt Uptime Long"
        state: >-
          {%- set uptime  = states.sensor.runtime.state | round -%}
          {%- set sep     = ', ' -%}
          {%- set TIME_MAP = {
                        'week': (uptime / 604800) % 604800,
                        'day': (uptime / 86400) % 7,
                        'hour': (uptime / 3600) % 24,
                        'minute': (uptime / 60) % 60,
                        'second': (uptime % 60)
          }
          -%}

          {%- for unit, duration in TIME_MAP.items() if duration >= 1 -%}
            {%- if not loop.first -%}
              {{ sep }}
            {%- endif -%}
             
            {{ (duration | string).split('.')[0] }} {{ unit }}

            {%- if duration >= 2 -%}
              s
            {%- endif -%}
          {%- endfor -%}

          {%- if uptime < 1 -%}
            just now
          {%- endif -%}

« Last Edit: June 26, 2022, 09:29:15 PM by Daali »

Offline Daali

  • weather n00b
  • Senior Contributor
  • ****
  • Posts: 223
    • The weather in Jefferson, GA
Re: Ecowitt + Home Assistant
« Reply #36 on: June 21, 2022, 11:05:18 AM »
in other news, one of the big boy devs at HomeAssistant is moving to wittboy.  https://twitter.com/pvizeli/status/1538869201288499200

Offline Daali

  • weather n00b
  • Senior Contributor
  • ****
  • Posts: 223
    • The weather in Jefferson, GA
Re: Ecowitt + Home Assistant
« Reply #37 on: June 21, 2022, 11:15:22 AM »
thanks @Mandrake for the reply.

Indeed you are correct. If I want more than 1 Ecowitt device reporting, I would have to use a different port.

I have not added the GW2000 to HA yet, for that reason that it's not supported yet. Following the Github, it seems the have a semi-working PR for the Wittboy

https://github.com/garbled1/homeassistant_ecowitt/pulls

Does anyone know if this integration/script is maintained? It works well and super stable with my GW1100, with the exception of the unhandled sensors, and lightning sensor configuration which floods my logs, it really just needs some tweaks.

He mentions in the 2021 issues log, that he expected the integration to make it to the HA core in 2022.3.  Unfortunately, that did not happen.  Here's to hoping that it makes it and Ecowitt partners with them to ensure it's updated before firmware hits the street.
« Last Edit: June 21, 2022, 11:18:13 AM by Daali »

Offline bigalpha

  • Member
  • *
  • Posts: 27
Re: Ecowitt + Home Assistant
« Reply #38 on: June 21, 2022, 04:07:57 PM »

He mentions in the 2021 issues log, that he expected the integration to make it to the HA core in 2022.3.  Unfortunately, that did not happen.  Here's to hoping that it makes it and Ecowitt partners with them to ensure it's updated before firmware hits the street.

Any idea where we can lend support to having Ecowitt as a core integration?  That would be amazing!

Offline Autofill

  • Senior Contributor
  • ****
  • Posts: 290
Re: Ecowitt + Home Assistant
« Reply #39 on: June 26, 2022, 05:48:56 PM »
I found another Ecowitt/HA intergration. I installed it on another raspberry pi that is bring in my water and gas meter reading to HA via MQTT

Took me 5 minutes to get one running with my GW2000.

https://github.com/bachya/ecowitt2mqtt

Ecowitt WH2320-E
Ecowitt HP2551-C (SOLD - replaced with Home Assistant Fully Kiosk FireTab HD10)
Ecowitt GW1000
Ecowitt GW1100
Ecowitt WH69E
Ecowitt WH32B
Ecowitt WH57 (x3)
Ecowitt WH51 (x6)
Ecowitt WH41
Ecowitt WH41 (Honeywell-based USB/Supercap modified)
Ecowitt WH31 (x8)
Ecowitt WH55 (x4)
Ecowitt WH45
Ecowitt WN34S (x2)
Ecowitt WN35
Ecowitt Wittboy running on 12VDC  solar power

Online olicat

  • Forecaster
  • *****
  • Posts: 1511
  • GWxx00, HPx5x1C, WN1900C, WN1980C & WS3800C
    • FOSHKplugin
Re: Ecowitt + Home Assistant
« Reply #40 on: June 27, 2022, 01:07:23 AM »
Hi!

Quote
another Ecowitt/HA intergration
If MQTT is sufficient to connect HA, this could also be solved via FOSHKplugin that may already exist anyway.
This could then also pass the metric values to HA if required.
Is MQTT sufficient or does native HA integration offer significant advantages?

Oliver

Offline Autofill

  • Senior Contributor
  • ****
  • Posts: 290
Re: Ecowitt + Home Assistant
« Reply #41 on: June 27, 2022, 01:25:31 AM »
MQTT is absolutely sufficient for HA. The conveience of course is having one system do everything, as opposed to having another system doing the work, and dumping the output to another platform like HA. HA has auto discovery and this particular integration supports HA output format (by including the  "--hass-discovery" option when starting the program, otherwise its your standard topic/name format.

Also include this option "--output-unit-system metric" will send metric values to HA.

I just got it to run as a service on my Raspberry Pi and it handles the Wittboy with no problems at all! I really like the garbled1 also, but I'm starting not like all the error messages in my logs for unhandled sensors. Plus, the person who has developed this mqtt-based code, is super responsive to your issues.

If FOSHKplugin has MQTT output option, then yes, this could be a good way (and very common way) to get it into HA

« Last Edit: June 27, 2022, 01:28:56 AM by Autofill »
Ecowitt WH2320-E
Ecowitt HP2551-C (SOLD - replaced with Home Assistant Fully Kiosk FireTab HD10)
Ecowitt GW1000
Ecowitt GW1100
Ecowitt WH69E
Ecowitt WH32B
Ecowitt WH57 (x3)
Ecowitt WH51 (x6)
Ecowitt WH41
Ecowitt WH41 (Honeywell-based USB/Supercap modified)
Ecowitt WH31 (x8)
Ecowitt WH55 (x4)
Ecowitt WH45
Ecowitt WN34S (x2)
Ecowitt WN35
Ecowitt Wittboy running on 12VDC  solar power

Online olicat

  • Forecaster
  • *****
  • Posts: 1511
  • GWxx00, HPx5x1C, WN1900C, WN1980C & WS3800C
    • FOSHKplugin
Re: Ecowitt + Home Assistant
« Reply #42 on: June 27, 2022, 01:46:59 AM »
Hi!

Quote
If FOSHKplugin has MQTT output option, then yes, this could be a good way (and very common way) to get it into HA
FOSHKplugin has also a MQTT output option.
All sensors are supported, additional values are calculated (min/max, cloud height, sun hours, dew point, ...) and status messages (battery alarm, thunderstorm alarm, storm alarm, ...) are also output via MQTT.
It would be nice if an HA user could test and confirm this. I do not use HA here myself.

Oliver

Offline Autofill

  • Senior Contributor
  • ****
  • Posts: 290
Re: Ecowitt + Home Assistant
« Reply #43 on: June 27, 2022, 08:42:04 AM »
Hi Oliver,

It sounds like FOSHKplugin has everything we need!

I was just reading how to install FOSHKplugin and looks like I need a dedicated RPi to run Loxberry, is this correct?

If so, I won't have an option now to test it as I don't have an extra RPi laying around. I would really like to try this so, once some RPi come in stock at my supplier, I can give it a go!

Can I install this on a Windows computer?
Ecowitt WH2320-E
Ecowitt HP2551-C (SOLD - replaced with Home Assistant Fully Kiosk FireTab HD10)
Ecowitt GW1000
Ecowitt GW1100
Ecowitt WH69E
Ecowitt WH32B
Ecowitt WH57 (x3)
Ecowitt WH51 (x6)
Ecowitt WH41
Ecowitt WH41 (Honeywell-based USB/Supercap modified)
Ecowitt WH31 (x8)
Ecowitt WH55 (x4)
Ecowitt WH45
Ecowitt WN34S (x2)
Ecowitt WN35
Ecowitt Wittboy running on 12VDC  solar power

Online olicat

  • Forecaster
  • *****
  • Posts: 1511
  • GWxx00, HPx5x1C, WN1900C, WN1980C & WS3800C
    • FOSHKplugin
Re: Ecowitt + Home Assistant
« Reply #44 on: June 27, 2022, 08:56:44 AM »
Hi!

Quote
I was just reading how to install FOSHKplugin and looks like I need a dedicated RPi to run Loxberry, is this correct?
No, you don't need a separate LoxBerry nor a LoxBerry installation at all.
The generic version of FOSHKplugin is able to run as a (parallel) service on any 24/7 Linux computer which may already serve other things.
The installation process is quite simple.

On Windows it only runs within a WSL (Windows Subsystem for Linux) - so it needs a Linux as the base.

Oliver

Offline bigalpha

  • Member
  • *
  • Posts: 27
Re: Ecowitt + Home Assistant
« Reply #45 on: June 27, 2022, 05:00:34 PM »
I found another Ecowitt/HA intergration. I installed it on another raspberry pi that is bring in my water and gas meter reading to HA via MQTT

Took me 5 minutes to get one running with my GW2000.

https://github.com/bachya/ecowitt2mqtt



Does this one create a device with the entities grouped under it?  Are there data that ecowitt creates from the raw sensor values that wouldn't be captured by the MQTT output?  Versus the reading from the weather station hardware?  Like, does the console/Gateway crunch data then creates a new data point that is not output by the weather station hardware?  Hopefully that makes sense.

Offline Autofill

  • Senior Contributor
  • ****
  • Posts: 290
Re: Ecowitt + Home Assistant
« Reply #46 on: June 27, 2022, 05:41:38 PM »
yes, it creates one device (GW2000 for example) with all the entities below it, for example here is mine:

 [ You are not allowed to view attachments ]

According to the documentation, you can have raw data also if you use the "--raw-data" config keyword. see this:

https://github.com/bachya/ecowitt2mqtt#raw-data

I presonally use the crunched data because I have some offsets in GW2000.

By the way, if you are using metric, include the meteric keyword before you feed it to HA because i oringally had imperial and then switched to metric and HA complained later that the entities had wrong units, so include this "--output-unit-system metric"
Ecowitt WH2320-E
Ecowitt HP2551-C (SOLD - replaced with Home Assistant Fully Kiosk FireTab HD10)
Ecowitt GW1000
Ecowitt GW1100
Ecowitt WH69E
Ecowitt WH32B
Ecowitt WH57 (x3)
Ecowitt WH51 (x6)
Ecowitt WH41
Ecowitt WH41 (Honeywell-based USB/Supercap modified)
Ecowitt WH31 (x8)
Ecowitt WH55 (x4)
Ecowitt WH45
Ecowitt WN34S (x2)
Ecowitt WN35
Ecowitt Wittboy running on 12VDC  solar power

Offline Autofill

  • Senior Contributor
  • ****
  • Posts: 290
Re: Ecowitt + Home Assistant
« Reply #47 on: June 27, 2022, 05:47:40 PM »
You're right, that is simple enough to install, the instructions are there line-by-line.

Ok, im going to see if I have enough overhead on the same pi that im already running two mqtt services and try it out.


Hi!

Quote
I was just reading how to install FOSHKplugin and looks like I need a dedicated RPi to run Loxberry, is this correct?
No, you don't need a separate LoxBerry nor a LoxBerry installation at all.
The generic version of FOSHKplugin is able to run as a (parallel) service on any 24/7 Linux computer which may already serve other things.
The installation process is quite simple.

On Windows it only runs within a WSL (Windows Subsystem for Linux) - so it needs a Linux as the base.

Oliver
« Last Edit: June 27, 2022, 09:26:02 PM by Autofill »
Ecowitt WH2320-E
Ecowitt HP2551-C (SOLD - replaced with Home Assistant Fully Kiosk FireTab HD10)
Ecowitt GW1000
Ecowitt GW1100
Ecowitt WH69E
Ecowitt WH32B
Ecowitt WH57 (x3)
Ecowitt WH51 (x6)
Ecowitt WH41
Ecowitt WH41 (Honeywell-based USB/Supercap modified)
Ecowitt WH31 (x8)
Ecowitt WH55 (x4)
Ecowitt WH45
Ecowitt WN34S (x2)
Ecowitt WN35
Ecowitt Wittboy running on 12VDC  solar power

Offline Daali

  • weather n00b
  • Senior Contributor
  • ****
  • Posts: 223
    • The weather in Jefferson, GA
Re: Ecowitt + Home Assistant
« Reply #48 on: June 27, 2022, 10:37:04 PM »
a dockerized version of FOSHKPlugin as an HomeAssistant addon would be awesome.

Offline Autofill

  • Senior Contributor
  • ****
  • Posts: 290
Re: Ecowitt + Home Assistant
« Reply #49 on: August 31, 2022, 12:46:16 PM »
Ecowitt is now an official integration as of 2022.9


https://next.home-assistant.io/integrations/ecowitt/
Ecowitt WH2320-E
Ecowitt HP2551-C (SOLD - replaced with Home Assistant Fully Kiosk FireTab HD10)
Ecowitt GW1000
Ecowitt GW1100
Ecowitt WH69E
Ecowitt WH32B
Ecowitt WH57 (x3)
Ecowitt WH51 (x6)
Ecowitt WH41
Ecowitt WH41 (Honeywell-based USB/Supercap modified)
Ecowitt WH31 (x8)
Ecowitt WH55 (x4)
Ecowitt WH45
Ecowitt WN34S (x2)
Ecowitt WN35
Ecowitt Wittboy running on 12VDC  solar power

 

anything