I would like to indicate a status (0/1, no progress bar) to indicate if an element in the on or of status with a picture (eg a light bulb in 2 different states)
Currently it is not possible with a picture (it has no value, so you cannot switch), and you cannot do this with a button (you can... but you cannot disable the butten)
I would be great to have
- a picture with different states
- or a butten that you can disable (but where you still can change the status by code)
ok, i found a solution.
you can make use from the tsw function (Enable/disable component touch function) to disable a button.
(add this command in the preinitialize event page for the page)
In this way you can disable the button, but still update the value (and switch the picture)
Thanks Gerry for the examples & the explaination !
I've now only one status (that from the bulb). and this status is updated externally via an MQTT message (feedback & real status of the bulb)
To switch the bulb on/off there is just a button that sends a command based on the status of the bulb (toggle)
My nextion is connected with an ESP8266 (Wemos module) that converts the serial message form the nextion to a mqtt message to activate a switch and visa versa (switch gives a message back to update the status)
(Raspberry Pi acting as an MQTT server and multiple ESP8266 modules sending & receiving mqtt messages)
I am now reviewing all of the Feature Requests, this will take some time, patience please.
Although this wasn't a real feature request, it is now marked as reviewed.
Future questions should be posted to the Free Chat Section