Wifi Troubleshooting

My wifi connection keeps dropping and/or I keep getting kicked out of ssh

There is a script that you can add to your root cron that will test your connection and reset it if it is down. Here is an example that runs every two minuntes (odd minutes). You could also do it every 5 minutes or less. Note, this does not have to be for an Edison, you can set this up for a Pi, etc as well.

cd ~/src
git clone https://github.com/TC2013/edison_wifi
cd edison_wifi
chmod 0755 /home/edison/src/edison_wifi/wifi.sh

Next, add the script to your root cron. Note this is a different cron that what your loops runs on, so when you open it don’t expect to see your loop and other items you have added.

  • Log in as root su root
  • Edit your root cron crontab -e
  • Add the following line 1-59/2 * * * * /home/edison/src/edison_wifi/wifi.sh google.com 2>&1 | logger -t wifi-reset

I forget to switch back to home wifi and it runs up my data plan

You can add a line to your cron that will check to see if is avaiable and automatically switch to it if you are on a different network.

  • Log in as root su root
  • Edit your root cron crontab -e
  • Add the following line */2 * * * * ( (wpa_cli status | grep <YOURWIFINAME> > /dev/null && echo already on <YOURWIFINAME>) || (wpa_cli scan > /dev/null && wpa_cli scan_results | egrep <YOURWIFINAME> > /dev/null && udo pa_cli select_network $(wpa_clilist_networks | grep jsqrd | cut -f 1) && echo switched to <YOURWIFINAME> && sleep 15 && (for i in $(wpa_cli list_networks | grep DISABLED | cut -f 1); do wpa_cli enable_network $i > /dev/null; done) && echo and re-enabled other networks) ) 2>&1 | logger -t wifi-select

I am having trouble consistently connecting to my wifi hotspot when I leave the house (iPhone)

When you turn on your hotspot it will only broadcast for 90 seconds and then stop (even if it is flipped on). So, when you leave your house you need to go into the hotspot setting screen (and flip on if needed). Leave this screen open until you see your rig has connected. It may only take a few seconds or a full minute.

I am not able to connect to my wireless access point on my iPhone

Consider changing your iPhone’s name... In most cases iPhone will set the phone’s SSID to something like “James’s iPhone” By default Apple puts a curly apostrophe (’) into the SSID instead of a straight one (‘). Your choices from here are either paste in the curly apostrophe in wpa_supplicant.conf, or change the name on the phone. To change the name on the iPhone:

  • On your iOS device, go to Settings > General > About.
  • Tap the first line, which shows the name of your device.
  • Rename your device, then tap Done.