Other Parts Discussed in Thread: CC3200
May i know is their any way to know number of sockets open at given point of time using CC3200 SDK.
This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Hi,
There no API for such purpose at CC3200 host driver. You can count number of socket by yourself when you using (sl_Open and sl_Close API) but your will not be able determine whether socket was closed by opposite side.
Why you need to count number of opened sockets?
Jan
Hi,
CC3200 supports up to 8 sockets. Two of them can be secured (SSL/TLS).
If you need more sockets, you should cosier to use CC3220 (16/6) or CC3235/CC3230 device (16/16). CC3220/CC3235 supports also linger option for closing socket, which allow to better management of sockets.
update: But if you want to stay with CC3200 device, reasonable way how to overcome issue with number of secured sockets is to wait 10sec before opening new secured socket after calling sl_Close() API. This will be enough time for closing socket by timeout even secured socket was not closed by opposite side.
Jan
Hi Linga,
I agree with Jan's answer, but I also wanted to add that the SL_ESECTOOMANYSSLOPENED error is not fatal. You can check for this error when you create a new socket, and then wait for a few seconds before trying again.
Best regards,
Sarah