---
title: "WIZ550io sends lots of meaningless data from tcp"
url: "https://maker.wiznet.io/forum/12636"
markdown_url: "https://maker.wiznet.io/forum/12636/md"
type: "Forum topic"
category: "Ethernet Chips"
author: "epppp"
created: "2017-12-28T13:49:36+09:00"
last_activity: "2018-01-01T14:04:36+09:00"
language: "en"
views: 685
replies: 1
source: "WIZnet Makers forum (https://maker.wiznet.io/forum/)"
---

# WIZ550io sends lots of meaningless data from tcp

## Question

Asked by epppp on 2017-12-28 in Ethernet Chips.

Hi,
I use wiz550io module in my board. My firmware waits a tcp connection as server and a PC terminal program connects my socket as a client. After connection done; from PC terminal program I send some datas ( 20-30 byte data) to my board and my boards firmware answers ( 20-30 byte) this command. If I send datas quickly(without waiting) from PC terminal program to my board after 3-5 package I see a lot of datas in my PC terminal program as answer. I recognize that this datas are old packages from my communication. Wiz550io sends theese datas until socket communication closed or wiz550iO is resetted. My initialize code is below. I get this code from application notes. I guess there is something about wiz550io buffer, maybe should I reset some buffers in side of wixnet module.

```
_**wizchip_Init();**_
```

**
*** /* Chip selection call back */**#if *WIZCHIP_IO_MODE* == *WIZCHIP_IO_MODE_SPI_VDM
*** reg_wizchip_cs_cbfunc(wizchip_select, wizchip_deselect);**#elif *WIZCHIP_IO_MODE* == *WIZCHIP_IO_MODE_SPI_FDM
*** reg_wizchip_cs_cbfunc(wizchip_select, wizchip_select); // CS must be tried with LOW.**#else** #if (*WIZCHIP_IO_MODE* & *WIZCHIP_IO_MODE_SIP*) != *WIZCHIP_IO_MODE_SIP
*** #error “Unknown *WIZCHIP_IO_MODE*”** #else** reg_wizchip_cs_cbfunc(wizchip_select, wizchip_deselect);** #endif**#endif** /* SPI Read & Write callback function */** reg_wizchip_spi_cbfunc(wizchip_read, wizchip_write);** ** ** /* WIZCHIP SOCKET Buffer initialize */** if(ctlwizchip(CW_INIT_WIZCHIP,(void*)memsize) == -1)** {** printf(“WIZCHIP Initialized fail.\r\n”);** while(1);** }***

## Replies

### Reply 1 by Eugeny, 2018-01-01

There should be something about improper programming of the W5500.

epppp:

> My firmware waits a tcp connection as server and a PC terminal program connects my socket as a client. After connection done; from PC terminal program I send some datas ( 20-30 byte data) to my board

I propose you perform data dumping at the W5500 side to see if it receives data correctly.

epppp:

> my boards firmware answers ( 20-30 byte) this command

Does it answer the same data?

epppp:

> If I send datas quickly(without waiting)

But if “with waiting”? What is the difference?

epppp:

> terminal program to my board after 3-5 package I see a lot of datas in my PC terminal program as answer.

That must be data sent by W5500, you must check your code at the W5500 side.

epppp:

> I recognize that this datas are old packages from my communication.

Guess - you use incorrect pointer to RX or TX buffers. I recommend you downloading W5100 datasheet and refer to chapter “Functional description” and check if your code complies with the algorithms described.

epppp:

> maybe should I reset some buffers in side of wixnet module.

You should share code of the main loop (the best whole code related to W5500), and explain what exactly you expect this code doing.

---

Source: https://maker.wiznet.io/forum/12636
