It could be that mqtts is not supported. Can you try with “mqtt”.
We just released version 3.0.6. It addressed the SHT issue. Updates through the browser can be made here and github repository is here.
The new version in the Arduino library should also be available in the next 24 hours.
Added support for OpenMetrics
Just to call this out (because that may not be clear to everyone), this does mean that, with the new firmware, the device is now queryable from Prometheus (or any other OpenMetrics-compatible ingestor) out-of-the-box - just add the AirGradient’s address in your Prometheus scrape config and you’re good to go. You don’t need to do stuff like this anymore.
(This only applies to AirGradient ONE though. It would be easy to add the same functionality to the other devices, but I only wrote the code for the ONE because that’s the device I have.)
This did the trick. Now I have to figure out how to use the data in HA
Please share your findings afterwards
OK, so I’m really confused as to why this isn’t pulling all the values in HA. I added the following to my configuration file:
mqtt:
sensor:
name: CO2 basement
state_topic: “airgradient/readings/mysensor”
value_template: “{{ value_json.rco2 }}”
name: pm01 basement
state_topic: "airgradient/readings/mysensor"
value_template: "{{ value_json.pm01 }}"
name: pm02 basement
state_topic: "airgradient/readings/mysensor"
value_template: "{{ value_json.pm02 }}"
name: pm10 basement
state_topic: "airgradient/readings/mysensor"
value_template: "{{ value_json.pm10 }}"
name: pm003_count basement
state_topic: "airgradient/readings/mysensor"
value_template: "{{ value_json.pm003_count }}"
name: tvoc_index basement
state_topic: "airgradient/readings/mysensor"
value_template: "{{ value_json.tvoc_index }}"
name: tvoc_raw basement
state_topic: "airgradient/readings/mysensor"
value_template: "{{ value_json.tvoc_raw }}"
name: nox_index basement
state_topic: "airgradient/readings/mysensor"
value_template: "{{ value_json.nox_index }}"
name: atmp basement
state_topic: "airgradient/readings/mysensor"
value_template: "{{ value_json.atmp }}"
name: rhum basement
state_topic: "airgradient/readings/mysensor"
value_template: "{{ value_json.rhum }}"
name: boot basement
state_topic: "airgradient/readings/mysensor"
value_template: "{{ value_json.boot }}"
It will only create a sensor for the last sensor. If I get rid of the boot line then it’ll create a sensor for the rhum. What am I doing wrong.
For anyone wondering, I got this working on mqtt. I just reordered my statements per what Frk suggested above and it’s now working. Basic format is:
mqtt:
sensor:
- value_template: “{{ value_json.rco2 }}”
name: CO2 basement
state_topic: “airgradient/readings/mysensor”
- value_template: "{{ value_json.pm01 }}"
name: pm01 basement
state_topic: "airgradient/readings/mysensor"
Does this beta firmware allow for a hand-upgraded outdoor air? I removed one of the PM sensors and put in the co2 sensor, and it stopped reporting everything.
Yes. It should work.
Well, it doesn’t I didn’t get any readings, but i also don’t have a tvoc sensor apparently. There’s only some solder points with no headers on my board where it would go.
for now i just put the 2nd particulate matter sensor in it, but when i get some more time, what can i do to troubleshoot?
Did you flash version 3.0.6?
Yeah, I flashed the latest beta version
I have a feature request. It would be nice if I didn’t have to reconfigure wifi after flashing.
Should I just post this as an issue in the github repo?
Agreed. I just had to setup wifi for the 3rd time after trying various beta releases
Hi, I saw the home assistant mail mention configuration from home assistant, and off course the openhab plugin can’t miss this functionality if home assistant has it
For the API it should be simple to add.
For when you communicate directly with the monitors: Are there any plans to add local configuration (led and triggering of calibration) for parity with the API?
Did you have the “erase” checkbox checked during flashing?
I did not check that box
Ok. We will have a look.
No, the erase checkbox was not checked.
Love the MDNS feature in the beta firmwares! There is an added feature I would love for service discoverability (MDNS DNS-SD): Could we add a service which identifies this as an AirGradient device?
I think it is a one line addition:
MDNS.addService("_airgradient", “tcp”, 80);
(having it will make it easy to discover all airgradient sensors in your network and add them automatically to your home automation system)