WICED SDK HTTP Server Locks Up with Multiple Requests.

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

Hi All,

Just wondering if any one has seen this issue before.

I am running the snip/ping_webserver example provided by the WICED SDK, 2.4.0.

I am able to receive the web pages and AJAX responses on my browser from the target.

The problem occurs when I "refresh" the ping web page or open new browser tabs to connect to target, the http server would then stop responding.

I added some debug statements in http_server.c, http_server_thread_main(),

one after wiced_tcp_accept() and another after wiced_tcp_receive().

When multiple requests are made (refreshes on browser, new tabs, etc), the receive() never returned.

I suspected it's due to "WICED_WAIT_FOREVER" configuration for the time out parameter in wiced_tcp_receive().

So I tried both 1 and 5 second(s) instead.

The http server no longer locks up, but performs poorly with multiple requests. (image is not responded, or even the entire page is not served.)

Information about my environment:

Version of the WICED SDK: 2.4.0

Target: SN8200x from MURATA

Software Stack: ThreadX, NetX_Duo

Thank you so much for reading through my issue.

Regards,

Peter

0 Likes
5 Replies
Anonymous
Not applicable

What browser are you using?  In my experience, the snips that use Javascript/AJAX tend to work better in Internet Explorer as opposed to Chrome or Firefox.

0 Likes
Anonymous
Not applicable

Thanks for your reply c g.

I think IE does work better after some trials. However, the issue is still there when I have say 3 tabs open and refresh one of the tab, then the http server just stops responding to any requests, tho the accept() are still looping with timeouts.

I think it has more to do with "wiced_tcp_receive()" hang up issues that have been reported on NetX_Duo....

Not sure using LwIP would help, but at least we have the source code.

Also, I find it a abit weird that listen and accept uses same socket...

0 Likes

Can you please create a new discussion if there is a new question?

0 Likes
Anonymous
Not applicable

Hi gangi,

Certainly.

However, the original question "HTTP server locks up with multiple requests" still persists.

Just wondering if you have experienced this when running the "snip/ping_webserver example".

Having multiple browser tabs opened and connected to the HTTP server on the target.

(at the same time, refreshing some of the tabs) eventually will cause the HTTP / TCPIP to lock up.

I tried doubling the "NETWORKING_WORKER_THREAD_QUEUE_SIZE" from 15 to 30 today which seemed to have helped the performance and no lock up have occurred so far. But not sure if this is the ultimate solution.

Thank you!

0 Likes

Hello

I am using the ISM4319_TESTBOARD as a server and I have the same problem, in my case, my server is locked up after a client device connects and disconnects several times from the access point. I think the problem is that the server does not detect the disconnection of the client and each new disconnection and reconnection to the access point, it takes it as a device more connected to the network.

Could you help me solve this problem?

0 Likes