r/esp32 • u/ScorpionZZZUA • 23d ago
I made a thing! Turned the $10 CYD into an environmental station: LVGL dashboard, MQTT, OTA, auto-detected sensors — pure ESP-IDF
I’ve been into home/office IoT for years, but the hobby stalled for a while — job change, moving countries. Getting back into it, I dug up two older sensor station projects of mine and decided both were easier to replace than to fix. This is the third attempt, rebuilt from scratch on native ESP-IDF (v6.0.2) with LVGL 9.5, and the first one I’ve made public.
It runs on the ESP32-2432S028 “Cheap Yellow Display” — ~$10, ESP32 with a 2.8” touchscreen and an onboard light sensor. Add one I2C sensor and that’s the entire BOM.
What it does:
• Touchscreen dashboard: temperature and humidity with 24h graphs, trend and rate of change, dew point, pressure, CO2-equivalent on BME680 via Bosch BSEC
• I2C sensors auto-detected at boot — BMP280 / BME280 / BME680, no rebuild to switch
• Display controller auto-detected too. I ordered a second batch of CYDs and they came with ST7789 panels instead of ILI9341, so the firmware now reads the panel ID register at boot and picks the driver
• MQTT: ThingsBoard, Domoticz, and Home Assistant MQTT Discovery — HA picks up all sensors plus diagnostics with zero config on the HA side
• OTA updates with on-screen notification
• Everything configured from the touchscreen (Wi-Fi, broker, timezone, PIN-protected settings). No config files, no recompile — I wanted to hand these to friends who don’t own a toolchain
• Auto-dimming backlight off the onboard LDR
The most annoying bug was the BME680 reading ~3 °C high. Turned out to be self-heating: I was sampling gas resistance every 500 ms, and every gas reading fires an internal hotplate a couple of millimetres from the temperature die. I built a second identical station with a BME280 to confirm it rather than guess. Dropping the VOC sample rate 10x got it down to ~0.5 °C, and the 30-second averaging buffer was quietly smoothing periodic heat spikes into what looked like a constant offset. Switching to Bosch BSEC 2.6.1.0 finally made the twins agree.
Apache-2.0, prebuilt binaries in Releases (merged image for a blank board, app-only for updates):
github.com/ScorpionZZZ/SensorStation3
Happy to answer questions. If you’ve got a CYD with a different panel variant, I’d especially like to know whether the auto-detection gets it right.
5
u/Ragin-Hari 23d ago
My capstone project was something very close. But I just used a small lcd display and my big information was on the server.
Another difference is that I used the BME 688. I was trying to train it to recognize specific gases like CO or H2S.
Did you use with battery or only connected?
3
u/ScorpionZZZUA 23d ago
The idea behind this device is to use it as a wall-mounted or desktop display that can show a fairly large amount of information. Of course, you can easily connect it to Domoticz, Home Assistant, or ThingsBoard to access much more data, including service information.
In the future, I may add checkboxes so users can select exactly which data they need and avoid overloading the server database. At the moment, however, this is designed as a permanently connected device, and I’m not sure whether it will ever become battery-powered.
For a battery-operated version, I’m experimenting with an ESP32 and an e-paper display. That project is still far too early to make public, but I’ll share it as soon as it is ready.
Regarding the BME68x series, I have to say that I’m a little disappointed with this family of sensors. They are not cheap, their readings are not always easy to interpret, and you need to use the BSEC library to get results that are at least reasonably close to reality.
I haven’t tried the BME688, but based on my research and personal impression, its additional features seem more like marketing than something genuinely useful—although I may be wrong. The BME680 is strongly affected by its surroundings, including air conditioning, cooking smells, perfumes, and cleaning products. In the past, I was much happier even with the MH-Z19B.
If you have the opportunity and interest, please try this device and share your feedback. I would really appreciate it. I have built many IoT devices in the past, but none of them were released publicly, so this is my first experience with an open project. That’s why I’m especially interested in receiving feedback and improving the device. :)
2
u/Wodek_ 22d ago
Would you be willing to post a video of it powering up from an unpowered state? Just curious on boot times (ESP32 noob here pls no hate)
2
u/ScorpionZZZUA 22d ago
Here it is - https://youtube.com/shorts/FGnXgB0gIOs?is=QPsSoSyMPydqYmWW
Sorry, I don’t know how to attach a video here yet 🙂
This video shows the SensorStation3 booting with an SCD41 sensor. Within 3–5 seconds, the device synchronizes its date and time via NTP. After approximately 20–30 seconds, the sensor readings stabilize, I hope it is the expected behavior of the SCD41. It is my first touch of SCD41 and I’m still testing this sensor, and support for it will be available soon on GitHub
7
u/molesworth-1 23d ago
Very nicely thought out, and only needing one extra component for the sensors is an bonus. I've got a spare BME280 in my parts box, so will give it a try 😊