sandeepn wrote: ↑Wed Aug 30, 2017 3:16 am
One assumption is that one knows which WiFi to connect and has the credentials. For example, you are visiting your friend's place and friend provides you the WiFi credentials. You can easily provision your phone or laptop with it but NOT raspberry pi. For PI, you need the keyboard/monitor to provision it...
Nope. Not correct. Your knowledge is quite out of date.
You can edit a file called wpa_supplicant.conf, and Raspbian even has the provision to put that file into the easily accessible FAT32 formatted boot partition. When Raspbian finds that file it will move it to the correct location and use it to connect. You can also enable SSH by adding an empty file called "ssh" or "ssh.txt" to the boot partition.
With both of those files in place, you can boot a completely headless Pi and have it automatically connect to a wireless network, then SSH into it. No keyboard or mouse needed at all. If you want to connect at other locations, you could keep a copy of the wpa_supplicant.conf file on your smartphone that you could edit and then copy to the Pi's SD card.
I'm not saying it's the easiest solution possible, but you can operate a completely headless Pi right now (and have been able to for awhile).
A basic wpa_supplicant.conf file would look like this:
Code: Select all
network={
ssid="your-network-service-set-identifier"
psk="your-network-WPA/WPA2-security-passphrase"
}
EDIT: It seems that Raspbian Stretch does not like the basic wpa_supplicant.conf file, so for the new Raspbian Stretch use the full file:
Code: Select all
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
country=US
network={
ssid="your-network-service-set-identifier"
psk="your-network-WPA/WPA2-security-passphrase"
key_mgmt=WPA-PSK
}
My mind is like a browser. 27 tabs are open, 9 aren't responding,
lots of pop-ups...and where is that annoying music coming from?