Start a new topic

Get list of objects from Flash

Hi,

Is is possible toe interface to the Nextion screen and get a list of all objects back fromit. The flash must have this data, otherwisie one cannot define them in our own program.


I am now reviewing all of the Feature Requests, this will take some time, patience please.

This has not yet been implemented, but will be represented


How so Nico? 

Are you looking for the object names within your HMI design, or for more information than that?



There currently isn't an ability to pull from Nextion over serial, the objects it contains.


Quite frankly, I wouldn't want such a capability, as it would pose a security risk to know what internal variables my design is using to be made available over serial in runtime.  This type capability would be a deal breaker if anyone with a 9600 baud modem and a pair of alligator clips could steal a design from a running Nextion.


However, know that it is possible in your design phase to get a list of your objects from your HMI file to help assist you while in the design phase  and writing your host mcu code.  But in this scenario, it is your design that you are in possession of that you are using as your source.


Please clarify


This does need some explanation :)

I am trying to build a generic interface to the nextion screens. If I know the type of component, ID, name and page, I can generate all the data I need in my MCU. At the same time I am working with a software package that supports UML. From there I can (re)generate the contents of each class including the actual functionality. For the Nextion screens I am (trying) to do something similar. So I wouldn't mind if I can generate (XML?) code of the screen through the IDE with all the components with their attributes. That would be fine. It is still in a bit of a brainstorming phase though.

Never thought about it from your perspective but that is a fair one as well. But if it is in the IDE it would be fine as well.

How can I get a list of my objects btw?

I have made a personal console utility that will pull out basic component info (component order, name, and type) though I haven't yet succeeded in obtaining all the attributes.  Knowing by way of using the Nextion Editor that a hotspot has attributes .objname, .vscope, .x, .y, .w, .h - You can begin coding your classes.  It is possible for you to query the Nextion for most attribute values at runtime, only those attributes listed in green can be set at runtime, and only BOLD Green will auto-refresh your component.  Your process would be to setup your classes per component you are implementing in your HMI design - there wouldn't be a whole lot currently gained programmatically from the HMI file except to get you started with the list of order, name and type.


This approach to me, doesn't have that same security risk.  You are the HMI designer, and the inside knowledge to creating your personal tools is a result of your programming your design and use of the Nextion Editor - starts with your thoughts and what you are putting into your HMI and MCU.  And a far cry from an "reassembly via external debug without source knowledge".


So I will blackmail you at this point, sign up for my ZI Font Editor by sending an email to zieditor@homehub.info and in doing so, I have your contact info to send you the details you need for the components - and you will get a good font editor for the Nextion w/Manual as well.



Login or Signup to post a comment