ESP32-based display monitor for TheKilnGod kiln controller. Displays real-time temperature, status, and a temperature graph on a 3.2" ST7789P3 TFT display.
- LCDWIKI E32R32P/E32N32P ESP32-32E Integrated Display Board (3.2" 240x320 ST7789P3 display)
- Or compatible ESP32 development board with ST7789P3 display
- Wiring connections (see pin configuration below)
Note: This project is configured for the LCDWIKI E32R32P/E32N32P board. For other boards, adjust pin configuration in config.h.
For LCDWIKI E32R32P/E32N32P ESP32-32E Integrated Display Board:
The display is already wired internally. The pin configuration is set according to the official specification:
| Function | ESP32 Pin | Description |
|---|---|---|
| CS | GPIO 15 (IO15) | LCD screen selection control signal, low level effective |
| DC | GPIO 2 (IO2) | LCD command/data selection control signal (High: data, Low: command) |
| SCLK | GPIO 14 (IO14) | SPI bus clock signal (shared by LCD and touch screen) |
| MOSI | GPIO 13 (IO13) | SPI bus write data signal (shared by LCD and touch screen) |
| RST | GPIO 4 | LCD reset control signal (EN pin is shared with ESP32-32E master) |
| BL | GPIO 27 (IO27) | LCD backlight control signal (HIGH = backlight on, LOW = backlight off) |
Note: The backlight pin is GPIO 27, not GPIO 21 or 15 as some other boards use. Make sure TFT_BL is set to 27 in config.h.
For Other Integrated ESP32 Display Boards:
If you have a different integrated board, you may need to adjust the pins in config.h. Common alternatives:
- CS: GPIO 5 or GPIO 21
- SCLK: GPIO 18
- MOSI: GPIO 23
- BL: GPIO 15 or GPIO 21
For External Displays:
| Display Pin | ESP32 Pin | Function |
|---|---|---|
| VCC | 3.3V | Power |
| GND | GND | Ground |
| SCL/SCK | GPIO 14 or 18 | SPI Clock |
| SDA/MOSI | GPIO 13 or 23 | SPI Data |
| DC | GPIO 2 | Data/Command |
| CS | GPIO 15 or 5 | Chip Select |
| RST | GPIO 4 | Reset |
| BL | GPIO 27, 21, or 15 | Backlight |
Edit include/config.h to modify:
- WiFi credentials (already configured)
- Kiln API URL and port (default: 10.0.0.252:8081)
- Display pins (if different from defaults)
- Update intervals
- Install PlatformIO (VS Code extension recommended)
- Connect ESP32 via USB
- Build and upload:
pio run -t upload
- Monitor serial output:
pio device monitor
The code tries multiple API endpoints to find the correct one:
/api/status/api/state/status.json/api/temperature
The API should return JSON with the following fields (flexible naming):
temperatureortemp- Current temperaturetarget_temperatureortarget_temportarget- Target temperaturestatusorstate- Kiln status (RUNNING, PAUSED, IDLE)profile_nameorprofile- Current profile nametime_remainingortime_remaining_seconds- Time remaining in secondsruntimeorruntime_seconds- Total runtime in secondsheat_rateorheating_rate- Heating rate in degrees/hour
- Status Bar (Top): Shows "KILN MONITOR" and WiFi connection status
- Temperature Display: Large current temperature and target temperature
- Graph Area: Real-time temperature graph showing last 3 minutes of data
- Status Line (Bottom): Kiln status, profile name, and time remaining
-
Display not showing:
- For LCDWIKI E32R32P/E32N32P boards: Verify pins in
config.hmatch the specification:- CS = 15, DC = 2, SCLK = 14, MOSI = 13, RST = 4, BL = 27 (important!)
- Check that backlight pin is correct - for this board, BL is GPIO 27 (HIGH = on)
- Try different rotation values in
display.cpp(0-3) - Verify the display initializes by checking serial monitor for errors
- The serial monitor will show color tests (red, green, blue, white) - if you don't see these, the display isn't initializing
- Some boards may need
tft.init(240, 320, SPI_MODE3)- check Adafruit library docs
- For LCDWIKI E32R32P/E32N32P boards: Verify pins in
-
WiFi not connecting:
- Verify SSID and password in
config.h - Check serial monitor for connection errors
- Ensure ESP32 is within WiFi range
- Verify SSID and password in
-
API not responding:
- Verify kiln controller is running at the configured IP
- Check serial monitor for HTTP error codes
- Try accessing the API URL in a browser to verify it's working
- The code will try multiple endpoints automatically
-
Graph not updating:
- Wait for at least 2 data points (6 seconds)
- Check that temperature data is being received (see serial monitor)
The serial monitor (115200 baud) will show:
- WiFi connection status
- API request results
- Temperature updates
- Error messages
- Real-time temperature display
- Temperature graph (last 3 minutes)
- WiFi connection status indicator
- Automatic reconnection on WiFi loss
- Multiple API endpoint fallback
- Error handling and display
This project is provided as-is for use with TheKilnGod kiln controller.