Comments (5)
To use extend SPI flash for glyph storage, does this require calling a custom function to read the glyph data? I will put this on our dev backlog, but I am concerned about the performance impact. I think we would need to implement some sort of glyph caching mechanism so that we are not constantly reading the glyph data from slow memory. Do you have any thoughts on that?
from guix.
The function of reading and writing external memory is placed in the thread. I think it is acceptable for users. For example, touchgfx adopts this method. For users who have such needs, it can connect to a slower screen. For the refresh rate, you can consider making the read graphics and font data into a function pointer, which is implemented by the user, so that it has good applicability. Not sure what you think about this method.
from guix.
Many chips have dma function, reading spi flash can also be very fast, of course, it is slower than internal flash
from guix.
Hello @yuntian365 ,
Thanks for your feedback. I want to be 100% sure we are on the same page. Depending on the hardware architecture, it might be possible to directly read external SPI flash through a pointer, or it may require invoking a hardware-specific routine to read the SPI flash data. So I want to know which situation you are requesting.
If the external flash data is directly accessible via a standard C pointer, I think that is well supported in GUIX today. You can generate binary resource file(s), and write that binary data file to your external SPI flash. You can then use APIs such as gx_binres_theme_load to dynamically build your resource table, and install this resource table using gx-display_theme_install. When you call gx_binres_theme_load, GUIX builds a table of pointers to your resource data, it doesn't copy your resource data (including your glyph data) to RAM or anything like that. So if your SPI flash is directly accessible I think this is a working solution.
If your SPI flash is not directly accessible, but requires a "ReadDataOverSPI()" type function to be invoked, that is the case that would require some work on our side (allow you to install data read callback functions) and probably also do some caching of the data so that we don't have to invoke ReadDataOverSPI() every time we want to render the glyph "e" (for example). Let me know if we are on the same page and I will write up a task for our dev backlog.
from guix.
hi, @jdeere5220,
Thank you for your reply, yes, this requirement is applied to those spi flash that cannot be read directly through pointers. This kind of flash is not supported by MCU to read in a mapped way, and the resource data needs to be written by the user "ReadDataOverSPI()" to read, such as read_flash_byte(dev*, uint32_t adr, uint8_t *buf, uint16_t len) to read the required bytes, this read interface reserves a function pointer interface inside guix, if this If the pointer = null, it will be read by direct mapping, which is the current processing method of guix. If the user sets this pointer, then this function pointer will be used to read resource data from spi flash.
Similar applications such as: stm32f401rct, its internal flash has 256k, but the resource data of the application program will exceed 256k, and the space required by the code does not need to use up 256k, so the resource data must be put into the external spi flash, but unfortunately The thing is, this chip does not support the direct reading of the mapping mode by pointer, it requires the user to write a function to read the spi flash data, and currently guix does not support this method, similar chips such as some low-cost chips Such as stm32g0xx and the like, also do not have the mapping function, also need the user to write the spi flash function, as a product series, we certainly do not want to switch to other ui, if guix can provide this function, it is very worth looking forward to.
The user implements spi flash reading by himself, of course, it will be slower than the mapping method using pointer to read, but this application is originally used in projects with low requirements, and it is placed in the thread, the user will not feel too strong , the screen refresh rate is not high.
from guix.
Related Issues (20)
- PNG/DEFLATE font compression
- How to implement physical key operations
- GuiX Studio uses the Azure-RTOS GUIX repo, rather than the Eclipse-ThreadX repository HOT 1
- GUIX resources typo
- GUIX multiple identical resources
- How to uncompress compressed pixelmaps in GUIX?
- Documentation question about gx_system_event_send() error code HOT 8
- Incorrect PNG function being called when 2d engine is disabled HOT 3
- Bad LowerCase/UpperCase file loading in recent file window HOT 3
- GUIX Studio RGB888 frame buffer support HOT 7
- Documentation Errors HOT 5
- 4bit per pixel png image support HOT 2
- GUIX in low power mode HOT 11
- gx_studio_auto_event_handler calls event function on a deleted widget HOT 9
- GUIX Studio font heights above 240 pixels are not possible HOT 2
- If a vertical lists has a multiple childs of different heights, the scrollbar thumb does not reach the end of the scrollbar HOT 3
- The GX_EVENT_FOCUS_LOST event is not sent if the parent does not have focus HOT 2
- GX_VERTICAL_LIST does not release input if it contains GX_SINGLE_LINE_TEXT_INPUT HOT 2
- Increase maximum font size HOT 2
- Hebrew : multiline text view widgets dont display correctly on several lines HOT 10
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from guix.