2022年9月19日 星期一

樹梅派3的無線網路用DHCP自動取得IP

安裝Raspberry Pi OS (32-bit, Debian 11 Bulleye改) 的raspberry pi 3,因為本身硬體就已經帶有無線網路Wifi硬體,故只要裝好以後使用圖形介面找到Wifi的SSID並登入,那麼系統本身就會把Wifi密碼給記住。要設定無線Wifi網路用的是DHCP來抓IP,只要設定 /etc/network/interfaces 這個檔案如下:

# interfaces(5) file used by ifup(8) and ifdown(8)
# Include files from /etc/network/interfaces.d:
source /etc/network/interfaces.d/*

auto wlan0
allow-hotplug wlan0
iface wlan0 inet dhcp

這樣wlan0連到Wifi以後就會用DHCP去自動抓IP位址了,再用指令重新啟動網路介面:
  • service networking restart

_EOF_

Manhattan on a floating island in the sky, waterfalls falling down, low poly art, isometric art, 3d render, ray tracing, high detail, artstation, concept art, behance, smooth, sharp focus, ethereal lighting.

Steps: 20, Sampler: DPM++ 2M Karras, CFG scale: 7, Seed: 2444695684, Size: 512x256, Model hash: fc2511737a, Model: chilloutmix_NiPrunedFp32Fix, Version: v1.6.0-2-g4afaaf8a

Time taken: 5.7 sec.

沒有留言:

張貼留言