Wlan0 not detected on pi0 with build 0.15


#1

What is the problem?

Wifi is not working, wlan0 is not available on pi0. It says device not detected.

What did you already try to solve it?

Tried adding it in interfaces file, and rebooting. Ifconfig still shows only l0 and no wlan0

Additional information about your setup (OctoPrint version, OctoPi version, printer, firmware, octoprint.log, serial.log or output on terminal tab, ...)


#2

Assuming that you loaded this from the OctoPi image rather than some other means.

Your /boot/octopi-wpa-supplicant.txt file needs the correct country code (usually at the bottom) and presumably...

country=US

It wants a reboot after updating that. You might need to bring the microSD over to your workstation to edit that. But it sounds like you have a local monitor on the Raspi.


Although I do miss the /etc/network/interfaces way of configuring things, that's under a different service. Raspi Stretch now uses wpa_supplicant as the service so I'm pretty sure that it ignores interfaces.


cat /sys/firmware/devicetree/base/model
...will tell you/us which Raspi you have.

cat /etc/os-release|grep PRETTY
...will tell us which version.


#3

Thank you for your reply.

I did update my country code to LB (Lebanon) and using the 0.15 image on the octoprint website.

I added the wlan0 in interfaces just to see if I can activate the connection.

auto wlan0
allow.hotplug wlan0
iface wlan0 inet dhcp
wpa.conf /etc/wpa_supplicant/wpa_supplicant.conf

I have raspberry pi Zero Rev 1.3
PRETTY_NAME="Raspbian GNU/Linux 9 (stretch)

Thank you


#4

Is it definitely called wlan0 ?

The newer kernels are tending to use "predictable interface names" and this
caught me out recently (admittedly not on a Pi, so this might be irrelevant)

ip link show

Is likely to list the actual name being used.


#5

Here is a good read regarding Raspbian Stretch and some work-arounds. I would suggest reading the entire thread.

Short version:

ctrl_interface=/var/run/wpa_supplicant

...appears to be missing from the Raspbian Stretch distro's wpa_supplicant.conf. (Search for "Okay. Solved it." in that thread.)

If you can fix the native wpa_supplicant service's configuration, then you won't need to deal with /etc/network/interfaces. And if you did want that to work, then you'd need to enable the service that uses it.


#6

I tried every solution on that page and I still get the following (attached) if I do a systemctl status networking.service


#7

Can you sudo cat /etc/wpa_supplicant/wpa_supplicant.conf and show us what's there?


#8

The Pi0 doesn't have WiFi. So unless you actually mean a Pi0W, there's nothing to detect and you need to get yourself a USB dongle. Or switch to a Pi3, since contrary to the Pi0W (and Pi0 due to all the connectivity hassle and low power) that is actually recommended.


#9

Oh... facepalm. I have so many Pi0W's that I didn't even think of that.