Difference between revisions of "Pi"
(further notes about rebooting) |
(→Giving the Pi the Internet: note) |
||
(3 intermediate revisions by one other user not shown) | |||
Line 13: | Line 13: | ||
Note that for these directions, you ''must not'' be using the Pi in ad-hoc mode (see [[Connecting to the Pi#General notes|explanation here]]. Use Ethernet instead. | Note that for these directions, you ''must not'' be using the Pi in ad-hoc mode (see [[Connecting to the Pi#General notes|explanation here]]. Use Ethernet instead. | ||
− | Also, note that <code>/etc/network/interfaces</code> must be ''EMPTY'' | + | Also, note that <code>/etc/network/interfaces</code> must be ''EMPTY'' or deleted. |
− | Remember to restart the Pi after you edit /etc/network/interfaces, or changes will not take effect! You can unplug and plug in the Pi, or just run <code>sudo reboot</code>. | + | * Remember to restart the Pi after you edit /etc/network/interfaces, or changes will not take effect! You can unplug and plug in the Pi, or just run <code>sudo reboot</code>. |
+ | * Remember that NEITHER the ad-hoc NOR the locomotionlab wifi networks will work at all after you wipe out the /etc/network/interfaces file! The physical Ethernet cable will definitely work though. Or just plug in a monitor and keyboard. | ||
set up a hotspot on your phone and then run these commands: | set up a hotspot on your phone and then run these commands: | ||
Line 21: | Line 22: | ||
sudo ip link set dev wlan0 up | sudo ip link set dev wlan0 up | ||
− | (then wait 30 seconds or however long it takes before the next command stops giving an error message) | + | (then wait 30 seconds or however long it takes before the next command stops giving an error message. the "set up" command may print no output even if it worked) |
sudo iw dev wlan0 connect -w 'NAME OF WIFI NETWORK' | sudo iw dev wlan0 connect -w 'NAME OF WIFI NETWORK' | ||
− | (then wait about 30 seconds or so) | + | (then wait about 30 seconds or so - it's fine if nothing appears) |
sudo dhclient | sudo dhclient | ||
− | (then wait a random number of seconds) | + | (then wait a random number of seconds. this command may take a while) |
sudo dhclient | sudo dhclient | ||
− | (yes, you have to run it again) | + | (yes, sometimes you have to run it again) |
+ | |||
+ | '''Remember!''' When you're done working please put /etc/network/interfaces back to the way it was. | ||
The Internet should come on within a minute or so. | The Internet should come on within a minute or so. |
Latest revision as of 00:32, 1 March 2020
For setting up the Pi, see Setting up the Pi.
For connecting to the Pi, see Connecting to the Pi.
Giving the Pi the Internet
Go to the fifth floor of Upson and stand outside the bike lab, then use the LocomotionLab wifi as detailed in Connecting to the Pi#General notes.
If you don't want to walk:
Note that for these directions, you must not be using the Pi in ad-hoc mode (see explanation here. Use Ethernet instead.
Also, note that /etc/network/interfaces
must be EMPTY or deleted.
- Remember to restart the Pi after you edit /etc/network/interfaces, or changes will not take effect! You can unplug and plug in the Pi, or just run
sudo reboot
. - Remember that NEITHER the ad-hoc NOR the locomotionlab wifi networks will work at all after you wipe out the /etc/network/interfaces file! The physical Ethernet cable will definitely work though. Or just plug in a monitor and keyboard.
set up a hotspot on your phone and then run these commands:
sudo ip link set dev wlan0 up
(then wait 30 seconds or however long it takes before the next command stops giving an error message. the "set up" command may print no output even if it worked)
sudo iw dev wlan0 connect -w 'NAME OF WIFI NETWORK'
(then wait about 30 seconds or so - it's fine if nothing appears)
sudo dhclient
(then wait a random number of seconds. this command may take a while)
sudo dhclient
(yes, sometimes you have to run it again)
Remember! When you're done working please put /etc/network/interfaces back to the way it was.
The Internet should come on within a minute or so.