Skip to content
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

perf: LVGL 8.3 #3279

Merged
merged 7 commits into from
Nov 7, 2023
Merged

perf: LVGL 8.3 #3279

merged 7 commits into from
Nov 7, 2023

Conversation

gagarinlg
Copy link
Member

@gagarinlg gagarinlg commented Feb 28, 2023

Summary of changes: switch to LVGL v8.3 which contains a number of bug fixes and faster the DMA2D usage has been improved

@pfeerick
Copy link
Member

pfeerick commented Apr 10, 2023

The tests for this failed as there has been a fractional colour shift (and I do mean fractional, I only noticed it when zooming in on the text - and text only, but the colour picker can see/quantify it)... any idea where that came from, and is it anything to be worried about?

Original:
primitives_EN_480x272
Failed:
primitives_EN_480x272_failed
Original:
transparency_EN_480x272
Failed:
transparency_EN_480x272_failed

@pfeerick pfeerick added the color Related generally to color LCD radios label Apr 10, 2023
@gagarinlg
Copy link
Member Author

They did some changes to the font rendering with 8.3

@pfeerick
Copy link
Member

Fair enough, I'll update the tests and continue on then :)

@pfeerick pfeerick self-assigned this Apr 10, 2023
@pfeerick
Copy link
Member

This looks mostly good with two minor issues

  • The standalone lua scripts screen seems like it's either one pixel short, or one pixel higher on the 480x272 screen (but seems ok on the 320x480) - i.e. there is a single row of white at the bottom of the screen that wasn't there on a prior nightly on the TX16S

  • default splash screen on the NV14/EL18 will need some TLC as the "blank" space above and below is now filled with in-memory garbage - I guess a screen clear or fill before showing the logo?

@richardclli
Copy link
Collaborator

richardclli commented Apr 13, 2023

For the splash screen, see if this can resolve the problem. #2764
I do not know how to work out the effect in #638, but it can replace the current splash screen with a dynamic background.

@pfeerick
Copy link
Member

pfeerick commented Apr 13, 2023

Yup, that'll do for now... (just tried it cherry-picked into this PR) so you're fine with that being merged even though you still have it marked as draft? 😆

@richardclli
Copy link
Collaborator

Yup, that'll do for now... (just tried it cherry-picked into this PR) so you're fine with that being merged even though you still have it marked as draft? 😆

I change the status of the PR, let's use it first.

@pfeerick pfeerick added this to the 2.9 milestone Apr 14, 2023
@gagarinlg gagarinlg modified the milestones: 2.9, 2.10 May 6, 2023
@gagarinlg
Copy link
Member Author

Moved to 2.10, because it is waiting for libopenui changes

@pfeerick
Copy link
Member

pfeerick commented May 7, 2023

And more importantly, it looks like there are still some kinks to be worked out.

@raphaelcoeffic
Copy link
Member

@gagarinlg @philmoz let's tackle this in September :-) It seems the 8.3.x series is getting mature now (currently at v8.3.9).

@raphaelcoeffic raphaelcoeffic marked this pull request as draft August 12, 2023 05:37
@pfeerick pfeerick added the needs: rebase A git rebase on top of the latest destination branch version is required label Oct 16, 2023
@pfeerick pfeerick added house keeping 🧹 Cleanup of code and house keeping and removed needs: rebase A git rebase on top of the latest destination branch version is required labels Oct 20, 2023
@pfeerick pfeerick changed the title Lvgl 8.3 perf: LVGL 8.3 Oct 20, 2023
@pfeerick
Copy link
Member

I think this issue

The standalone lua scripts screen seems like it's either one pixel short, or one pixel higher on the 480x272 screen (but seems ok on the 320x480) - i.e. there is a single row of white at the bottom of the screen that wasn't there on a prior nightly on the TX16S

