coding-lemur / co2-meter-esp32

Measures the CO2 level in the room and gives a warning when to ventilate. All values are also distributed via MQTT.
MIT License
10 stars 0 forks source link

Can't compile without warnings #1

Closed joopy closed 2 years ago

joopy commented 2 years ago

Using Atom with platform IO. What SoftwareSerial library needs to be installed?

Keep getting compile errors.

coding-lemur commented 2 years ago

Hey Joopy. Thanks for contacting me. I also noticed your Youtube comment on my channel :)

I fixed the problem with the missing SoftwareSerial dependency. Hope that helps.

Best regards

René

joopy commented 2 years ago

Hey René,

Thanks for the help! compiling is working so that's great. Config true webinterface and connecting to mqtt (home assistant) is working. But the json payload is not compleet:

{"version":"1.0.0","system":{"deviceId":"ccf95b","freeHeap":235316},"network":{"wifiRssi":-50,"wifiQuality":100,"wifiSsid":"secretssid","ip":"192.168.1.18"},"co2":{"isPreheating":false,"isReady":false}}

Can you enlight me?

Best regards jeroen

joopy commented 2 years ago

isReady is not true. But display is working and showing co2 ppm

coding-lemur commented 2 years ago

Hey Joopy. Happy new year :)

I'm in trouble at end of the year like everyone. But today I found time to fix the error: I removed the caches for sensor values and read the values live on generating the JSON result. So it should be correct.

Hope that helps. Happy coding & best regards :)

René

coding-lemur commented 2 years ago

I tested the original isReady value from the MZ library. But dosn't understand when it's TRUE. It's always FALSE. But the sensor value and isPreheating works :)

coding-lemur commented 2 years ago

in v1.1.3 I removed the isReady field from JSON. So it's only important to check isPreheating field (while TRUE the sensor value is still 0) :)

joopy commented 2 years ago

in v1.1.3 I removed the isReady field from JSON. So it's only important to check isPreheating field (while TRUE the sensor value is still 0) :)

Yes it's working correctly now.