Quantcast
Channel: Raspberry Pi Forums
Viewing all articles
Browse latest Browse all 3552

Networking and servers • Setting up Wi-Fi on OS Lite Bookworm

$
0
0
Using Buster OS version I was able to configure Wi-Fi connection from Python code:
- Select Wi-Fi network from the list returned by the command 'sudo iwlist wlan0 scan'
- Update the file /etc/wpa_supplicant/wpa_supplicant.conf with selected SSID and encrypted password.
- Run two commands:

Code:

sudo wpa_cli -i wlan0 reconfiguresudo systemctl restart dhcpcd
After these steps a Wi-Fi connection became active/functional.

The same steps don't work on OS Lite Bookworm. I can list connections with 'iwlist' command but I cannot run two last commands:

Code:

$ sudo wpa_cli -i wlan0 reconfigureFAIL$ sudo systemctl restart dhcpcdFailed to restart dhcpcd.service: Unit dhcpcd.service not found.
How can I fix that? Is there a better way to configure Wi-Fi connection programmatically from Python code?

Thanks!

Statistics: Posted by peppy.player — Mon Jan 29, 2024 8:03 am



Viewing all articles
Browse latest Browse all 3552

Trending Articles