树莓派 设置wifi设置

设置固定 wifi:

cd /etc/wpa_supplicant

vim wpa_supplicant.conf
内容如下:
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
country=CN

network={
        ssid="video"
        psk="KMff-33d-dd"
        key_mgmt=WPA-PSK
}

 

设置固定IP:

vim /etc/dhcpcd.conf


无线:

SSID video
inform 192.168.5.11
static routers=192.168.5.1
static domain_name_servers=222.172.200.68


SSID YNZK
    inform 192.168.3.11

    interface wlan0
    inform 192.168.3.11
    static routers=192.168.3.1
    static domain_name_servers=61.166.150.123


或:
interface wlan0
    static ip_address=192.168.2.21/24
    static routers=192.168.2.1
    static domain_name_servers=114.114.114.114



有线:
interface eth0
    static ip_address=192.168.2.20/24
    static routers=192.168.2.1
    static domain_name_servers=114.114.114.114

 

你可能感兴趣的:(技术文档,树莓派)