Sonoff NSPanel by ITead - Smart Scene Wall Switch based on ESP32 and custom Nextion Touch Screen Panel Display (non-Pro variant)

Hi @Shejken,

Great, thanks. I’ve just copied all the latest code over to the EU version and have tested that it works on my US NSPanel (in landscape) - so this should just be testing that I’ve dealt with the specific quirks of the EU version properly (the cropped display and the touch offset), which I can’t test on the US model.

This also has a much improved gesture system for interacting with the Widget cards, which displays a dynamically updated gesture indicator in the top left hand corner to let you know what gesture is currently being detected and the action that will be triggered for that Widget if you lift your finger at that moment. Check out the Widget UI documentation on my Github page (I’ve started updating it with the new gesture information, and that will be included as part of the next version).

I’ll PM you the link to the beta files when I’ve uploaded them. Follow the installation instructions on the Github page as normal except replacing the standard files with the new beta versions. If you already have ESPHome flashed to your NSPanel, then it shouldn’t take much effort to get the Widget UI installed and configured. PM me if you have any issues setting up.

Hi Kriz,

Can you upload the beta files also to me ?

Sure, PM sent with link and details.
Let me know how it goes - once I know it is working properly I will upload it to the main Widget UI folder on Github with the next version (once I’ve finished tweaking the new gestures and new Widget features).

1 Like

For everyone who has the “System Data Error” after an upload of a tft file, I was only able to fix it by uploading directly from within the Nextion Editor.
Neither Esphome nor Tasmota could successfully upload a tft file.

You’ll have to use a USB-To-Serial Adapter and solder 4 Wires directly to the NSPanel Board:

Make sure the display is properly connected!

Power it through the USB-To-Serial Adapter and hit the “Upload” Button in Nextion Editor:


Hope this helps anyone with a stuck screen!

6 Likes

Thanks @hiscorebob,

When I have a day where I get the itch to play with hardware and do some soldering I’ll give this a go.
I doubt it will make it to the top of my list any time soon, but good to know where the contact points are for doing a direct flash.

hey,
Saw your running the nspanel in docker container/
do you mind help me configure it ?

Hey’
Trying to setup the nspannel on homeassistant Docker.
got this error on log
AppdaemonLog

apps.yaml:

nspanel-1:

module: nspanel-lovelace-ui

class: NsPanelLovelaceUIManager

config:

panelRecvTopic: "tele/nspannel/RESULT"

panelSendTopic: "cmnd/nspannel/CustomSend"

updateMode: "auto-notify"

sleepTimeout: 20

#sleepBrightness: 10

sleepBrightness:

  - time: "7:00:00"

    value: 10

  - time: "23:00:00"

    value: 0

appdaemon.yaml:
appdaemon:

latitude: 52.0

longitude: 4.0

elevation: 2

time_zone: Europe/Berlin

plugins:

HASS:

  type: hass

MQTT:

  type: mqtt

  namespace: mqtt

  client_id: "appdaemon"

  client_host: 192.168.XX.XXX

  client_port: 1883

client_user: “mqttuser”

client_password: “mqttpassword”

  client_topics: NONE

http:

url: http://192.168.XX.XXX:5050

admin:

api:

hadashboard:

CAN SOMEONE HELP ME?

Just Flashed this, can see it in MQTT, but just get a Homeassistant Logo on the screen. Tried adding the demo screens, but nothing changes
app daemon log:

