SparkFun Inventor's Kit for Edison Experiment Guide
Appendix C: Using a USB Network
If you are trying to update the Edison's firmware via the Phone Flash Tool Lite program or want to upload code from the XDK without using WiFi, you can enable USB Ethernet networking. For Windows, this relies on the RNDIS driver. OS X needs to use HoRNDIS, and Linux users will need to use USB CDC.
For all operating systems, start by connecting a USB cable from the OTG port of the Edison Base Block to an available USB port on your computer.
Windows
Go to Start → Control Panel → Network and Internet → Network and Sharing Center → Change Adapter Settings
Right-click on the Local Area Connection that says Intel Edison USB RNDIS Device and select Properties. This will bring up a new window.
Select Internet Protocol Version 4 (TCP/IPv4) and click Properties. This will, once again, bring up a new window.
Select Use the following IP address: and enter 192.168.2.2 for the IP Address. Click anywhere in the Subnet mask fields and it should auto-populate. Click OK on this window and OK on the Local Area Connection window.
Your computer and Edison should now be networked together over USB. To check this, go to Start → Accessories → Command Prompt. Enter ping 192.168.2.15
and you should see several replies from the Edison (192.168.2.15).
OS X
Modern versions of OS X do not come with USB networking drivers. As a result, we will need to install a custom driver. Download the latest release (in .pkg form) for HoRNDIS:
Open the .pkg file and follow the instructions to install the driver. Restart your Mac just to be sure. Once it has booted back up, open up System Preferences and go to Network, and you should see the Edison listed. Change Configure IPv4 to Manually, set IP Address to 192.168.2.2, and Subnet Mask to 255.255.255.0.
Click Apply and you should be able to connect to the Edison over the USB network. Open a console and enter the command ping 192.168.2.15
. You should see some ping replies. Press 'Ctrl+C' to stop pinging.
OS X also come packaged with an SSH client. In a console, enter:
ssh root@192.168.2.15
Type yes
if prompted to accept the RSA key, and enter your Edison's root password.
Linux
Many modern distributions contain USB network drivers by default. With a USB cable connected between your computer and the OTG port on the Base Block, open up a console and enter the command:
ifconfig
You should see an entry labeled usb0, which refers to a USB network. That should be the Edison, assuming you have no other USB Ethernet devices plugged in.
Enter the commands:
sudo ip address add 192.168.2.15/24 dev usb0
sudo ip link set dev usb0 up
If your system does not support the sudo
command, use su
to become root before entering the commands (without sudo
).
You can check to make sure that the IP address was set with ifconfig
. You should see an IP address assigned to usb0.
To test that you have a connection to the Edison, you can ping it:
ping 192.168.2.15
That should give you a few replies, showing that the Edison is indeed at 192.168.2.15. Press 'Ctrl+C' to stop pinging.
Many versions of Linux also come packaged with an SSH client. If so, you won't need any special programs to connect to the Edison over the USB network. Just enter:
ssh root@192.168.2.15
Type yes
if prompted to accept the RSA key, and enter your Edison's root password.