cancel
Showing results for 
Search instead for 
Did you mean: 

Wi-Fi Combo

MaFa_974161
Contributor

Hello, I'm using CYW954907AEVAL1F.

 

I develop an app that listen and accept incoming TCP connections on WiFi.

 

Sometimes when I create socket I obtain error

 

MaFa_974161_0-1638261282041.png

result = 7

0 Likes
3 Replies
GauravS_31
Moderator
Moderator

Is it the netX error code? The error code 7 indicates NX_PTR_ERROR which is due to Invalid IP or socket pointer.  Is the WLAN interface in STA or AP mode? I presume the WLAN device had been associated first and then you called the wiced_tcp_create_socket ()? The failure could be because of DHCP bring up failure. Did you observe any IP address on the console logs after the association was successful?

0 Likes
MaFa_974161
Contributor

Yes, it is the netX error code.

 

Wiced WLAN is configured as AP.

 

My Wiced application act as a server.

 

I develop an Android APP that open the TCP socket on Wiced and then,

when it detects the socket is closed (on the Wiced side) it reopens it as soon as possible.

 

I observe that when the socket is closed (on Wiced side) and the Android APP reopen it, 

the Wiced subsequently reclose socket and this situation generates a open/close/open/close/... "ballet" loop .

 

Using the debugger, after some cycle I observe the situation taken in screeshot.

 

I don't understand why ...

0 Likes
Rakesh_BG
Moderator
Moderator

Hi @MaFa_974161 ,

Can you share the wireshark logs. We can check why wiced closes the TCP socket.

Thanks,

Rakesh BG

0 Likes