acid-drop

- Hacking the planet from a LilyGo T-Deck using custom firmware
git clone git://git.acid.vegas/acid-drop.git
Log | Files | Refs | Archive | README | LICENSE

lv_rt_thread_conf.h (1920B)

      1 /*
      2  * Copyright (c) 2006-2021, RT-Thread Development Team
      3  *
      4  * SPDX-License-Identifier: MIT
      5  *
      6  * Change Logs:
      7  * Date           Author       Notes
      8  * 2021-10-15     Meco Man     The first version
      9  */
     10 
     11 #ifndef LV_RT_THREAD_CONF_H
     12 #define LV_RT_THREAD_CONF_H
     13 
     14 #ifdef __RTTHREAD__
     15 
     16 #define LV_RTTHREAD_INCLUDE <rtthread.h>
     17 #include LV_RTTHREAD_INCLUDE
     18 
     19 /*=========================
     20    MEMORY SETTINGS
     21  *=========================*/
     22 
     23 #ifdef RT_USING_HEAP
     24 #  define LV_MEM_CUSTOM 1
     25 #  define LV_MEM_CUSTOM_INCLUDE LV_RTTHREAD_INCLUDE
     26 #  define LV_MEM_CUSTOM_ALLOC   rt_malloc
     27 #  define LV_MEM_CUSTOM_FREE    rt_free
     28 #  define LV_MEM_CUSTOM_REALLOC rt_realloc
     29 #endif
     30 
     31 /*====================
     32    HAL SETTINGS
     33  *====================*/
     34 
     35 #define LV_TICK_CUSTOM 1
     36 #define LV_TICK_CUSTOM_INCLUDE LV_RTTHREAD_INCLUDE
     37 #define LV_TICK_CUSTOM_SYS_TIME_EXPR (rt_tick_get_millisecond())    /*Expression evaluating to current system time in ms*/
     38 
     39 /*=======================
     40  * FEATURE CONFIGURATION
     41  *=======================*/
     42 
     43 /*-------------
     44  * Logging
     45  *-----------*/
     46 
     47 #ifdef PKG_LVGL_ENABLE_LOG
     48 #  define LV_USE_LOG 1
     49 #else
     50 #  define LV_USE_LOG 0
     51 #endif
     52 
     53 /*-------------
     54  * Asserts
     55  *-----------*/
     56 
     57 #define LV_ASSERT_HANDLER_INCLUDE LV_RTTHREAD_INCLUDE
     58 #define LV_ASSERT_HANDLER RT_ASSERT(0);
     59 
     60 /*-------------
     61  * Others
     62  *-----------*/
     63 
     64 #define LV_SPRINTF_CUSTOM 1
     65 #define LV_SPRINTF_INCLUDE LV_RTTHREAD_INCLUDE
     66 #define lv_snprintf  rt_snprintf
     67 #define lv_vsnprintf rt_vsnprintf
     68 #define LV_SPRINTF_USE_FLOAT 0
     69 
     70 /*=====================
     71  *  COMPILER SETTINGS
     72  *====================*/
     73 
     74 #ifdef ARCH_CPU_BIG_ENDIAN
     75 #  define LV_BIG_ENDIAN_SYSTEM 1
     76 #else
     77 #  define LV_BIG_ENDIAN_SYSTEM 0
     78 #endif
     79 
     80 #define LV_ATTRIBUTE_MEM_ALIGN ALIGN(4)
     81 
     82 /*==================
     83 * EXAMPLES
     84 *==================*/
     85 
     86 #ifdef PKG_USING_LVGL_EXAMPLES
     87 #  define LV_BUILD_EXAMPLES 1
     88 #endif
     89 
     90 /*--END OF LV_RT_THREAD_CONF_H--*/
     91 
     92 #endif /*__RTTHREAD__*/
     93 
     94 #endif /*LV_CONF_H*/