Getting the object name of a widget

This should work:

    lv_obj_type_t buf;
    lv_obj_get_type(obj, &buf);

    uint8_t i = 0;
    while(buf.type[i] != NULL) {
        if(!strcmp(buf.type[i], "lv_textarea")) { /* use lv_ta for 6.1 and under */
            /* It inherits from a text area*/
        }
        i++;
    }