e35058f53d
Backfills the working firmware that had stayed uncommitted across the build sessions, so the branch is self-contained. - audio: audio_player, radio_pipeline, sd_player, calm_tone, aac_player - net: podcast (RSS), udp_log - modes: balloons, plus calm/games/radio tweaks - ui: fonts header, icons; build files (CMakeLists, idf_component.yml, sdkconfig.defaults) - docs/superpowers: Histoires design + plan Note: sdkconfig stays gitignored (Wi-Fi creds + tuned LFN/FS/mbedtls settings); a fresh checkout must reconfigure those.
26 lines
1.2 KiB
C
26 lines
1.2 KiB
C
// Icon helpers for the Lisael Box UI.
|
|
//
|
|
// The home tiles and weather use real colour icons (Twemoji PNGs converted to
|
|
// LVGL RGB565A8 image descriptors, in ui/assets/). This file maps open-meteo
|
|
// WMO weather codes to the matching icon.
|
|
|
|
#include "ui/icons.h"
|
|
#include "ui/assets/lisael_icons.h"
|
|
|
|
const lv_image_dsc_t *lisael_weather_code_icon(int code)
|
|
{
|
|
switch (code) {
|
|
case 0: return &lisael_ic_wsun; // clear
|
|
case 1: case 2: case 3: return &lisael_ic_wpartly; // partly cloudy
|
|
case 45: case 48: return &lisael_ic_wfog; // fog
|
|
case 51: case 53: case 55: return &lisael_ic_wdrizzle; // drizzle
|
|
case 61: case 63: case 65: return &lisael_ic_wrain; // rain
|
|
case 66: case 67: return &lisael_ic_wsleet; // freezing rain
|
|
case 71: case 73: case 75:
|
|
case 77: case 85: case 86: return &lisael_ic_wsnow; // snow
|
|
case 80: case 81: case 82: return &lisael_ic_wrain; // showers
|
|
case 95: case 96: case 99: return &lisael_ic_wthunder; // thunderstorm
|
|
default: return &lisael_ic_wunknown;
|
|
}
|
|
}
|