2023-05-31 10:59 PM
Hi ST Community,
Thank you so much in advance for your timely support.
void _exit (int status)
{
_kill(status, -1);
while (1) {} /* Make sure we hang here */
}
Regards,
Nandagopal
Solved! Go to Solution.
2023-06-01 09:40 PM
I figured it out everyone !
Sharing my findings in case anyone finds it helpful.
The Touch GFX generated code declares the scroll list with a fixed size of 6 as shown. This is in theViewbase.hpp file of the corresponding screen in the generated code/
touchgfx::DrawableListItems<Procedure_List_Item, 6> scrollList1ListItems;
This in my case prevents me from updating the scrollList1ListItems manually for each index.
Even if I update the scrollList1.setNumberOfItems(). It does not reflect in the array size of the scrollList1ListItems.
I was treating the scrollList1ListItems as an array I can call in my setup function of the screen. The moment I call the 7th element, code exceeds the prescribed size. and goes to the exit() function as said.
What I have to do is override the generated scrollList1UpdateItem function and update the text fields from there. Whenever I call the scrollList1.setNumberOfItems() function. TouchGFX will automatically call the scrollList1UpdateItem function for every list item in the scroll list.
Doing this has fixed the issue for me!
Thank you all
Regards,
Nandagopal
2023-06-01 11:49 AM
Hello.
Have you set enough big number as 'number of items' in scroll list ?
How do you share the added elements between ADD screen and LIST screen, maybe there is some problem.
2023-06-01 09:40 PM
I figured it out everyone !
Sharing my findings in case anyone finds it helpful.
The Touch GFX generated code declares the scroll list with a fixed size of 6 as shown. This is in theViewbase.hpp file of the corresponding screen in the generated code/
touchgfx::DrawableListItems<Procedure_List_Item, 6> scrollList1ListItems;
This in my case prevents me from updating the scrollList1ListItems manually for each index.
Even if I update the scrollList1.setNumberOfItems(). It does not reflect in the array size of the scrollList1ListItems.
I was treating the scrollList1ListItems as an array I can call in my setup function of the screen. The moment I call the 7th element, code exceeds the prescribed size. and goes to the exit() function as said.
What I have to do is override the generated scrollList1UpdateItem function and update the text fields from there. Whenever I call the scrollList1.setNumberOfItems() function. TouchGFX will automatically call the scrollList1UpdateItem function for every list item in the scroll list.
Doing this has fixed the issue for me!
Thank you all
Regards,
Nandagopal
2023-06-01 09:42 PM
Thank you JTP for taking the time to respond.
I have solved it. It was a different issue. Please see my findings on the thread.
Regards,
Nandagopal