5 Tips for Optimizing GUIs in Industrial Applications

Industrial applications have traditionally involved analog buttons, switches, and dials to interact with a user. As you are aware, times are changing, and industrial application users now need rich graphical user interfaces. Many interfaces are built on top of embedded systems, which are quite powerful, but they are still resource-constrained systems. They may be resource-constrained in processing power, memory, or in battery life. In today’s post, we will examine several tips for optimizing GUIs in industrial applications.

Tip #1 – Draw images directly from flash

GUI images are often stored in flash memory as PNG’s. The PNG file format is a compressed image format that is designed to save space. This sounds great, but if the image is compressed, that means the processor needs to decompress the image before it can be written to the frame buffer. Decompressing the image doesn’t just require internal RAM but also will waste potentially precious clock cycles to decompress the image.

The optimization developers can leverage is to decompress their PNGs and store them in flash in the TGA format. This format is an uncompressed file format that supports 8, 16, 24 or 32 bits per pixel with an 8-bit alpha channel. While each image will be larger than the PNGs, it can be directly written from flash to the frame buffer without the need to waste CPU cycles and RAM for decompression. Thankfully, flash memory is generally very cheap, and many system designers oversize them anyways so this optimization not only will improve system performance but should also have minimal impact on system costs.

Tip #2 – Optimize the image storage format

There are several different image formats that can be used to interact with a display, but they are not all created equally and have various advantages and disadvantages. For example, the RGB888 format provides developers with a 24-bit per pixel color depth, which means 8-bits are used for each red, green, and blue color control. While this does provide rich color, storing the images can require additional storage space in addition to more complex hardware and harnessing requirements.

A good trade-off for industrial applications is to instead use the RGB565 format. The RGB565 format provides developers with 16-bit per pixel color depth where 5-bits are used to represent red, 6-bits are used to represent green, and 5-bits are used to represent blue. Obviously, the color fidelity will not be as rich as the RGB888 format since we are using 16-bit instead of 24-bit representations. To regain some of that color fidelity that is lost due to fewer bits being available, we can add dithering to the image. The result is a nice-looking image with savings in storage and computing power.

Tip #3 – Carefully optimize animations

In general, an animation can go a long way in sprucing up a …

Continue Reading at the Crank Software blog: 5 Tips for Optimizing GUIs in Industrial Applications.

 

Share >

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.