koenvervloesem / ESPHome-Air-Quality-Monitor

ESPHome configuration for a DIY indoor air quality monitor for CO₂ concentration, PM2.5 and PM10 concentrations, and temperature, humidity and pressure
https://koenvervloesem.github.io/ESPHome-Air-Quality-Monitor
MIT License
91 stars 11 forks source link

Need more assistance #7

Open madebywitteveen opened 1 year ago

madebywitteveen commented 1 year ago

Hi Koen,

Can you help me out please? Created this folder config/esphome/common containing 4 yaml files: base, aqi, bme280 & mh-z19b. in the yaml config for the ESP8266 the packages not used are # (out). still getting al kinds of errors but can't find the issue. When trying to transfer the configuration to the ESP: _Couldn't find ID 'pm2_5value' _Couldn't find ID 'pm10value' _Couldn't find ID 'show_calibrating'. Please check you have defined an ID with that name in your configuration. These IDs look similar: "co2_calibrate", "co2calibrated"

I'm using the d1_mini wemos.

and more of those like that,

can you give me a hint please ?

thanks

H

koenvervloesem commented 1 year ago

It's best to copy all YAML files from the common directory. For instance, the errors about the pm values are because these are defined in the sds011.yaml file.

madebywitteveen commented 1 year ago

Thanks Koen, that helped. It is working (I think ) set it to calibrate, see what happens tomorrow What is the calibration time roughly ? best regards, H

koenvervloesem commented 1 year ago

Calibration is done for 20 minutes: https://github.com/koenvervloesem/ESPHome-Air-Quality-Monitor/blob/acff085bf7ee94120aadeeb3bae73f3d337e15e5/common/mh-z19b.yaml#L74

madebywitteveen commented 1 year ago

Hi Koen, Can't get it working; The code reverts back to different yaml than the one is uploaded?! Can't figure out why this is happening:

1: create a new ESPHOME device with the code what's in here : koenvervloesem/ESPHome-Air-Quality-Monitor/esphome-air-quality-monitor-esp8266.yaml. 2: made some adjustments to this code for logging and WIFI 3: upload this yaml to the 8266 4: device is not getting online 5: ESPhome detects a new device ! 6: Click adopt to add this new one to ESPhome 7: After adopt and install the device is online but the yaml code is different ?! 8: yaml code is now (below): 9: this isn;t working because the pin declarations in the online version are different than my esp 10: how to stick with the yaml I uploaded first ??

_substitutions: name: esphome-airquality-c00b8d friendly_name: AIRQUALITY c00b8d packages: koenvervloesem.air-quality-monitor: github://koenvervloesem/ESPHome-Air-Quality-Monitor/esphome-air-quality-monitor-esp8266.yaml@main esphome: name: ${name} name_add_mac_suffix: false friendly_name: ${friendly_name} api: encryption: key: "......blablabla......"

wifi: ssid: !secret wifi_ssid password: !secret wifipassword _

koenvervloesem commented 1 year ago

I'm not sure what is going wrong.

If you have exactly the same configuration as in the table, with an MH-Z19B connected to the ESP8266, then you could try the web-based firmware installer for this project. This requires Chrome or Edge.

madebywitteveen commented 1 year ago

Thanks,

I'm using the d1_mini thus the pinout is different. Could you do me a favor ? Can you write me a yaml for d1_mini containing only the code for the mhz19b without the packages?

Also getting this error:

You're_ using the same serial port for logging and the UART component. Please disable logging over the serial port by setting logger->baud_rate to 0

But I can't disable the logging because improv serial needs it

can I buy you a coffee ?

thanks

H

koenvervloesem commented 1 year ago

Now that I'm reading your previous message again, I think what's happening is that you changed the esphome-air-quality-monitor-esp8266.yaml file with the pinout of your D1 mini, right? But you kept these two lines with the dashboard import:

dashboard_import:
  package_import_url: github://koenvervloesem/ESPHome-Air-Quality-Monitor/esphome-air-quality-monitor-esp8266.yaml@main

So that's why the code reverts back to the one for the NodeMCU. So if you delete those two lines in your YAML file, I expect that you're closer to a solution :-) Can you give this a try?

madebywitteveen commented 1 year ago

Yes thanks Koen,That is the trick.But; found out that the MH-Z19B sensor does only work with nodemcu ESP not with others.Has something to do with the double use of the UART/FTDI combination. Lots of people having this issue. Don't now whether you chose the nodemcu bij coincidence?Anyway,  I'm copying your entire project thus I ordered a nodemcu for myself.Thanks -------- Original message --------From: Koen Vervloesem @.> Date: 05/06/2023 08:41 (GMT+01:00) To: koenvervloesem/ESPHome-Air-Quality-Monitor @.> Cc: @.>, Author @.> Subject: Re: [koenvervloesem/ESPHome-Air-Quality-Monitor] Need more assistance (Issue #7) Now that I'm reading your previous message again, I think what's happening is that you changed the esphome-air-quality-monitor-esp8266.yaml file with the pinout of your D1 mini, right? But you kept these lines: https://github.com/koenvervloesem/ESPHome-Air-Quality-Monitor/blob/main/esphome-air-quality-monitor-esp8266.yaml#L23-L24 So that's why the code reverts back to the one for the NodeMCU. So if you delete those two lines in your YAML file, I expect that you're closer to a solution :-) Can you give this a try?

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you authored the thread.Message ID: @.***>

koenvervloesem commented 1 year ago

Oh it's just that I had one of those NodeMCU boards at hand, so yes that was a coincidence.