-
-
Notifications
You must be signed in to change notification settings - Fork 19.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[WIP] Refactoring LVGL integration #20853
base: bugfix-2.1.x
Are you sure you want to change the base?
Conversation
Do you know about the MKS's UI ? It's already using LVGL internally and it's quite complete already. I agree that developing on Linux is easier than on the printer itself, but in the end, you'll have to simulate so many stuff (touch position, printer's interaction, G-Code, etc...) that I doubt you'll gain time. |
Yes i know, but it used an old lvgl with no font loading support.(7.2) And for linux display, mouse is used as touch input, and mousewheel as encoder. so you can test some part of ui. you can't test everything, but designing the windows, etc is easier. and it add no code in Marlin as it use external lvgl driver library. |
Currently, MKS makes an hacky use of LVGL filesystem to implement the G-Code preview icon feature. You'll have hard time fixing this (I've done it here, but it was rejected since it was solving a deprecated issue). Also, there is some outgoing effort to use LVGL 7 here. I don't know how good it is however. |
I already did the mks ui working on lvgl 7, a long time ago. I will resurrect the branch. |
Hello, i don't stop working on it, but can't work on it every week. Feel free to close it if you want, i'll reopen it when development from my side will be finished. |
12b98af
to
9501b5b
Compare
This has been brought up to date, cleaned up, and tweaked to conform better to Marlin S&P. Please work up a test compilation that succeeds and we can add it as a new CI test for continued development. |
Thanks, i'm a bit busy now as my work is in bankrupt, and i have to do a lot of things for that. |
@rhapsodyv What is your LVGL7 branch you are referring to ? |
It's a stash. I updated it with the last marlin bugfix. I need to update the style code, that changed from 6 to 7. I might send a PR in the next days. I'm just waiting the 2.0.8 release. This pic is of the lastest lvgl (as you see, just re apply the styles now) |
I've reworked the color picker widget in LVGL7 (submitted to lvgl repository, but they merged it in v8), so please @ mention me when you post your PR so I can send you the new code. It's required for #21158. Thanks! |
Using standard LVGL, we can just enable/disable it right on marlin lv_conf.h . |
That's one of the things to do, but the cpicker is:
See here for (1), the change for V8 is merged already I don't know if (3) is fixed in your code (it might be), but (1) and (2) is really required for a working color wheel. |
Anyway, I'll adapt once your code is merged. |
I'm using lvgl v7.10.1, but we can point it to their dev branch. |
Honestly, the v8's dev branch is very far from the v6/v7. They reworked almost everything. So, it'll be a hard work to do. If your code is using v7.10, it's ok for me as my patch will apply (it applied on v7.11). |
Won't they apply your patch on v7?? |
They approved it, but after discussing with the original author, they decided they won't apply any more patch to v7 and instead switched to v8. v7 is now in support-mode, it won't receive any change, only bug fix as far as I understood. See first link in my previous comment for the history and the patch. |
e90c213
to
4b9bb85
Compare
27df113
to
8d31429
Compare
de391db
to
0f34163
Compare
Co-Authored-By: belese <2719742+belese@users.noreply.github.com>
This is still interesting, though it might be more suitable as an addition to the MarlinSimUI project. I went ahead and rebased it in case anyone still wants to experiment with this. |
c624e13
to
e6f1b07
Compare
9c65146
to
4f65466
Compare
c792921
to
37fb26b
Compare
37d77d6
to
aa44542
Compare
The goal is to remove LVGL configuration stuff from UI code and make lvgl already configured for extui that want to use it.
It doesn't add anything in Marlin Core.
It also add SDL display (Linux Only), mainly for developpement
And i would also initialise LVGL filesystem for SD Card and Flash storage and upload assets if found on sd card
My Idea for flash storage, was to split it in 3 'lvgl filesystem'.
one for Font
one for Bitmap (with a lvgl image decoder for compressed image)
one for the Ui data
PS : Last commit is Linux configuration and hello world ui for lvgl.
Requirements
Linux or tft screen
for linux, sdl libraries
apt-get install gcc-multilib g++-multilib libsdl2-dev
Benefits
Easier to add LVGL UI, and developpe UI faster with SDL
LVGL also support lcd screen, but i haven't one, so i' will not add it.
Any thought are welcome.
Johan