2024-10-07 04:19 AM
Hello members of the ST community,
I want to access LAN8742 PHY with RMII via ethernet protocol with STM32H743VIT6 microcontroller. I want to run the system using the default address settings generated by CubeMX. I created 10kB space for MEM_SIZE. I wanted to access the callback function of the system over ethernet by creating a UDP server. The system does not enter the callback function determined by the data coming over UDP. The addressing I used in this microcontroller is shown below;
LWIP_RAM_HEAP_POINTER : 0x30004000
First Tx Identifier Address : 0x30000080
First Rx Identifier Address : 0x30000000
Rx Buffers Address : 0x30000100
I found an application for lwIP application in the forum using MII connections. I tried the configurations there but no results. When I run the system in debug mode, mem_malloc: could not allocate in mem.c is returned;
MEM_STATS_INC(err);
LWIP_MEM_ALLOC_UNPROTECT();
sys_mutex_unlock(&mem_mutex);
LWIP_DEBUGF(MEM_DEBUG | LWIP_DBG_LEVEL_SERIOUS, (“mem_malloc: could not allocate %”S16_F“ bytes\n”, (s16_t)size));
return NULL;
Can you help how to fix this problem. Thanks.
Solved! Go to Solution.
2024-10-08 09:38 AM
You can also refer to this github link (especially for flash.ld file modification for placement of DMA descriptors and RX buffers).
2024-10-07 06:00 AM
Hello @mmercan and welcome to the community,
Could you please refer to this article on how to create a project for STM32H7 with Ethernet and LwIP stack
2024-10-08 09:38 AM
You can also refer to this github link (especially for flash.ld file modification for placement of DMA descriptors and RX buffers).