Hi all,
I’d like to share an issue and workaround for GUI Guider + LVGL v9 simulator with FreeMASTER binding.
Environment: GUI Guider 9.2 / 1.10.0 GA, LVGL v9 simulator (lvgl-simulator or lv_web_emscripten),
FreeMASTER JSON-RPC WebSocket (ws://localhost:41000), Windows 10/11.
Problem: When a FreeMASTER variable is bound to a Meter/Scale widget using an Image Needle,
the needle disappears or does not update correctly. The same variable bound to a Label updates
normally (e.g., 40–60), so the incoming value is valid.
Workaround/Fix: Patch the simulator code (or the template) here:
C:\nxp\GUI-Guider-1.10.0-GA\environment\template\project\v9\lvgl-simulator\gg_external_data\freemaster\freemaster_client.c
Update the GG_METER case to safely handle image needles vs line needles (and add NULL guards):
case GG_METER:
{
for (int i = 0; i < user_parm->arrayLen; i++)
{
meter_needle *nd = (meter_needle *)user_parm->childObjArray[i];
int v = atoi(dataArray[i]);
if (nd && nd->needle_obj)
{
if (lv_obj_check_type(nd->needle_obj, &lv_image_class))
lv_scale_set_image_needle_value(user_parm->parentObj, nd->needle_obj, v);
else
lv_scale_set_line_needle_value(user_parm->parentObj, nd->needle_obj, nd->needle_length, v);
}
}
break;
}
Question: Is this a known issue? If not, could this fix be integrated into future GUI Guider releases/templates?
Thanks.