Time & Room Temperature Display for mounting on Center Microphone Stand, Temperature and CO2 levels are derived from either the Room Controller or remote ENS160+AHT21 Devices

Benjamin Harris 35da5fdb6b Add Image 2 ماه پیش
documents 35da5fdb6b Add Image 2 ماه پیش
README.md 35da5fdb6b Add Image 2 ماه پیش

README.md

ESP32-S3 RLCD 4.2 Indoor / Outdoor Temperature Display

A simple, clean desktop temperature and clock display built around the WaveShare ESP32-S3-RLCD-4.2.

The display is designed to make the information readable from a distance, with the current time occupying the upper half of the screen and indoor/outdoor temperatures displayed prominently across the lower half.

Display Layout

Display Sample

The display uses the full 300 × 400 pixel resolution of the 4.2-inch reflective LCD.

Display Sections

Top 50%

  • Large digital time
  • Current date underneath
  • Time displayed in a very large, bold font
  • 24-hour format
  • Date displayed as:

    • Day of week
    • Day
    • Month

Bottom 50%

  • Two equal-width temperature sections
  • Indoor temperature on the left
  • Outdoor temperature on the right
  • Large, bold temperature values
  • Temperature displayed in °C
  • Optional small labels above each temperature

Hardware

Main Controller / Display

WaveShare ESP32-S3-RLCD-4.2

The board provides:

  • ESP32-S3 dual-core LX7 processor
  • Up to 240 MHz
  • 16 MB Flash
  • 8 MB PSRAM
  • 2.4 GHz Wi-Fi
  • Bluetooth 5 LE
  • 4.2-inch reflective LCD
  • 300 × 400 pixel resolution
  • PCF85063 real-time clock
  • SHTC3 temperature/humidity sensor
  • TF card interface
  • USB Type-C
  • 18650 battery holder
  • RTC backup battery support

The onboard SHTC3 provides the indoor temperature measurement. The PCF85063 provides hardware real-time clock functionality.

See the official hardware documentation:

WaveShare ESP32-S3-RLCD-4.2 Documentation

Outdoor Temperature

The outdoor temperature will be supplied separately from the display.

The preferred architecture is:

Outdoor Sensor
      │
      │ Wi-Fi
      ▼
ESP32-S3-RLCD-4.2
      │
      ├── Indoor Temperature
      ├── Outdoor Temperature
      ├── Date
      └── Time

The outdoor sensor can be another ESP32-based device, a network temperature sensor, MQTT source, HTTP API, or another compatible data source.

The display should continue showing the last known outdoor temperature if the outdoor sensor temporarily becomes unavailable.

Software

The project is intended to run on the ESP32-S3 using the Arduino framework.

Development Environment

Recommended:

  • Visual Studio Code
  • PlatformIO
  • Arduino framework
  • ESP32-S3 board support

WaveShare officially supports both Arduino IDE and ESP-IDF for this board.

Proposed Software Architecture

                    ┌─────────────────────┐
                    │      ESP32-S3       │
                    │                     │
                    │   Main Application  │
                    └──────────┬──────────┘
                               │
              ┌────────────────┼────────────────┐
              │                │                │
              ▼                ▼                ▼
        ┌───────────┐    ┌───────────┐    ┌───────────┐
        │    RTC    │    │   SHTC3   │    │   Wi-Fi   │
        │ PCF85063  │    │  Indoor   │    │           │
        └─────┬─────┘    └─────┬─────┘    └─────┬─────┘
              │                │                │
              │                │                │
              │                │         Outdoor Temp
              │                │                │
              └────────────────┼────────────────┘
                               │
                               ▼
                     ┌──────────────────┐
                     │  Display Engine  │
                     └────────┬─────────┘
                              │
                              ▼
                     ┌──────────────────┐
                     │  300 × 400 RLCD  │
                     └──────────────────┘

Display Design

The UI should remain intentionally simple.

There should be no unnecessary menus, icons, animations, or small text.

The primary purpose of the display is to provide information that can be read quickly from across a room.

Time

The time should be the largest element on the display.

Example:

        11:08

The seconds should not normally be displayed.

The display should update once per minute.

Date

The date is positioned directly underneath the time.

Example:

     MONDAY 24 AUGUST

Indoor Temperature

