Permalink
Name already in use
A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
WPILibPi/stage5/02-net-tweaks/01-run.sh
Go to fileThis commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This helps avoid SSID conflicts when configuring multiple devices. The SSID can be discovered in two ways: - It's written as a text file to the SD card /boot partition. This is a FAT partition that can be read on Windows systems. - It's spoken (via text to speech) to the Pi audio jack.
executable file
33 lines (24 sloc)
934 Bytes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash -e | |
| # enable wireless | |
| rm -f "${ROOTFS_DIR}/etc/modprobe.d/raspi-blacklist.conf" | |
| # Enable wifi on 5GHz models | |
| mkdir -p "${ROOTFS_DIR}/var/lib/systemd/rfkill/" | |
| echo 0 > "${ROOTFS_DIR}/var/lib/systemd/rfkill/platform-3f300000.mmcnr:wlan" | |
| echo 0 > "${ROOTFS_DIR}/var/lib/systemd/rfkill/platform-fe300000.mmcnr:wlan" | |
| # Install hostapd.conf to .orig so it's not activated on first boot | |
| install -m 644 files/hostapd.conf "${ROOTFS_DIR}/etc/hostapd/hostapd.conf.orig" | |
| install -m 644 files/dnsmasq.conf "${ROOTFS_DIR}/etc/dnsmasq.d/wpilib.conf" | |
| cat <<END >> "${ROOTFS_DIR}/etc/wpa_supplicant/wpa_supplicant.conf" | |
| ###### BELOW THIS LINE EDITED BY RPICONFIGSERVER ###### | |
| network={ | |
| ssid="WPILibPi" | |
| psk="WPILib2021!" | |
| } | |
| END | |
| cat <<END >> "${ROOTFS_DIR}/etc/dhcpcd.conf" | |
| ###### BELOW THIS LINE EDITED BY RPICONFIGSERVER ###### | |
| interface wlan0 | |
| static ip_address=10.0.0.2/24 | |
| static routers=0.0.0.0 | |
| nohook wpa_supplicant | |
| END |