Skip to content

[ LV_ROLLER] function compareRollerOptions does not exits #792

Open
@arturv2000

Description

@arturv2000

Describe the bug

Project type as LVGL(No EEZ Flow).

When using a widget LV_ROLLER and assigning variable to the options an error occurs during compilation of project.

../Drivers/STM32/GUI/src/ui/screens.c:2870:9: warning: implicit declaration of function 'compareRollerOptions' [-Wimplicit-function-declaration]
 2870 |     if (compareRollerOptions((lv_roller_t*) objects.roller_select_ils, new_val, cur_val, LV_ROLLER_MODE_NORMAL) != 0) {
      |         ^~~~~~~~~~~~~~~~~~~~


c:/program files (x86)/gnu arm embedded toolchain/10 2021.10/bin/../lib/gcc/arm-none-eabi/10.3.1/../../../../arm-none-eabi/bin/ld.exe: ./Drivers/STM32/GUI/src/ui/screens.o: in function `tick_screen_ils_selection':
D:\Projectos\***\***\****\Debug-STM32/../Drivers/STM32/GUI/src/ui/screens.c:2870: undefined reference to `compareRollerOptions'

The function is not part of LVGL (at least don't find anything as compareRollerOptions

As a quick workaroud, change the definition of screens.c to:

#include <string.h>

#include "screens.h"
#include "images.h"
#include "fonts.h"
#include "actions.h"
#include "vars.h"
#include "styles.h"
#include "ui.h"

static int32_t compareRollerOptions(lv_roller_t *roller, const char *new_val, const char *cur_val, lv_roller_mode_t mode) {
        return strcmp(new_val, cur_val) != 0;
}

//${eez-studio LVGL_SCREENS_DEF}
//${eez-studio LVGL_SCREENS_DEF_EXT}

int eez_flow_get_selected_theme_index() { return 0; }

To Reproduce
Steps to reproduce the behaviour:

  1. Create a new project
  2. Select type as LVGL (no EEZ flow)
  3. Add a Roller widget
  4. Configure the options to have source as variable
  5. Generate the code
  6. Attempt to compile the code in a C project...

Expected behaviour
A clear and concise description of what you expected to happen.

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: [Windows]
  • Version [0.23.2]

** LVGL version (if used)**

  • 9.2

Additional context

Project is type LVGL no EEZ flow...

Disclaimer
Please take into account that the tasks reported here will be processed by the Envox team according to the best effort principle, so adjust your expectations accordingly. However, if you want a more prompt and high-quality response as well as direct contact with technical support, you can choose one of our Support plans.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions