Wifi
piCorePlayer’s wifi objective is to have a wifi setup that:
- will work 99% of the time.
- is tolerant of typical user typos and formatting errors.
- has a headless option, so using a monitor and keyboard is not required.
- uses psk passphrases, so passwords are not stored as plain text.
- has a manual setup option for more advanced users. This means it is theoretical possible that any valid WPA configuration is supported.
Three wifi setup methods
piCorePlayer has 3 wifi setup methods:
- Using the piCorePlayer web GUI.
- Adding
wpa_supplicant.conf
to the boot partition. - Using piCorePlayer setup CLI.
1 - piCorePlayer web GUI - the preferred method
To initially access piCorePlayer’s [Wifi Settings] web page you will need wired ethernet access.
As the majority of Raspberry Pi’s have a wired ethernet option, using Option 1 - Using the piCorePlayer web GUI
is the preferred method—see Setup Wifi.
After inputting your wifi information into the [Wifi Settings] web page and clicking [Save], piCorePlayer will generate a nicely formatted wpa_supplicant.conf
configuration file for you.
Basic format of wpa_supplicant.conf
# Maintained by piCorePlayer
ctrl_interface=/var/run/wpa_supplicant
ctrl_interface_group=staff
country=CC
update_config=1
network={
#enc_ssid="yourssid"
ssid="yourssid"
psk=6554d2e9bbf47ce37dd95fffc7a6d25d9ef54e477dbd04ed1aa7f724b7e6747f
key_mgmt=WPA-PSK
auth_alg=OPEN
}
2 - Adding wpa_supplicant.conf to the boot partition
It was decided rather than rely on the user to provide a 100% correctly formatted wpa_supplicant.conf
configuration file, piCorePlayer would extract some of the settings from the existing wpa_supplicant.conf
configuration file and generate a new, correctly formatted wpa_supplicant.conf
configuration file.
The basic process:
- Look for
wpa_supplicant.conf
configuration file on the boot partition. - If found, extract the ssid and psk.
- Create a new
/usr/local/etc/pcp/wpa_supplicant.conf
configuration file. - Rename original
wpa_supplicant.conf
configuration file on boot partition toused_wpa_supplicant.conf
configuration file.
Danger
used_wpa_supplicant.conf
configuration file is left on the boot partition.
Basic format of wpa_supplicant.conf configuration file
Next, after you boot piCorePlayer your minimal wpa_supplicant.conf
configuration file will be converted to a working wpa_supplicant.conf
configuration file formatted like the example below:
# Maintained by piCorePlayer
ctrl_interface=/var/run/wpa_supplicant
ctrl_interface_group=staff
update_config=1
network={
#enc_ssid="yourssid"
ssid="yourssid"
psk="yourpassword"
key_mgmt=WPA-PSK
auth_alg=OPEN
}
Note there are two issues with this wpa_supplicant.conf
configuration file:
- It still has the password in clear text.
- The country code is missing.
Minimal wpa_supplicant.conf configuration file
You can create a minimal wpa_supplicant.conf
configuration file with just two lines, one line containing your ssid and the other your password. For example:
ssid="yourssid"
psk="yourpassword"
GUI formatted wpa_supplicant.conf configuration file
It is advisable to use the [Wifi Settings] web page to complete the process of creating a wpa_supplicant.conf
configuration file with a passphrase and a country code. The final format looks like this:
# Maintained by piCorePlayer
ctrl_interface=/var/run/wpa_supplicant
ctrl_interface_group=staff
country=AU
update_config=1
network={
#enc_ssid="yourssid"
ssid="yourssid"
psk=bd9abb43d0e2dd30bd92049f926debe09fc87c8eb18f1bdabe8e17453020bfa6
key_mgmt=WPA-PSK
auth_alg=OPEN
}
3 - Using piCorePlayer setup CLI
Requires a keyboard and monitor—see Using setup with keyboard and monitor.
Force piCorePlayer to ignore wpa_supplicant.conf configuration file
Warning
For advanced users.
This wifi setup method is used for complex wifi network setups that:
- have an unusual ssid.
- have an unusual password.
- have multiple networks.
- are corporate networks.
By simply adding # Maintained by user
to the first line of the wpa_supplicant.conf
configuration file (it must be exactly # Maintained by user
including spaces and capitalisation) the wpa_supplicant.conf
configuration file will be copied from the boot partition to /usr/local/etc/pcp/
without piCorePlayer checking for, and correcting, errors.
This method requires the user to create the wpa_supplicant.conf
configuration file 100% correctly otherwise wifi will not connect to the network.
The piCorePlayer GUI will not work with your custom wpa_supplicant.conf
configuration file. piCorePlayer setup tools will completely ignore your custom wpa_supplicant.conf
configuration file.
See Setup Wifi without ethernet - Maintained by user,
Wifi AP
We have decided not to activate a Wifi Access Point (WAP) by default.
More information
- Setup Wifi
- Setup Wifi without ethernet
- Wifi does not work
- Example wpa_supplicant configuration file
- WPA Supplicant
- The Short List - Superstar USB WiFi Adapters for Linux
- Utility for compiling out of tree kernel modules for pCP Kernels