is still present, and it could actually be out one row at the bottom, and on the right side (making it one pixel down and one pixel in, since the screen is flipped?). It's most noticeable for me with Offer's Model Flight Log viewer (https://github.com/offer-shmuely/edgetx-x10-scripts/tree/main/SCRIPTS/TOOLS/LogViewer), as I get a white line on at the bottom and right side when the splash screen is being shown, but I do get it other times also.

@philmoz
Copy link
Collaborator

philmoz commented Oct 20, 2023

I think this issue

The standalone lua scripts screen seems like it's either one pixel short, or one pixel higher on the 480x272 screen (but seems ok on the 320x480) - i.e. there is a single row of white at the bottom of the screen that wasn't there on a prior nightly on the TX16S

is still present, and it could actually be out one row at the bottom, and on the right side (making it one pixel down and one pixel in, since the screen is flipped?). It's most noticeable for me with Offer's Model Flight Log viewer (https://github.com/offer-shmuely/edgetx-x10-scripts/tree/main/SCRIPTS/TOOLS/LogViewer), as I get a white line on at the bottom and right side when the splash screen is being shown, but I do get it other times also.

Is it reproducible in the simulator?

@philmoz
Copy link
Collaborator

philmoz commented Oct 20, 2023

@pfeerick If you mean like the image below then this happens in the simulator on both 2.8.4 and 2.9.1 as well.

The problem is the image itself has these lines at the bottom and right edge.

screenshot_tx16s_23-10-20_17-33-37

@pfeerick
Copy link
Member

pfeerick commented Oct 20, 2023

Thanks for checking that... I hadn't tried on simulator, but now that I had what I thought was an easily reproducible test case I tried it on nightly and that was the same. I also just noticed the ELRS Lua has a thin border on the left right and bottom sides, and that is visible on this branch, so whatever caused this before is clearly gone. Now it's just a matter of any final changes to the LVGL 8.3 branch.

@philmoz
Copy link
Collaborator

philmoz commented Oct 20, 2023

There is something going wrong though.
I get this line at the bottom on the EdgeTX 3.0 UI demo script on my TX16S; but not in the simulator.

Does not happen with current main.

screen-2023-10-20-173155

Unfortunately as it's distributed pre-compiled it's not possible to see how the image is being displayed and debug the code.

@pfeerick
Copy link
Member

I've seen something exactly like that before, so that could have been what was happening before (it was a few months ago 🤭), or I've seen that same glitch elsewhere. 🤷

@philmoz
Copy link
Collaborator

philmoz commented Oct 21, 2023

I did some investigation into the white bottom line issue with LVGL 8.3.

It seems to be some timing issue or conflict with the DMA used to copy the standalone script bitmap and the DMA used to rotate the screen.

The rotate screen code does a line at a time starting at the bottom row of the source and working up. If I change the direction so it works from the top row of the source and works down the problem goes away.

@pfeerick
Copy link
Member

Looks like the structure of lv_style_t changed in 8.3... so this is not playing nicely with #4180.

@philmoz
Copy link
Collaborator

philmoz commented Oct 31, 2023

Looks like the structure of lv_style_t changed in 8.3... so this is not playing nicely with #4180.

Should be fixed now.

@pfeerick pfeerick marked this pull request as ready for review November 4, 2023 08:54
@pfeerick pfeerick self-requested a review November 4, 2023 08:54
Copy link
Member

@pfeerick pfeerick left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TX16S and EL18 both seem ok now with this PR... no immediately visible issues after loading several themes, trawling through some images, running some widgets and standalone Lua like Offer's graphing log viewer...

@pfeerick pfeerick merged commit e9d7428 into main Nov 7, 2023
37 checks passed
@pfeerick pfeerick deleted the lvgl8.3 branch November 7, 2023 10:57
pfeerick added a commit that referenced this pull request Nov 7, 2023
pfeerick added a commit that referenced this pull request Nov 10, 2023
pfeerick added a commit that referenced this pull request Nov 12, 2023
pfeerick added a commit that referenced this pull request Nov 12, 2023
@robustini
Copy link
Contributor

Horus X10S Express: when I change the points of a curve the selection has tremendous lag.
With LVGL 8.2 it was fine.

richardclli pushed a commit that referenced this pull request Nov 14, 2023
richardclli pushed a commit that referenced this pull request Nov 15, 2023
richardclli pushed a commit that referenced this pull request Nov 17, 2023
richardclli pushed a commit that referenced this pull request Nov 17, 2023
richardclli pushed a commit that referenced this pull request Nov 20, 2023
richardclli pushed a commit that referenced this pull request Nov 20, 2023
richardclli pushed a commit that referenced this pull request Nov 21, 2023
pfeerick added a commit that referenced this pull request Nov 24, 2023
richardclli pushed a commit that referenced this pull request Nov 24, 2023
richardclli pushed a commit that referenced this pull request Nov 28, 2023
richardclli pushed a commit that referenced this pull request Nov 30, 2023
richardclli pushed a commit that referenced this pull request Dec 3, 2023
richardclli pushed a commit that referenced this pull request Dec 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
color Related generally to color LCD radios house keeping 🧹 Cleanup of code and house keeping
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants