![Mediatek Labs LinkIt Connect 7681 Developer'S Manual Download Page 46](http://html1.mh-extra.com/html/mediatek-labs/linkit-connect-7681/linkit-connect-7681_developers-manual_1760804046.webp)
MediaTek LinkIt™ Connect 7681 Developer's Guide
© 2015, 2016 MediaTek Inc.
Page 41 of 65
This document contains information that is proprietary to MediaTek Inc.
Unauthorized reproduction or disclosure of this information in whole or in part is strictly prohibited.
5.
Using the APIs
This section provides information on how to use the MT7681 APIs. For details of the API please
refer to the
MediaTek LinkIt Connect 7681 API Reference
.
The topics covered in this section include:
•
connecting MT7681 to an AP.
•
configuring MT7681 as an AP.
•
using uIP for TCP/IP operations, including:
o
creating a TCP client that connects to a remote TCP server.
o
creating a TCP server and allowing others to connect to it.
o
increasing the available TCP/UDP connections.
5.1.
Connecting MT7681 to an AP
This section describes how to code MT7681 so that it will always connect to the specified AP. This
is useful when you don’t want to use Smart Connection but have a specific AP you want to
connect to. The steps to achieve this are as follows:
1)
disable default Smart Connection
Open
mak\MT7681\flags_stak.mk
(this is the make file for Station mode), scroll to the
bottom and add following lines before
#END-OF-FILE#
.
...
FUN= -DCFG_SUPPORT_MTK_SMNT=0 # add this line to enable MTK
SMNT
#END-OF-FILE#
2)
add the specific AP setting to
IoT_Cust_SM_Smnt()
.