Connect to Raspberry Pi remotely without screen

1. First, enable SSH.
From the official Raspbian system log, the system mirrors after November 25, 2016 do not enable SSH by default. You need to pull out the SD card first and create a new SSH blank file (without suffix) in the root directory (boot), no need to edit the content. At first I wanted to operate directly on the Raspberry Pi, but found that I could not create new files without boot permission, so I had to pull out the SD card.
2. Add the file wpa_supplicant.conf containing Wi-Fi information and
create a new wpa_supplicant.conf file in the SD card root directory (boot), edit the content, you can use multiple networks{} to configure multiple wifi:

ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
country=GB   #设置国家
network={
    
    
    ssid="将我换成第一个WIFI的名字,不删除引号,不能有中文"
    psk="将我换成WIFI的密码,不删除引号"
    key_mgmt=WPA-PSK
    # 无论使用WPA-PSK/WPA2-PSK,这里都填WPA-PSK
    priority=将我换成数字,数字越大代表优先级越高
}
network={
    
    
    ssid="将我换成第二个WIFI的名字,不删除引号,不能有中文"
    psk="将我换成WIFI的密码,不删除引号"
    key_mgmt=WPA-PSK
    # 无论使用WPA-PSK/WPA2-PSK,这里都填WPA-PSK
    priority=将我换成数字,数字越大代表优先级越高
}

Note that if the wifi has no password, then key_mgmt=NONE

network={
    
    
    ssid="将我换成第一个WIFI的名字,不删除引号,不能有中文"
    key_mgmt=NONE
    # 无论使用WPA-PSK/WPA2-PSK,这里都填WPA-PSK
    priority=将我换成数字,数字越大代表优先级越高
}

Generally, a network without a password will be linked by many people, such as a campus network. At this time, it may be difficult to scan with Advanced IP Scanner. After all, there may be thousands of people linking. At this time, you can use the mobile phone hotspot to directly connect. Get the IP.
Insert picture description here

Insert the TF card into the Raspberry Pi, turn on the power switch, the green indicator on the Raspberry Pi will flash, indicating that the system is normal.
Then you can connect to the Raspberry Pi remotely. I use Putty software and VNC Viewer. For specific operations, you can check my blog and connect the Raspberry Pi to the laptop without a screen and wired connection .

Guess you like

Origin blog.csdn.net/qq_50866711/article/details/113998381