ESPHOME with 16x2 module does not display values anymore after reboot of ESP module

I programmed with ESPHome an ESP32 to display some Home Assistant sensor values on a 16x2 LCD module without using I2C adapter.
It works fine after ESPhome install and compile. But when I reboot the ESP32 module the display does not show values.
Although in the lESP32 log I see the the values are read and updated.
If I install the code again (wifi) it start displaying the values again.

esphome:
  name: esp32

esp32:
  board: esp32dev
  framework:
    type: arduino

# Enable logging
logger:

# Enable Home Assistant API
api:
  encryption:
    key: "******"

ota:
  password: "*****"

wifi:
  ssid: !secret wifi_ssid
  password: !secret wifi_password


  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: "Esp32 Fallback Hotspot"
    password: "********"



captive_portal:


sensor:
  - platform: dht
    pin: 33
    temperature:
      name: TemperatureESP32
      id: temp
    humidity:
      name: "HumidityESP32"
      id: humidity
    update_interval: 60s
  - platform: homeassistant
    id: elek_up
    entity_id: sensor.dsmr_reading_electricity_currently_returned
  - platform: homeassistant
    id: elek_down
    entity_id: sensor.dsmr_reading_electricity_currently_delivered


display:
  - platform: lcd_gpio
    dimensions: 16x2
    data_pins:
      - 18
      - 17
      - 16
      - 21
    enable_pin: 23
    rs_pin: 19
    lambda: |-
      it.printf("%.1fC %.1f%%", id(temp).state, id(humidity).state);
      it.printf(1 , 1, "%.3fkW %.3fkW", id(elek_up).state, id(elek_down).state);


Capture and post the startup logs for a reboot.