I like to use my Black like the Arduino.

I like to use my Black like the Arduino. So to have network access on the Black using just the USB wire, I learnt the following trick

On the Black do:
/sbin/route add default gw 192.168.7.1
echo “nameserver 8.8.8.8” >> /etc/resolv.conf

On the Linux host from which you want to route:
sudo iptables -A POSTROUTING -t nat -j MASQUERADE
sudo echo 1 | sudo tee /proc/sys/net/ipv4/ip_forward > /dev/null

Now on the BBB:
ping http://google.com