cancel
Showing results for 
Search instead for 
Did you mean: 

Wi-Fi Combo

MaGr_2160016
New Contributor II

[WICED-SDK-2.2.1]

The NX_TIMEOUT() macro produces an overflow when used with WICED_NEVER_TIMEOUT.

This happens for instance when wiced_tcp_receive() is invoked with WICED_NEVER_TIMEOUT with unexpected results.

-Marco G.

0 Likes
4 Replies
Anonymous
Not applicable
Good find marcoeg,

I believe the following definition of NX_TIMEOUT() should solve the problem:

#define NX_TIMEOUT(timeout_ms)   ((timeout_ms != WICED_NEVER_TIMEOUT) ? (timeout_ms * SYSTICK_FREQUENCY / 1000) : WICED_NEVER_TIMEOUT )
0 Likes
MaGr_2160016
New Contributor II
Since the SDK comes without source code for NetX, how can I insure that the correct definition is used? I noticed that it is part of a Wiced layer, but just deleting the library in the build/[app]/Libraries directory, it doesnt seem enough.

Can anyone suggest a workaround?

Thanks,

-Marco G.
0 Likes
Anonymous
Not applicable
The NX_TIMEOUT() is only used in the NetX/NetX_Duo tcpip.c file which is built into the Wiced_NetX_Interface library.

Running "make clean" followed by a build of your application should ensure that the new definition of NX_TIMEOUT() is used.

What, specifically, is the error you are seeing?
0 Likes
Anonymous
Not applicable

Discussion is being locked. If you have any follow-up, please start a new discussion.

0 Likes