1.設置靜態(tài)IP
IP地址:192.168.113.101
賬號:pi
密碼:raspberry
確認端口設置IP维贺、掩碼、路由和DNS
sudo vi /etc/dhcpcd.conf
# Example static IP configuration:
interface eth0
static ip_address=192.168.113.101/24
#static ip6_address=fd51:42f8:caae:d92e::ff/64
static routers=192.168.113.1
static domain_name_servers=8.8.8.8 fd51:42f8:caae:d92e::1
最后執(zhí)行
sudo reboot
2.設置wifi
設置樹莓派的wifi連接
sudo vi /etc/wpa_supplicant/wpa_supplicant.conf
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
network={
ssid="test"
psk="123456"
}
最后執(zhí)行
sudo reboot