41 views
in GUI Development by
Hi!

In my project, I read around 2000 data from SD card memory and store in Embedded wizard Local variable for the purpose of displaying in a vertical list. That works fine. But after returning from that Unit, if I tried to read some data from flash memory in a different Unit, system freeze. Reading from flash fails. This happens only after read form SD card, store the data in local array and view in vertical list. According to my knowledge, the memory used by local array will be freed when I come out of the Unit. Since system freeze happens only after accessing that unit, Is there any way to make sure memory release after returning from specific Unit. Can I call EwReclaimMemory() function to free memory when I exit that UNIT? Do you suggest any better ways to handle this?

Thank you

 

Regards,

Thanushiyah

1 Answer

0 votes
by
Hello Thanushiyah,

the memory management (respective the garbage collection) is not related to a Unit. As long as an object is referred somewhere in your software, it is kept in the memory. As soon as an object is no more needed (because there is no reference) it is freed automatically. There is no need to call EwReclaimMemory() separately. It is called automatically after each screen update.

Maybe there is some issue with the flash reader / SD card reader? Try to separate the GUI from the data access and test each of them.

Best regards,

Manfred.

Ask Embedded Wizard

Welcome to the question and answer site for Embedded Wizard users and UI developers.

Ask your question and receive answers from the Embedded Wizard support team or from other members of the community!

Embedded Wizard Website | Privacy Policy | Imprint

...