2022-06-24 15:11:25.696987 INFO nspanel-1: Input config: {'panelRecvTopic': 'tele/nspanel_C72424/RESULT', 'panelSendTopic': 'cmnd/nspanel_C72424/CustomSend', 'sleepTimeout': 20, 'sleepBrightness': [{'time': '7:00:00', 'value': 10}, {'time': '23:00:00', 'value': 0}], 'locale': 'en_GB', 'screensaver': {'entity': 'weather.k3ll3r'}, 'cards': [{'type': 'cardEntities', 'entities': [{'entity': 'switch.roof_nightlight'}, {'entity': 'light.roof'}], 'title': 'Example 1'}]}
2022-06-24 15:11:25.699413 INFO nspanel-1: Loaded config: {'panelRecvTopic': 'tele/nspanel_C72424/RESULT', 'panelSendTopic': 'cmnd/nspanel_C72424/CustomSend', 'updateMode': 'auto-notify', 'model': 'eu', 'sleepTimeout': 20, 'sleepBrightness': [{'time': '7:00:00', 'value': 10}, {'time': '23:00:00', 'value': 0}], 'screenBrightness': 100, 'sleepTracking': None, 'sleepOverride': None, 'locale': 'en_GB', 'timeFormat': '%H:%M', 'dateFormatBabel': 'full', 'dateAdditionalTemplate': '', 'timeAdditionalTemplate': '', 'dateFormat': '%A, %d. %B %Y', 'cards': [{'type': 'cardEntities', 'entities': [{'entity': 'switch.roof_nightlight'}, {'entity': 'light.roof'}], 'title': 'Example 1'}], 'screensaver': {'type': 'screensaver', 'entity': 'weather.k3ll3r', 'weatherUnit': 'celsius', 'forecastSkip': 0, 'weatherOverrideForecast1': None, 'weatherOverrideForecast2': None, 'weatherOverrideForecast3': None, 'weatherOverrideForecast4': None, 'doubleTapToUnlock': False, 'alternativeLayout': False, 'defaultCard': None, 'key': 'screensaver'}, 'hiddenCards': []}
2022-06-24 15:11:25.704222 INFO nspanel-1: Sending MQTT Message: pageType~pageStartup
2022-06-24 15:11:25.714551 INFO nspanel-1: Registering callbacks for the following items: ['switch.roof_nightlight', 'light.roof', 'weather.k3ll3r']
2022-06-24 15:11:25.727352 INFO nspanel-1: Current time 15:11:25.724443
2022-06-24 15:11:25.733187 INFO nspanel-1: Current time 15:11:25.730152
2022-06-24 15:11:25.738734 INFO nspanel-1: Setting dim value to {'time': '7:00:00', 'value': 10}
2022-06-24 15:11:25.747147 INFO MQTT: Topic tele/nspanel_C72424/RESULT already subscribed to
2022-06-24 15:11:25.751114 INFO nspanel-1: Started
2022-06-24 15:11:25.950350 INFO nspanel-1: MQTT callback for: {'topic': 'tele/nspanel_C72424/RESULT', 'wildcard': '#', 'payload': '{"nlui_driver_version":"4"}'}
2022-06-24 15:11:25.952153 INFO nspanel-1: Update Pre-Check failed Tasmota Driver Version: 4 Panel Version: None

EDIT - Fixed, Flash had not completed successfully the firstime around as the template had not applied correctly. All working now and looking very nice :slight_smile:

Take a look at the appdaemon documentation, if you are using a standalone docker container for appdaemon, you have to configure the authentication to HA.

https://appdaemon.readthedocs.io/en/latest/CONFIGURE.html#hass-authentication

Done it
token

For @ChenH The trick is to share de appdeamon directory from home assistant.

Here is my Docker HA & Appdeamon setup
Appdeamon

docker stop appdaemon
docker rm appdaemon
docker run --name=appdaemon -d -p 5050:5050 \
  --restart=always \
  -e HA_URL='http://<yourserver>:8123' \
  -e TOKEN=secret \
  -e DASH_URL='http://<yourserver>.local:5050' \
  -v /share/Docker/data/homeA/appdaemon:/conf \
  -v /etc/localtime:/etc/localtime:ro\
  acockburn/appdaemon:latest

Home assistant

docker stop home-assistant
   docker rm home-assistant
   docker run -d --name="home-assistant" \
           --restart always \
           -v /share/Docker/data/homeA:/config\
           -v /etc/localtime:/etc/localtime:ro\
           --net=host homeassistant/home-assistant:latest

Great!
THANKS A LOT

Hi, I watched your YT video and noticed in the comments that the NSPanel is not physically connected to the dimmer, rather the panel controls HA that in turn controls the dimmer. Is it possible to change the switches via Esphome to momentary switches and phisically connect the panel and the dimmer?

I very much would like to only have nspanel and no ”normal” wall switches but still want dimming and also want it to be ”tethered” to be wifi redundant.

What I’m thinking is something like this:

Thanks for any clarifications

Hi, any news on the EU version?

Hi @Botap. Some people are beta testing the next version at the moment with some nice new features (such as a much improved gesture system, a media player popup control etc.) and this includes an EU version. I’ll pm you details if you want to try it out. The beta works well, its just that the features keep getting tweaked as I get user feedback and suggestions.

Yes, you link the relay to the push button as a GPIO switch and configure the relay to automatically switch off, after a short delay, whenever it switches on.

This is covered in the ESPHome docs here:

BUT the NSPanel relays are hardwired to the mains voltage that powers them!
So you would have to rewire the relays, which isn’t something I’d recommend (unless maybe you power the NSPanel from a separate 5V power supply instead).

Thanks for your reply. In the shelly docs there is an option regarding switch:

Button Type
• One Button mode: the device is controlled with a single switch.
• Dual button mode: the device is controlled dual switch.
• Toggle switch one button: the device is controlled by a single toggle switch.
• Edge switch: the device is controlled with an edge on/off.

If not changeing anything on NSPanel is it possible to use the proposed wiring and set the button option to toggle or edge switch? Then actual dimming could be done by a slider on the screen.

Hi, I would love to test the beta and provide feedback. Please PM me the details. Thanks

Would love to participate in this beta as well. Have 10 nspanels in the house currently to play around with and provide feedback

@Botap, I PMed you the details a few days ago - check your mailbox (or let me know if it didn’t get through).

@snoekieboe I just PMed you details too.

I just uploaded the next version (2022-06-29) with quite a few improvements.