This function disconnects the socket.

Syntax

char CloseSc(
  SOCKET sock
);

Parameters

sock
[in] Socket descriptor

Return value

The following values will be returned.
ValueDescription
SOCK_ERR_NO_ERROR Succeeded
M2M_ERR_SLEEP_FAIL Initialize with SysWLANInit function.
Other than the above Failed

Remarks

This function disconnects the socket.
It can be used with both TCP and UDP sockets.

Requirements

Header file:
lib.h
Library file:
libSTARTUPOPH5000.a

Sample

Last updated: 2020/11/26