I’m trying to display my solar power essentials on a tiny 64x48 display and would like to use icons in stead of text to save space.
The OLED display: OLED 0.66 Shield — WEMOS documentation
The Icon I would like to use is this one: battery - Material Design Icons - Pictogrammers
Here’s my code:
substitutions:
name: "esphome-micro-display"
friendly_name: ESPHome Micro Display
esphome:
name: ${name}
friendly_name: ${friendly_name}
name_add_mac_suffix: false
project:
name: esphome.web
version: '1.0'
esp8266:
board: d1_mini
dashboard_import:
package_import_url: github://esphome/example-configs/esphome-web/esp8266.yaml@main
import_full_config: true
i2c:
scl: D1
sda: D2
font:
- file: "gfonts://B612 Mono"
id: font_small
size: 10
- file: "gfonts://Reddit Mono"
id: font_mono_medium
size: 14
sensor:
- platform: homeassistant
id: soc
entity_id: sensor.deye_sunsynk_sol_ark_battery_state_of_charge
internal: true
- platform: homeassistant
id: load
entity_id: sensor.deye_sunsynk_sol_ark_load_power
internal: true
time:
- platform: homeassistant
id: esptime
display:
- platform: ssd1306_i2c
model: "SSD1306 64x48"
reset_pin: 0
address: 0x3C
lambda: |-
it.printf(0, 0, id(font_small), "BATT:%.0f%%", id(soc).state);
it.printf(0, 15, id(font_small), "LOAD:%.1f%KW", id(load).state/1000.0);