PyBoard D Wifi 控制

PyBoard D Wifi 控制

TONYLABS 15 Apr, 2019


首先打开 文件,配置 Wifi 通道的区域:

import pyb'CN')   # 2-char code, eg: US, GB, DE, NL, FR, AU, CA Wifi Station import network wl = network.WLAN() # bring up the interface wl.config('mac') # get the MAC address wl.config(antenna=0)    # select antenna, 0=chip, 1=external wl.scan()               # scan for access points, returning a list wl.connect('ssid', 'password')  # connect to an access point wl.isconnected()        # check if connected to an access point wl.disconnect()         # disconnect from an access point


输入您的电子邮箱即可在第一时间获得 TONYLABS 资讯