AnsweredAssumed Answered

General question about LwIP and STM32F4 / STM34F7

Question asked by Alberto Fahrenkrog on Jul 20, 2017

Hi all,


this question might be a bit vague, I'm more interested in how the STM32F4 and F7 series work with LwIP in detail.


The application I'm developing is simple UDP and TCP data transfer. UDP to be used for status and commands, TCP (possibly) for bulk data transfer at around 12 MBit. I've read about how to use and implement the raw API from LwIP, both for UDP and TCP. What I'm wondering is, in both TCP and UDP cases, how many data "copy" actions does LwIP do between the buffer where my data is stored (internal or external RAM) and the Ethernet out buffer. I've seen "memcopy" used a few times, so I'm wondering if LwIp uses DMA transfers at all.


And pbuf's, usually (in applications) they are allocated dynamically, is it possible to have a set of static pbufs pointing at the data? Or do I need to copy the data to a pbuf so that it can contain the necessary TCP/UDP/IP headers?


Last, about the checksum, does the MAC generate the checksum for TCP and UDP while copying out the data to the PHY (so I understood from the datasheet) and does LwIP take advantage of that? I'm planning to start development soon on the STM32F769 discovery board, I thought I'd start gettin all ready.


Any information would be appreciated.