Export an EEZ Studio UI to Arduino Nano RP2040 | nerdhut.de
ฝัง
- เผยแพร่เมื่อ 10 ก.ย. 2024
- In the second part of this mini series, I demonstrate how to get the UI we created in EEZ Studio in part one uploaded to the Arduino. I also detail the steps you need to take to implement event handlers, actions, and variables. Finally, I also discuss how to update the EEZ Studio UI from the Arduino sketch code.
You can find the template project here: github.com/Whi...
------
I create videos about tech, gadgets, electronics, DIY, projects and builds, and other related stuff. Check back for new content every once in a while, or subscribe to the channel, so you don't miss any new videos!
------
Website: nerdhut.de/202...
------
Social Media & contact information: nerdhut.de/ner...
------
If using VS Code, you can go to "Replace in files" to quickly replace the lvgl.h lines in all the files in one go.
I also noticed in the Eez Studio the build process uses templates that specify a system variable to define the lvgl.h path. I haven't worked out how to set it yet :(
Saved my life ... without this video i wouldn't be able to get my cyd to work and change screens
Can you make a video for how to pass variables to the project
Like displaying counting number
Or printing slider values etc in a simple way for beginners 😅
I am trying to make an interface but i can't handle passing variables to the user interface
Hi, thanks for your comment! Unfortunately, there is no easier way than what is shown here. Building an (embedded) UI is no beginner topic. You need to have good understanding of the basics and how to work with external libraries and their functions.
But if your only goal is to pass variable values to labels, for instance, you can call LVGL's set_text function on the UI element (which is also shown in the video toward the end). You can find a more detailed description of the method in the LVGL docs: docs.lvgl.io/master/widgets/label.html#usage
Similarly, you can read the value of a UI element (e.g., a slider) using LVGL events, which I discuss in a different video: th-cam.com/video/PTKjjDPNIdM/w-d-xo.html (It's for SquareLine Studio but that also uses LVGL, just like EEZ Studio).
I hope this still helps! :)
Your video couldn't have arrived at a better time! I am struggling with EEZ Studio and have no intention to use Squareline. You managed to convince me not to use its LVGL 8.3 and to go for LVGL 9. EEZ Flow generates a really long-winded code that is hard to follow. Yes, coding in the Arduino seems like the proper way out.
I will confess. I found other videos about EEZ Studio, but they skip some crucial details, unlike yours. The accents are also not very easy to listen to, and the racism in me doesn't help matters.
Thank you for your input! I'm glad you liked the video and found it helpful -- I strive to make videos that focus only on the content without filler.
Can u make a video with EEZ flow because it seems more effective
I might one day but I currently don't have any concrete plans
Hi!
Thank you for this tutorial!
I am currently in the state of playing with eez lvgl with flow support. I like it so far but one thing bothers me and maybe you have an advice.
There is a not so little part of handcoding inside the generated files. If one hast to regenerate because of changing or adding Something - what ist the best way to Update the gui while keeping the implementation?
Merging? Or is there a way to only write a few includes to map the variables and functions to the user code so we can keep gui and user code mostly independent?
Yeah, like you mentioned, using a VCS (like GIT) can be a viable approach. Then you can create a commit before re-generating the code and revert the changes you don't want to keep in the generated code. Alternatively, I think placing all the custom code in separate C-files (with matching headers) can also be a good method. Then you only need to call your custom functions from within the generated code. That way, you only have to add back single method calls to the re-generated code, which can at least reduce the hassle.
I might look at flow in a future video, as I'm interested in it myself, and I may talk about some strategies there, too.
But yeah, essentially, you already mentioned the two things I'd try myself
@@nerdhut Thank you for your reply!
I haven't known Flow until I created different projects to play around. For me it is useful to have all the ui-handling in the eez project like animations (also for testing purposes).
That is why I am looking for an approach to just call my user methods or steh similar or better.
I am looking forward to your next videos - maybe you can talk about some strategies.