WINC1500 HTTP Server - Is there a way to reduce the number of accepted sockets?

Go To Last Post
6 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I have a WINC1500 set up as a HTTP server. When I launch a browser such as Google Chrome, it immediately sends 4 TCP [SYN] packets and WINC immediately [SYN, ACK] on all four. As a consequence, multiple HTTP commands can come to me one after another. I am handling this by creating one set of TX and RX buffers for each accepted socket, and this approach takes up quite amount of memory. I'd like to know if it is possible to tell WINC to only accept one request at a time so that I only need to allocate one set of buffer. 

 

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hello

Is it not up to you accepting incoming connections.
If you don't call accept() you will not get a new connection.

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

accept() is a deprecated function. The comment says:

/** @} */
/** @defgroup AcceptFn accept
 *    @ingroup SocketAPI
 *	The function has no current implementation. An empty deceleration is used to prevent errors when legacy application code is used. 
 *     For recent application use, the accept function can be saferIt has no effect and could be safely removed from any application using it.
 */
 /**@{*/
/*!

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

acpie360 wrote:
The comment says:

 deceleration 

 

laugh

Top Tips:

  1. How to properly post source code - see: https://www.avrfreaks.net/comment... - also how to properly include images/pictures
  2. "Garbage" characters on a serial terminal are (almost?) invariably due to wrong baud rate - see: https://learn.sparkfun.com/tutorials/serial-communication
  3. Wrong baud rate is usually due to not running at the speed you thought; check by blinking a LED to see if you get the speed you expected
  4. Difference between a crystal, and a crystal oscillatorhttps://www.avrfreaks.net/comment...
  5. When your question is resolved, mark the solution: https://www.avrfreaks.net/comment...
  6. Beginner's "Getting Started" tips: https://www.avrfreaks.net/comment...
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi

 

Was you able to reduce the number of available sockets of your WINC1500 module? I need to make sure that only one session could be established.

 

BR Raphael

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

We are having the same problem on our HTTP server firmware that uses the WINC1500.  WE have been in contact with the factory, but so far there is no solution.  I would be interested to see if anyone find something.

 

We switched from and old Microchip WiFi module to the WINC. With the old module the "accept" function worked, and the HTTP server only used up 2 sockets since we rejected any requests after the first two sockets.  As the other poster says, "accept" on the WINC is an empty function, the HTTP server keep opening sockets as the client browser request them.  The result is the HTTP uses up all the available sockets.   

John Malaugh