Hi everyone Does someone know how to change the length of on array during the run time execution? I mean how can I request memory to use it for a array? Is there somthing like malloc()? Thanks!
"Is there somthing like malloc()?" To answer your question directly there is indeed something like malloc(): malloc(), in fact. However, as others have pointed out using malloc() is a bad idea in most 8051 situations. If you need dynamic allocation because your total memory requirements exceed your available memory then declare arrays as local variables within functions and let the overlay manager perform its magic.
"To answer your question directly there is indeed something like malloc(): malloc(), in fact." And then to answer your question even more directly about runtime changes, after malloc(), you would use realloc() to change size. http://www.keil.com/support/man/docs/c51/c51_realloc.htm
View all questions in Keil forum