Hi all,

I just got my Ben NanoNote today, and after flashing the latest firmware onto it wanted to set it up so networking with it is automatic.

Now, I'm using NetworkManager on my PC, and figured it should be possible to set it up with that somehow. And, well, with some work, I figured out how to make it work - using NM's connection sharing - and it's pretty simple once I know how, so figured I should share it.

First off, I had to make the MAC address static, as per the wiki[1].
(Is there a good reason it isn't static by default?)

Then, I changed the network setup of the NanoNote, editing the lan section of /etc/config/network to look like this:

config interface lan
        option ifname   usb0
        option proto    static
        option ipaddr   10.42.43.4
        option netmask  255.255.255.0
        option gateway  10.42.43.1
        option dns      10.42.43.1

This is because NetworkManager's connection sharing hardcodes the network used - it always uses 10.42.43.1 for itself, and gives out addresses with DHCP in the .10 to .100 range (though some sources online says it gives out .10 to .254, up to .100 is used on my system).
I picked .4 for the NanoNote just as a random IP in the non-DHCP range.

Now, reboot the Ben, to make sure the MAC address etc. is set up right.

Then, connect it to your PC via USB. NetworkManager sees it as a new network, and tries to connect to it with DHCP - this will fail after a little while, and is no problem.

(Note: the following paragraph has not been tested exactly by me, but should work, see explanation below that.)

Right-click the network applet and select "Edit Connections...", and go to the Wired tab if it doesn't start there. Click the "Auto usb0" connection that was created automatically when you connected the NanoNote, and click the Edit... button. On the "Wired" tab, make sure the "MAC address" field contains the NanoNote's static MAC address, and on the "IPv4 Settings" tab, change Method to "Shared to other computers". Click "Apply" at the bottom to save.

That should be all that is needed; if it didn't already connect just click the applet icon and select the Auto usb0 connection. The next time you connect the NanoNote it should be connected automatically.

Now, as mentioned above, this isn't the exact setup I have personally, in part because I've been messing around with it a bit to make this work, and in part because I have another profile for the standard network setup on the NanoNote (that doesn't give it Internet).

In my setup, I've left the "Auto usb0" connection alone except to uncheck the "Connect automatically" checkbox, and have instead added a new connection (called "Ben NanoNote (shared)") which is not available to all users (so I don't need admin access to change it), but is otherwise set up as above (with "Connect automatically" checked).

With this setup, all I have to do is plug in my NanoNote, and the networking Just Works(tm), without me having to change any config files on my PC (just had to use the graphical network configuration tool). NetworkManager also takes care of turning things back off when I unplug the NanoNote.

So, mission accomplished - now just to play around with it some more...
I'm liking what I've seen so far. :)


[1] http://en.qi-hardware.com/wiki/Ethernet_over_USB#Static_Mac_Address
(by the way - shouldn't the fw_setenv line here use "mem=32M" like in the defaults, instead of just "32M"? )

--
Regards,
Frode Austvik

_______________________________________________
Qi Hardware Discussion List
Mail to list (members only): [email protected]
Subscribe or Unsubscribe: 
http://lists.en.qi-hardware.com/mailman/listinfo/discussion

Reply via email to