The indoor temperature comes from the onboard SHTC3 sensor.

Example:

       INDOOR

       21.5°C

Outdoor Temperature

The outdoor temperature is received over the network.

Example:

       OUTDOOR

       14.8°C

Data Update Rates

Data Source Update Rate
Time PCF85063 RTC 1 minute
Date PCF85063 RTC 1 day
Indoor temperature SHTC3 30–60 seconds
Outdoor temperature Network 30–60 seconds
Display RLCD As required

The display should avoid unnecessary full-screen refreshes.

Network Behaviour

On startup:

  1. Initialise the display.
  2. Initialise the RTC.
  3. Read the onboard SHTC3 sensor.
  4. Connect to Wi-Fi.
  5. Obtain the current time.
  6. Obtain the outdoor temperature.
  7. Draw the complete display.

During normal operation:

  1. Update the RTC time.
  2. Read the indoor temperature.
  3. Check for a new outdoor temperature.
  4. Update the display when required.

If Wi-Fi is unavailable:

  • Continue displaying the time.
  • Continue displaying the indoor temperature.
  • Display the last known outdoor temperature.
  • Indicate that the outdoor reading is stale if required.

Time Synchronisation

The ESP32-S3 should synchronise the RTC from an NTP server when network connectivity is available.

Recommended configuration:

NTP Server:
pool.ntp.org

Time Zone:
Australia/Hobart

Format:
24 hour

The RTC then maintains the time locally when Wi-Fi is unavailable.

Temperature Display

Temperatures should be displayed with one decimal place.

Examples:

21.5°C
19.0°C
7.8°C
-2.3°C

The degree symbol should be displayed as:

°C

Error Handling

No Wi-Fi

The display continues operating from the local RTC.

OUTDOOR

--.-°C

or, if a previous value is available:

OUTDOOR

14.8°C

The previous value should preferably remain visible rather than replacing it immediately with an error value.

Sensor Error

If the SHTC3 cannot provide a valid indoor temperature:

INDOOR

--.-°C

RTC Error

If the RTC has lost its valid time:

--:--

The system should attempt to correct the time as soon as network connectivity becomes available.

Project Structure

A suggested project structure:

/
├── README.md
├── platformio.ini
│
├── src/
│   ├── main.cpp
│   ├── display.cpp
│   ├── display.h
│   ├── rtc.cpp
│   ├── rtc.h
│   ├── temperature.cpp
│   ├── temperature.h
│   ├── network.cpp
│   ├── network.h
│   ├── outdoor.cpp
│   └── outdoor.h
│
├── include/
│   ├── config.h
│   └── secrets.h
│
├── lib/
│
└── data/
    └── fonts/

Configuration

User-specific settings should be kept separate from the main application code.

Example:

#define WIFI_SSID       "YOUR_WIFI"
#define WIFI_PASSWORD   "YOUR_PASSWORD"

#define NTP_SERVER      "pool.ntp.org"
#define TIMEZONE        "Australia/Hobart"

#define TEMP_UPDATE_MS  60000
#define DISPLAY_UPDATE_MS 60000

Credentials should not be committed to the repository.

A local configuration file should be added to .gitignore.

Future Features

Potential future additions:

  • MQTT outdoor temperature
  • Multiple outdoor sensors
  • Humidity display
  • Weather forecast
  • Weather icons
  • Indoor/outdoor humidity
  • Wi-Fi signal indicator
  • Battery percentage
  • Automatic screen brightness control
  • Configuration through a web interface
  • OTA firmware updates
  • Custom temperature units
  • Minimum/maximum temperature
  • Historical temperature logging
  • TF card data logging
  • Automatic night mode
  • Multiple display layouts

Design Goals

The project should follow these principles:

  1. Large, readable information
  2. Minimal UI
  3. Low power consumption
  4. Reliable local timekeeping
  5. Continued operation without Wi-Fi
  6. Clear indoor/outdoor temperature separation
  7. Fast display updates
  8. Simple configuration

The WaveShare board is particularly suited to this application because the RLCD provides a reflective display without a conventional backlight, while the board already includes the RTC and indoor temperature/humidity sensor required by the application.

Hardware Documentation

Official documentation:

WaveShare ESP32-S3-RLCD-4.2

Licence

This project is released under the terms specified by the repository owner.