How edwardtfn/nspanel-easy works
NSPanel Easy is ESPHome firmware for a Sonoff NSPanel, configured through a Home Assistant Blueprint and presenting controls on a Nextion TFT. The principal workflow is Blueprint-provided entity/settings data reaching the panel, which renders interactive pages and hardware feedback; users interact with those pages to control Home Assistant entities. The repository also includes climate relay control, weather, display management, and hardware support. The README describes the Blueprint/TFT integration, while sampled sources show subscription dispatch and page/display implementation; links between unsampled subsystems are omitted where their wiring is not evidenced.
Main entry points: api_subscriptions.cpp Entity Subscriptions · page_home.cpp Home & Weather · page_buttons.cpp Button Pages · page_climate.cpp Climate Page
Components 24
Configuration & API
- HA Blueprint
- ESPHome Firmware
components/nspanel_easy/__init__.py - Entity Subscriptions
components/nspanel_easy/api_subscriptions.cpp - Entity Snapshots
components/nspanel_easy/entity_snapshot.cpp - Runtime State
components/nspanel_easy/base.h
Display & Pages
- Page Navigation
components/nspanel_easy/pages.h - Nextion Components
components/nspanel_easy/nextion_components.h - Icon Rules
components/nspanel_easy/icon_rules.h - Text Formatting
components/nspanel_easy/text.cpp
Entity Experiences
- Home & Weather
components/nspanel_easy/page_home.cpp - Button Pages
components/nspanel_easy/page_buttons.cpp - Entity Pages
components/nspanel_easy/page_entities.h - Climate Page
components/nspanel_easy/page_climate.cpp - Cover Controls
components/nspanel_easy/page_cover.h - Light Controls
components/nspanel_easy/page_light.cpp - Media Controls
components/nspanel_easy/page_media_player.h - Alarm Controls
components/nspanel_easy/page_alarm.h - Utilities Dashboard
components/nspanel_easy/page_utilities.h - Forecast Data
components/nspanel_easy/weather.h
Panel Hardware
- Display Control
components/nspanel_easy/hw_display.cpp - Climate Relay
components/nspanel_easy/addon_climate.cpp - Temperature Sensor
components/nspanel_easy/hw_temperature.cpp - TFT Upload
components/nspanel_easy/addon_upload_tft.cpp
Other components
- Home Assistant
Connections 16
- Home Assistant → HA Blueprint: provides configuration
README.md - HA Blueprint → ESPHome Firmware: configures
README.md - Home Assistant → Entity Subscriptions: sends entity updates
- Entity Subscriptions → Home & Weather: dispatches renders
components/nspanel_easy/api_subscriptions.cpp - Entity Subscriptions → Button Pages: dispatches renders
components/nspanel_easy/api_subscriptions.cpp - Entity Subscriptions → Climate Page: dispatches renders
components/nspanel_easy/api_subscriptions.cpp - Entity Snapshots → Entity Subscriptions: reads entity state
components/nspanel_easy/entity_snapshot.cpp - Home & Weather → Forecast Data: uses forecast
- Home & Weather → Nextion Components: renders on
components/nspanel_easy/page_home.cpp - Button Pages → Nextion Components: updates components
components/nspanel_easy/page_buttons.cpp - Climate Page → Page Navigation: uses navigation
components/nspanel_easy/page_climate.cpp - Climate Relay → Climate Page: supports thermostat
- Display Control → Page Navigation: manages display pages
- Temperature Sensor → Runtime State: uses runtime state
components/nspanel_easy/hw_temperature.cpp - Icon Rules → Entity Subscriptions: resolves icons
components/nspanel_easy/api_subscriptions.cpp - Button Pages → Text Formatting: wraps labels
components/nspanel_easy/page_buttons.cpp