This is a question that is asked daily in our household throughout December. Last year I realised I had all the pieces lying around to automate the response. I’m a big fan of quick-and-dirty projects that can be bashed out in a day just using bits I have lying around, and this is one of those.
The hardware list was quite simple:
- Wemos D1 mini (an ESP8266-based dev board)
- 16x2 LCD Display
- Resistor (current-limiting for the LCD backlight)
- Some jumper cables
I spliced the current-limiting resistor into a jumper cable and then assembly just involved connecting the jumper cables between the Wemos D1 and the LCD. I designed a simple 3D printed holder with the components held in place with hot glue:

Programming the project was simple. Using ESPHome meant I got it going really quickly with barely any code. The device gets the current time from my Home Assistant instance and displays the number of sleeps until the set date. The functional part to make this work is below:
# Configure time from Home Assistant
time:
- platform: homeassistant
id: homeassistant_time
# Configure LCD Display
display:
- platform: lcd_gpio
dimensions: 16x2
rs_pin: D0
rw_pin: D1
enable_pin: D2
data_pins:
- D3
- D4
- D5
- D6
lambda: |-
long daysleft = ((1735106400l - (id(homeassistant_time).now().timestamp))/60/60/24 + 1);
it.printf("%ld sleeps until Christmas!", daysleft);
# Configure output pin to control LCD contrast
output:
- platform: gpio
pin: D7
id: lcd_contrast
inverted: true
As I said before, this was one of those super-quick projects. That’s why the target date (1735106400 seconds since the Unix Epoch - a.k.a 6am on Christmas Day 2024) was hardcoded. When I dug this project out of the cupboard for 2025 I plugged it in and it read “-345 sleeps until Christmas!” Fixing was as simple as changing the timestamp and updating OTA with one simple command:
esphome run lcd_display.yaml
Maybe at some point I’ll add the target date as a proper entity that can be configured in Home Assistant, but that would start to feel like over-engineering of this quick-and-dirty project.