Skip to main content

Light and Versatile Graphics Library (VLGL ) with STM32

 

   LVGL (Light and Versatile Graphics Library) is a free and open-source graphics library providing everything you need to create embedded GUI with easy-to-use graphical elements, beautiful visual effects and a low memory footprint. He whole library is developed in pure c language and easy to port. The main features of littleVGL are as follows:

  •  Has a very rich built-in controls, such as buttons, charts, lists, sliders, images, etc.

  • Advanced graphic effects: animation, anti-aliasing, transparency, smooth scrolling

  • Supports multiple input devices, such as touchpad, mouse , keyboard, encoder, etc

  • Fully customizable graphic elements

  • Support multi-language UTF-8 encoding

  • Support multiple and multiple display devices, such as simultaneous display on multiple color screens or monochrome screens

  • The hardware is independent of any micro Controller or display

  • Can be reduced to the smallest memory (64 kB Flash, 16 kB RAM)

  • Support operating system, external storage and GPU (not required)

  • Only a single frame buffer device can present advanced visual effects

  • Use C to write Maximum compatibility (C++ compatible)

  •  Support PC simulator


Requirements

  • 16, 32 or 64 bit microcontroller or processor
  • > 16 MHz clock speed is recommended
  • Flash/ROM: > 64 kB for the very essential components (> 180 kB is recommended)
  • C99 or newer compiler

All repositories of the LVGL project are hosted on GitHub: https://github.com/lvgl


 LVGL ported to STM32F103

  First you can download LVGL library porting from this link  Dowanload.  and LVGL_DEMO  also download from this link. 
 
First open LVGL folder and select and copy file and folder from there. Create new Folder VLGL for that paste it.



Now Change lv_conf_template.h to lv_conf.h

Next Step is Open lv_config.h Change the first line #if 0 to #if 1, to enable lv_conf.h.

 lv_conf.h File Change

Next Step is 
Open the lvgl/examples/porting folder, which contains data that interacts with the hardware layer.

 lvgl/examples/porting folder,

Remove all _templates in the 8 files, and change #if 0 to #if 1 in everyfile. 
Remove _TEMP from All files  the macro definition. 
just like to Change the macro definition in file lv_port_disp.c :

 #include "lv_port_disp_templ.h" to change as "lv_port_disp.h" 

same this for  other C Files in fs and indevs are also modified accordingly. 
fs is related to the file system

indev is related to input devices, buttons, touch screens, mice, etc.


Now make some change in lv_config.h file as shown below

modify lv_config.h File



Example

Here  we create project of STM32F103RGT which have Flas Memory 1096 kb and RAM as 96 kb with basic setting




Next Step is to create folder VLGL and VLGL_Port folders in project . as show in below pic.



Now add VLGL folder source and example folder in it. and VLGL_Port have poring  files as shown below pics.











Comments

Popular posts from this blog

ARDUINO PORTENTA H7 Tutorial

Portena H7 simultaneously run high level code along with real time tasks. H7 main processor is the STMICROELECTRONICS dual core STM32H747  including an ARM CORTEX -M7 running at 480 MHz and ARM COTEXT M4 running at 240MHz. The two core communicate via a Remote Procedure call mechanism that allows calling functions on the other processor seamlessly. The  Portenta H7  simultaneously runs high level code along with real time tasks, since it includes two processors that can run tasks in parallel. For example, it is possible to execute Arduino compiled code along with MicroPython one and have both cores to communicate with one another. The Portenta functionality is two-fold, it can either be running like any other embedded microcontroller board or as the main processor of an embedded computer. There are many features in one module  STM32H747 dual-core processor 8 MB SDRAM 16 MB  NOR FLASH 10/100 ETHERNET PHY USB HIGH SPEED SECURE ELEMENT WIFI/ BLUETOOTH MODULE UFL CO...

Getting Started with mmWave Sensor MR60BHA1 and Arduino

Introduction : The MR60BHA1 mmWave Sensor is a compact and efficient radar sensor that utilizes millimeter-wave technology to detect objects, measure distance, and track motion. With its high precision and low power consumption , this sensor is ideal for applications in robotics, automation, and security systems. . Millimeter-wave (mmWave) sensors operate at extremely high frequencies, typically in the 30GHz to 300GHz range, allowing them to detect objects with great accuracy regardless of lighting conditions. Unlike optical sensors, mmWave sensors can penetrate fog, dust, and even certain materials, making them reliable in harsh environments. The MR60BHA1 is one such sensor that operates at 60GHz , providing precise motion detection and range measurement capabilities. By integrating the MR60BHA1 with an Arduino , users can develop a variety of projects, such as human presence detection , security systems , and robotic navigation . In this blog, we will explore how to interface...

Exploring Color Sensing with Arduino: A Journey into the World of RGB Detection

                           In today's tech-driven world, the Arduino platform continues to empower enthusiasts and professionals alike to explore the realms of electronics and programming. One fascinating avenue within this domain is color sensing using Arduino boards. With the integration of RGB sensors, Arduino opens up a world of possibilities for projects ranging from color sorting machines to ambient light displays. Let's delve into the exciting world of color sensing with Arduino and discover its applications, principles, and how you can embark on your own creative endeavors. Understanding Color Sensing       At the heart of color sensing lies the ability to distinguish between different wavelengths of light. RGB (Red, Green, Blue) sensors are commonly used for this purpose. These sensors typically consis...