letscontrolit / ESPEasy

Easy MultiSensor device based on ESP8266/ESP32
http://www.espeasy.com
Other
3.26k stars 2.21k forks source link

[BUG] BMx280 not reporting values via P2P Networking #4811

Closed hrikken closed 11 months ago

hrikken commented 1 year ago

Describe the bug When I post BMP280 values via the BMx280 plugin to the p2pnetworking controller, these values are not shown (always 0) on the other peer units. All other sensors (like SDS011, SDC41, SHT41) are working fine on the peers!

To Reproduce Steps to reproduce the behavior:

  1. Enable P2P Networking on the nodes
  2. Add the BMP280 device at position 32
  3. Send the values to the P2P controller
  4. Go to the second controller and add the remote sensor
  5. You'll see the sensor but only 0-values are shown. All other connected sensors on the remote unit show the right values

Expected behavior Id expect to see the measurements of the remote BMP280 sensor but I only see 0-values

Screenshots Obvious

Used platform (please complete the following information):

Platform Specifics (when applicable, please complete the following information):

Additional context Add any other context about the problem here.

TD-er commented 1 year ago

This has been fixed by Ton and has been merged yesterday. However we discovered a new bug caused by this merge, so I still have to fix that before I can give you a new build to test this.

tonhuisman commented 1 year ago

That was a bug that has been fixed in a recent PR, just hasn't been released yet. Can you test using this recent branch build that has the fix included?

Edit: This paragraph of the documentation is what you'll need to get it set up.

hrikken commented 1 year ago

Sorry guys. Doesn't work. Even got worse with this build: the SHT41 stopped working as well. Keep in mind that this has no urgency for me. I flashed both the ESP32-S and the regular ESP32 with the new binairies.

tonhuisman commented 1 year ago

the SHT41 stopped working as well

Can you please elaborate on that? What is not working here? The sensor readings, or transferring the read data to a remote unit?

hrikken commented 1 year ago

Ok sorry. I have an ESP32 (climate binairy) with 3 x I2C sensors, 1 remote (P2P) PM sensor and 1 display: SHT41, SCD41, BMP280 and a Oled 1106 display. I add the PM sensor via P2P on position 29, the I2C sensors on position 30 - 32 and the display on position 1. I add a P2P controller and publish the data of the I2C sensors to the P2P network.

On the other ESP32 I add all remote P2P sensors on positions 29 - 32. The data of the dust sensor and the SCD41 get in but the data of the SHT41 and BMP280 don't arrive. Before I flashed your new binairy the data of the SHT41 came in as well.

hrikken commented 1 year ago

Update: it's not a SHT41 but a SHT40

tonhuisman commented 1 year ago

Update: it's not a SHT41 but a SHT40

Ah, that's a good clue, I know where to look, will fix later today (after work 😉)

tonhuisman commented 1 year ago

Hmm, I just (partly) recreated your setup, though only used the SHT4x (connected a SHT45, but the only difference between the SHT40/41/45 is the resolution), an ESP32-S2 and an ESP32-C3, both using the Climate build. After enabling the P2P controller and saving the device on the sending side, and of course enabling the newly added task on the receiving side, the data was coming in at the receiving side as intended. I've used the same branch you downloaded the test-build from.

For now I see no reason to change any code, as it works as intended.

It's not a prerequisite, but are both ESPs using the same build (they may use different types of ESP, like I did, just install the matching binaries)? As the fix for the BMx280 has only been merged very recently, you'll have to upgrade at least the receiving side (for the BMx280 to work as intended), but preferably both.

hrikken commented 1 year ago

Hi Ton. I' m gonna make a setup wit two of the same ESP's and will try it again. Will be early next week. I'll keep you posted. Thanks for your effort Tom! Much appreciated.

TD-er commented 1 year ago

Could you test this with the latest code? For example this GH Actions build: https://github.com/letscontrolit/ESPEasy/actions/runs/6331716363

hrikken commented 1 year ago

Ok. I'll do and will keep you posted.

iz8mbw commented 11 months ago

@hrikken can this be closed?

hrikken commented 11 months ago

Sorry for the late response. Couldn’t reproduce it in a fresh setup. When I run into it again I’ll be in contact.

tonhuisman commented 11 months ago

Couldn’t reproduce it in a fresh setup.

So this issue is resolved, and can be closed?

hrikken commented 11 months ago

Ok.