Clear TCP receive register

Dear community,
I have just started working with W5500 and now with the help of the provided library I can create a TCP server and send and receive data, but after receiving data the RX register is not cleared and the previous data with the new ones are combined. This is obvious when the length of the data is different. Of course, I don’t want to close the socket. Is there a function that I can call it to clear the receiving buffer? If so show me how to use it. And the next question is, I want to define the maximum RX buffer size to 2048 bytes, how do I do this? getSn_RXBUF_SIZE retuen me 2 . what is that means?


W5100 datasheet chapter

W5500 datasheet chapter 3.3.

1 Like