cancel
Showing results for 
Search instead for 
Did you mean: 

Wi-Fi Combo

Anonymous
Not applicable

WICED SDK v2.4.0 (I also looked in v2.4.1 and its still there) in file: WICED\Wiced-SDK-2.4.0\Wiced-SDK\Wiced\Network\NetX_Duo\wiced\tcpip.c, function wiced_tcp_listen(), line 303.  Interface is hard-coded to WICED_STA_INTERFACE.

The setup: bring up both the STA and AP network.  Start an STA http server.  Now attempt to start an AP http server.  This will fail with a WICED_ERROR returned from wiced_tcp_listen() because the STA socket has already been initialised, and due to the hard-coded interface, that's the only socket checked by wiced_tcp_listen().  I haven't tried it, but I suspect that you could also erroneously create two or more AP http servers because of this bug.

Effect: Using NetX Duo, I can start both an AP and STA http server only if I start the AP server first, the other way around the AP http server does not start.

Note: This doesn't occur using NetX

0 Likes
3 Replies
Anonymous
Not applicable

Thanks for reporting this. We'll fix it up in the next release.

Meanwhile, the following link is related and may be useful.

TCP Server with multiple sockets on AP interface

0 Likes
Anonymous
Not applicable

To fix the bug you should replace the two instances of

IP_HANDLE(WICED_STA_INTERFACE).

with

socket->socket.nx_tcp_socket_ip_ptr->

This will use the socket's internal pointer to its parent IP context rather than statically pointing to the STA IP context.

Anonymous
Not applicable

Awesome, thank you for the fix