mirror of
https://github.com/micropython/micropython.git
synced 2026-01-06 20:20:14 +01:00
esp8266/modesp: Add malloc() and free() functions.
Useful for testing fragmentation issues in OS heap. E.g. freemem() may report large amount, but is it possible to actually allocate block of a given size? Issue malloc() (followed by free()) to find out.
This commit is contained in:
@@ -20,4 +20,8 @@ void ets_timer_arm_new(os_timer_t *tim, uint32_t millis, bool repeat, bool is_mi
|
||||
void ets_timer_setfn(os_timer_t *tim, ETSTimerFunc callback, void *cb_data);
|
||||
void ets_timer_disarm(os_timer_t *tim);
|
||||
|
||||
// These prototypes are for recent SDKs with "malloc tracking"
|
||||
void *pvPortMalloc(unsigned sz, const char *fname, int line);
|
||||
void vPortFree(void *p, const char *fname, int line);
|
||||
|
||||
#endif // _INCLUDED_ETSHAL_H_
|
||||
|
||||
Reference in New Issue
Block a user