0

I am trying to connect my Raspberry Pi CM4 to Wifi automatically after start-up. I am using Buildroot based Linux distribution. I have worked with Yocto before and it provides systemd-networkd and wpa_supplicant feature to connect to wifi on boot. I am lloking something similar in Buildroot but couldn't find any notes online.

So far, I think I have enabled the necessary config/driver using make menuconfig :

wpa_supplicant

firmware

but now, how can I set-up wpa_supplicant.conf? Any link to notes or suggestion would be helpful.

Can anyone please let me know how to proceed further with it?

Your help will be much appreciated.

Thanks in advance.

P.S: I am using Buildroot 2022.02 release and also using systemd feature and let me know if any info is missing here.

Preeti
  • 535
  • 1
  • 6
  • 30

1 Answers1

1

I tried to do the same thing but ultimately could not get wpa_supplicant to cooperate with connman. Connman kept throwing "Error /net/connman/technology/wifi: Not supported" and none of the fixes I found online worked.

Instead I switched to using iwd, the modern replacement for wpa_supplicant. I only needed to add the file /var/lib/iwd/<MyWifiSSID>.psk with the contents:

[Security]
Passphrase=<MyWifiPassword>

Then everything worked! By default it will try to autoconnect at boot. If it disconnects, it reconnects whenever possible. It is basically everything I need, and therefore I have given up trying to get wpa_supplicant to cooperate.

ps. I have also tested iwd with connman on top, which also seems to work quite nice.

Mercotui
  • 11
  • 2