NxPanel - Replacement Firmware for Sonoff NSPanel

I have a similar need for setting a delay value between 1-4 and was thinking about using the dimmer button-type for this with custom start (1) and end (4) states. In your case, the dimmer slider would have three states, one for each of your scenes. Havent implemented this yet, so cannot share an example yet.

But actually think the approach suggested by @Mathew_Fisher would be more intuitive and graphically appealing :slight_smile:

1 Like

Thanks guys. I basically went with a version of Matthew’s solution.

I was having a little difficulty with the “Off” button (probably due to some rules and the difference between “changed”, “updated”, “commanded”). So I decided to eliminate the “Off” button and just have buttons for “Entertain” and “Romantic”.

The initial screen has both buttons in the OFF state. If you tap one of the buttons it turns on that scene. If you then tap the other scene, it switches to that scene (obviously). Finally, if you tap a scene button that is currently ON, it turns that scene OFF (and thus all scene items get turned off).

I think it should be easy to scale this technique out to more scene buttons in the future.

2 Likes

Did you ever find a solution to this? I believe I’m having the same issue.

Is this truly a bug? Or am I just not understanding the functionality?

I ended up changing firmware to the NSPanel Lovelace UI. I really appreciate the work done here, but since the development has slowed down and I had a ratter complex node-red flow to make this work, I ended up switching.

Hi, looks very interesting. Do you have a good starting point on how to integrate it with openhab?

Guys how do you control dimming mode with mmike firmware? I do have motion sensor that could be used to turn display on and off but not sure where to start.

Not really. Even this project, I ended up running entirely on Node-Red and Home Assistant…

Hi, check examples in page 40 in the latest documentation (2.9).
Example for a rule:

// Adopt NSPanel Dimning level to night time
val mqttActions = getActions(“mqtt”, “mqtt:broker:mosquitto-xxxxxxx”)
mqttActions.publishMQTT(“cmnd/nspanel_7DD7FC/nxpanel”, “{"dim": {"low":20,"normal":60}}”)
logInfo(“myLog”, “NXPanel Dimlevel - “+timeRightNow+” Sunset, setting low=20”)

1 Like

Been away from this project for a while because had so many thing going on. Going to try and put a bit of time into this again to move it along again.

For those that have been using it over the last 6 months or so, how has it been doing? Any big bugs holding people back, or any features that would be really useful for people?

4 Likes

I’ve been using it a fair amount. Firstly, thank you!
I’d quite like to be able to change the background colour. I find in certain lighting conditions its a bit light.
Is this something that can be configured with messages, or does it need to be pre-compiled?

Although sounding simple, this is not. The nextion does not support transparancy or any alpha color channel, so all the icons are make on the background color and then cut to shape. To chance the background color would mean replacing all the icons and starting over. and the icons are compile in at resource level. I agree it would be nice, as I know what you mean.

I could change all the icons to be standalone square with straight edges. This would make changing the background easier. But I think the overall look on the device would then look much crappier.

I could also make a variant theme, where I did make new version B with all the same code and indeed cut all the icons out on a different background. Maybe at some point I will, but work to reward on this doesn’t feel right just now

Hope that explains.

Yeah I understand. I half thought that would be the case.

Another idea is, on the main page its broken up into different sections for like time, weather, temperature etc. If you press on them could it be configured to open a certain status page for example?

yes, that would be possible. what exact areas?

The main one for me is the one bottom right.
Maybe some sort of configuration setting that links which page it would open.

An example would be on the first post in this thread. Pressing on the 17C could be configured to open the Cabin page.

Hi, I’ve ”solved” this by adopting the dimming level based on sun-set, sun-rise, etc, basically just have a rule that triggers and updates dimming levels, see example below.

// Adopt NSPanel dimming level to daylight
val mqttActions = getActions(“mqtt”, “mqtt:broker:mosquitto-xxxx”)
mqttActions.publishMQTT(“cmnd/nspanel_7DD7FC/nxpanel”, “{"dim": {"low":40,"normal":60}}”)
logInfo(“myLog”, “NXPanel Dimlevel - Sunrise, setting low=40”)

Hi @m-home, great to have you back!

I’ve implemented two of these in different buildings which have now been running and (very) stable for a couple of months (and also more and more used and appreciated by the rest of the family).

Key feature missing is some kind of ”auto return” to the main page. Seems as you started on this (Return home?) on the settings page. And if this is tricky to implement, a MQTT message that moves NXPanel back to the main page would be an alternative.

I’m also interested in experimenting with the alarm panels but have no clue on how messages should look like, so any examples on this would be appreciated.

Hi @m-home,

Thanks for all the great work. I’ve got most of my setup working, with one exception, the color page.

I’m not sure if it’s a bug, or I’m not doing something correctly, but when I long press on a color button to render the color page, a “dimmer” event gets sent FROM the NxPanel:

{"dimmer":{"pid":13,"power":0,"hsbcolor":"180,100,50"}}

This sends things into a loop with lots of these:

{"nextion":"bytes('1CFFFFFF7B2264696D6D6572223A7B22706964223A31332C22706F776572223A...')"}

I think this same situation was highlighted a few months ago by another user. Any thoughts?

Thanks for all of your efforts.
I already ordered a NSPanel and like to try some things.
My main goal would be to use mainly the physical switches.
They should control lights, shutters/blinds, heating, etc… depending on what page is selected.
Is this possible? Thank you. BR

I would say its possible, but not really intended to work that way.
The physical switches are driven/reported with the Tasmota software, they are also linked to the relays on the unit (I think Tasmota can remove this link, but I’m not 100% sure)
To find out which page is being displayed you could maybe use the Refresh and Sync messages.
Then have some kind of complicated rule set that works out which page you are on and links the physical button messages to the different items.
This wouldn’t be easy and probably prone to errors.

Using the touchscreen buttons and switches is more how its intended for controlling external items.

It can be done! You can upload your tft file directly from nextion editor just like you are flashing your ESPs. Karibu! (Welcome)