2024-12-10 08:27 AM
Hi,
Context : STM32F777, FreeRTOS, Cmsis V2, LWIP, Sockets, TCP, UDP
Only one task is used to open, listen, poll, accept, send, receive, and close sockets.
Since STM32CubeIDE 1.7.0 and the new version of ethernetif.c, modifying "low_level_output", we have a problem when sending packets of about 400 bytes or more.
In that case, the client will not receive all data.
The old version called HAL_ETH_Transmit_IT, and then waited for the semaphore from HAL_ETH_TxCpltCallback().
The new version calls HAL_ETH_Transmit_IT, and returns immediatly.
The next call will fail, waits for the semaphore, then releases the previous packet, then retries...
It works well for small packets, but fails with bigger ones for unknown reasons...
A modification that work for us, is to move the call to HAL_ETH_ReleaseTxPacket in HAL_ETH_TxCpltCallback.
With this modification, we never fall in HAL_ETH_ERROR_BUSY...
What do you think?
Regards,
Fred.
2024-12-11 04:23 AM
Hello @SURLEAU.Frederic ,
I don't see a particular reason for the newer version of call to fail with bigger packets, but I think that the modification that you did will only maybe impact memory management but not overall functionality.
It would be great if you can send a simple project in which you comment the part that you removed indicating the CubeFirmware version and CubdeIDE version for analysis to make sure there are no potential issues with this modification.
Regards
2024-12-16 06:32 AM