Documentation/Maemo PC Connectivity Tutorial/Configuration
(categorize) |
(links) |
||
(One intermediate revision not shown) | |||
Line 1: | Line 1: | ||
- | = | + | == Connection Establishment == |
- | + | ||
- | = Connection Establishment = | + | |
On a Maemo device, connections can be easily configured using Maemo PC Connectivity applets. It is possible to configure a Maemo device to use USB, Bluetooth and WLAN connection types. | On a Maemo device, connections can be easily configured using Maemo PC Connectivity applets. It is possible to configure a Maemo device to use USB, Bluetooth and WLAN connection types. | ||
Line 13: | Line 11: | ||
On the host PC side (Linux, Windows and Mac OS X), the Host PC Connectivity product provides some tools to make it easier to configure the chosen connection type between the Maemo device and the host PC. Next the configuration of each supported connection type (USB, Bluetooth and WLAN) between the Maemo device and host PC are described briefly. | On the host PC side (Linux, Windows and Mac OS X), the Host PC Connectivity product provides some tools to make it easier to configure the chosen connection type between the Maemo device and the host PC. Next the configuration of each supported connection type (USB, Bluetooth and WLAN) between the Maemo device and host PC are described briefly. | ||
- | == Configuring USB Network == | + | === Configuring USB Network === |
For Maemo Diablo devices, the USB connection has been configured to '''Mass storage''' mode by default. That is, when connected to a host PC via USB cable, the Maemo device is visible as a memory card for the host PC. | For Maemo Diablo devices, the USB connection has been configured to '''Mass storage''' mode by default. That is, when connected to a host PC via USB cable, the Maemo device is visible as a memory card for the host PC. | ||
Line 39: | Line 37: | ||
|- | |- | ||
| [[Image:dialog-information.png]] | | [[Image:dialog-information.png]] | ||
- | | '''Note:''' Maemo Diablo N800 and N810 devices do not support PC Suite mode. Due to hardware limitations, Maemo Fremantle device N900 does not support USB Host mode. | + | | '''Note:''' Maemo Diablo [[Nokia N800|N800]] and [[Nokia N810|N810]] devices do not support PC Suite mode. Due to hardware limitations, Maemo Fremantle device [[Nokia N900|N900]] does not support USB Host mode. |
|} | |} | ||
- | The description of how to setup a USB connection to Mass storage, PC Suite and Host modes is skipped, since the configuration is simply to select and apply the desired mode on a Maemo device using Maemo PC Connectivity. Next, it is explained how to configure a USB network over TCP/IP between a Maemo device and host PC through Maemo PC Connectivity. Before that, you must install the < | + | The description of how to setup a USB connection to Mass storage, PC Suite and Host modes is skipped, since the configuration is simply to select and apply the desired mode on a Maemo device using Maemo PC Connectivity. Next, it is explained how to configure a USB network over TCP/IP between a Maemo device and host PC through Maemo PC Connectivity. Before that, you must install the <code>maemo-pc-connectivity</code> meta package on the Maemo device and the <code>host-pc-connectivity</code> package on the host PC (Linux, Windows and Mac OS). |
- | === Configuring USB for Maemo devices === | + | ==== Configuring USB for Maemo devices ==== |
To set up a USB network for a Maemo device you need to start PC Connectivity Manager, figure [[#fig:pc_connectivity_mpc_nm_usb_basic|3.1]]. | To set up a USB network for a Maemo device you need to start PC Connectivity Manager, figure [[#fig:pc_connectivity_mpc_nm_usb_basic|3.1]]. | ||
- | |||
Line 56: | Line 53: | ||
[[Image:mpc_maemo_nm_usb_basic.png|Image mpc_maemo_nm_usb_basic]] | [[Image:mpc_maemo_nm_usb_basic.png|Image mpc_maemo_nm_usb_basic]] | ||
|} | |} | ||
- | |||
- | |||
Follow these steps to enable USB Networking: | Follow these steps to enable USB Networking: | ||
- | + | # Disconnect the USB cable from Maemo device | |
- | + | # Run '''Settings - Control Panel - Connectivity - PC Connectivity Manager''' | |
- | + | # Check '''USB''' option | |
- | + | # Press '''Apply''' button | |
- | + | # Connect the USB cable to the host PC. | |
- | + | # Press the '''Advanced''' button and PC Connectivity Manager switches to advanced mode, if you want to change the default values. | |
- | + | # Change network options such as DHCP Server, IP address, Gateway and Netmask. | |
- | + | # Click on the '''Apply''' button. | |
- | + | ||
The USB Networking must have the following default values, figure [[#fig:pc_connectivity_mpc_nm_usb|3.2]]. | The USB Networking must have the following default values, figure [[#fig:pc_connectivity_mpc_nm_usb|3.2]]. | ||
- | |||
- | |||
{| summary="PC Connectivity Manager USB Networking" | {| summary="PC Connectivity Manager USB Networking" | ||
Line 82: | Line 74: | ||
|} | |} | ||
- | + | * '''DHCP Server:''' <code>enabled</code> | |
- | + | * '''IP address:''' <code>192.168.2.15</code> | |
- | * '''DHCP Server:''' < | + | * '''Gateway:''' <code>192.168.2.14</code> |
- | * '''IP address:''' < | + | * '''Netmask:''' <code>255.255.255.0</code> |
- | * '''Gateway:''' < | + | |
- | * '''Netmask:''' < | + | |
Once you have configured your USB Network using PC Connectivity Manager, you can enable or disable it easily by using Connection Switcher from the status bar, figure [[#fig:pc_connectivity_mpc_switcher_usb|3.3]]. | Once you have configured your USB Network using PC Connectivity Manager, you can enable or disable it easily by using Connection Switcher from the status bar, figure [[#fig:pc_connectivity_mpc_switcher_usb|3.3]]. | ||
- | |||
- | |||
{| summary="Connection Switcher dialog" | {| summary="Connection Switcher dialog" | ||
Line 99: | Line 87: | ||
[[Image:mpc_maemo_switcher_usb.png|Image mpc_maemo_switcher_usb]] | [[Image:mpc_maemo_switcher_usb.png|Image mpc_maemo_switcher_usb]] | ||
|} | |} | ||
- | |||
- | |||
If you prefer, you can follow the steps below to configure USB Network manually for a Maemo device (Diablo): | If you prefer, you can follow the steps below to configure USB Network manually for a Maemo device (Diablo): | ||
* Run '''Utilities - X Terminal''' | * Run '''Utilities - X Terminal''' | ||
- | * Type < | + | * Type <code>sudo gainroot</code> |
- | * Type < | + | * Type <code>insmod /mnt/initfs/lib/modules/2.6.21-omap1/g_ether.ko</code> |
- | * Edit the < | + | * Edit the <code>/etc/network/interfaces</code> file to configure the IP address of the <code>usb0</code> interface: |
- | The < | + | The <code>/etc/network/interfaces</code> file should have following entries in it: |
auto usb0 | auto usb0 | ||
Line 116: | Line 102: | ||
netmask 255.255.255.0 | netmask 255.255.255.0 | ||
- | * Type < | + | * Type <code>ifup usb0</code> |
* Plug in the USB cable | * Plug in the USB cable | ||
Line 122: | Line 108: | ||
* Run '''Utilities - X Terminal''' | * Run '''Utilities - X Terminal''' | ||
- | * Type < | + | * Type <code>sudo gainroot</code> |
- | * Type < | + | * Type <code>ifdown usb0</code> |
- | * Type < | + | * Type <code>rmmod g_ether</code> |
- | === Configuring USB for Linux === | + | ==== Configuring USB for Linux ==== |
- | If you install the < | + | If you install the <code>host-pc-connectivity</code> package, your Linux host PC is ready for USB Network. |
Otherwise, you can configure your Linux host PC manually following the steps below: | Otherwise, you can configure your Linux host PC manually following the steps below: | ||
- | On Ubuntu, you need to edit the < | + | On Ubuntu, you need to edit the <code>/etc/udev/rules.d/85-ifupdown.rules</code> file and replace the following line: |
SUBSYSTEM=="net", DRIVERS=="?*", GOTO="net_start" | SUBSYSTEM=="net", DRIVERS=="?*", GOTO="net_start" | ||
Line 140: | Line 126: | ||
SUBSYSTEM=="net", GOTO="net_start" | SUBSYSTEM=="net", GOTO="net_start" | ||
- | If this workaround is not done, the < | + | If this workaround is not done, the <code>usb0</code> interface does not get its IP address back when you unplug and plug back the Maemo device to the host PC. Therefore, you must restart the network manually with the command <code>/etc/init.d/networking restart</code> to get the <code>usb0</code> IP address back. This is a known issue on Ubuntu (see the related bug report [https://bugs.launchpad.net/ubuntu/+source/ifupdown/+bug/130437 here]). |
On Debian, this workaround is not needed. | On Debian, this workaround is not needed. | ||
- | Add the following lines to the network configuration file < | + | Add the following lines to the network configuration file <code>/etc/network/interfaces</code>: |
- | + | <pre> | |
- | + | auto usb0 | |
+ | allow-hotplug usb0 | ||
- | + | mapping hotplug | |
- | + | script grep | |
- | + | map usb0 | |
- | + | iface usb0 inet dhcp | |
- | + | up iptables -t nat -A POSTROUTING -s 192.168.2.15 -j MASQUERADE | |
- | + | up echo 1 > /proc/sys/net/ipv4/ip_forward | |
- | + | down iptables -t nat -D POSTROUTING -s 192.168.2.15 -j MASQUERADE | |
- | + | down echo 0 > /proc/sys/net/ipv4/ip_forward | |
+ | </pre> | ||
- | You can now connect the USB cable. With this configuration, you ensure that the < | + | You can now connect the USB cable. With this configuration, you ensure that the <code>ifup usb0</code> command sets up the IP address correctly on the host PC since it is using DHCP. Also, it allows a Maemo device to access the Internet from the host PC through the <code>usb0</code> interface. |
If you are using VMware: | If you are using VMware: | ||
* Connect USB cable. | * Connect USB cable. | ||
- | * Go to '''VMware - Devices - Netchip RNDIS/Ethernet Gadget''' and click on the '''Connect (Disconnect from host)''' option. If VMware hangs, unplug the USB cable and wait for a short period of time. You get two < | + | * Go to '''VMware - Devices - Netchip RNDIS/Ethernet Gadget''' and click on the '''Connect (Disconnect from host)''' option. If VMware hangs, unplug the USB cable and wait for a short period of time. You get two <code>device in use</code> error messages, one from Native OS and another from VMware (likely because of automatic USB Mass Storage mode). |
* Connect the USB cable. Repeat the previous steps if any problems are encountered. | * Connect the USB cable. Repeat the previous steps if any problems are encountered. | ||
- | Invoke the < | + | Invoke the <code>sudo ifdown usb0</code> and <code>sudo ifup usb0</code> commands. The down/up sequence ensures that the host PC attempts to reconnect the <code>usb0</code> interface. |
- | If this results in a lot of < | + | If this results in a lot of <code>Failed to bring up usb0</code> errors, try again a few times. There can be a delay until the host PC and Maemo device become aware of each other. If it does not succeed but no error message is displayed, you can unplug and plug back the USB cable. |
- | Test the < | + | Test the <code>usb0</code> connection with the following command <code>ping 192.168.2.15</code> |
If you do not get the ping working, try again a few times. This can be an annoying process, especially in VMware where the USB connection may be automatically configured to Mass Storage mode every time you plug the USB cable into the host PC. It may even require restarting VMware in some cases. | If you do not get the ping working, try again a few times. This can be an annoying process, especially in VMware where the USB connection may be automatically configured to Mass Storage mode every time you plug the USB cable into the host PC. It may even require restarting VMware in some cases. | ||
- | === Configuring USB for Windows === | + | ==== Configuring USB for Windows ==== |
- | In order to get USB Networking | + | In order to get USB Networking functioning between a Windows host PC and a Diablo Maemo device, you must replace the original Diablo kernel with a new one that fixes some generic Linux USB Networking issues. |
To replace the Diablo kernel, follow these steps: | To replace the Diablo kernel, follow these steps: | ||
- | * Download the file < | + | * Download the file <code>diablo_kernel_usbnet_patch_windows_v0.4.zip</code> from [http://tablets-dev.nokia.com/maemo-dev-env-downloads.php Maemo Development Environment Downloads] page. |
* Unzip the file. | * Unzip the file. | ||
* Replace the Diablo kernel by reflashing it using the flasher-3.5 application from the same [http://tablets-dev.nokia.com/maemo-dev-env-downloads.php Maemo Development Environment Downloads] page. | * Replace the Diablo kernel by reflashing it using the flasher-3.5 application from the same [http://tablets-dev.nokia.com/maemo-dev-env-downloads.php Maemo Development Environment Downloads] page. | ||
Line 195: | Line 183: | ||
|} | |} | ||
- | After reflashing the kernel to the Maemo Diablo device and installing the < | + | After reflashing the kernel to the Maemo Diablo device and installing the <code>PC-Connectivity.exe</code> package to the host PC, your Windows host PC is ready for USB Network. That is, Windows detects and configures the Maemo device automatically when you plug in the USB cable. Remember to activate USB Network on your Maemo device before plugging the cable into the Windows host PC. |
If you did not enable the '''DHCP''' option for the Maemo device, you need to configure the USB Network address for the host PC through the application available on the Windows Start menu '''Start - Programs - PC-Connectivity - UsbNetworking''', figure [[#fig:pc_connectivity_mpc_win_usb_app|3.4]]. | If you did not enable the '''DHCP''' option for the Maemo device, you need to configure the USB Network address for the host PC through the application available on the Windows Start menu '''Start - Programs - PC-Connectivity - UsbNetworking''', figure [[#fig:pc_connectivity_mpc_win_usb_app|3.4]]. | ||
- | |||
- | |||
{| summary="USB Network address on Windows" | {| summary="USB Network address on Windows" | ||
Line 208: | Line 194: | ||
|} | |} | ||
- | + | If you do not install the <code>PC-Connectivity</code> package, you have to configure the USB network manually on your Windows host PC. For that, you must follow the steps below: | |
- | + | ||
- | If you do not install the < | + | |
* Activate USB Network on the Maemo device. | * Activate USB Network on the Maemo device. | ||
Line 217: | Line 201: | ||
In the '''Found New Hardware Wizard''', figure [[#fig:pc_connectivity_mpc_win_usb_device_found|3.5]], proceed as follows: | In the '''Found New Hardware Wizard''', figure [[#fig:pc_connectivity_mpc_win_usb_device_found|3.5]], proceed as follows: | ||
- | |||
- | |||
{| summary="Windows Found New Hardware Wizard" | {| summary="Windows Found New Hardware Wizard" | ||
Line 226: | Line 208: | ||
[[Image:mpc_win_usb_device_found.png|Image mpc_win_usb_device_found]] | [[Image:mpc_win_usb_device_found.png|Image mpc_win_usb_device_found]] | ||
|} | |} | ||
- | |||
- | |||
* Select the '''No, not this time''' option. Click on the '''Next''' button, figure [[#fig:pc_connectivity_mpc_win_usb_device_found|3.5]]. | * Select the '''No, not this time''' option. Click on the '''Next''' button, figure [[#fig:pc_connectivity_mpc_win_usb_device_found|3.5]]. | ||
Line 234: | Line 214: | ||
* Click on the '''Next''' button, figure [[#fig:pc_connectivity_mpc_win_usb_choose_driver|3.6]]. | * Click on the '''Next''' button, figure [[#fig:pc_connectivity_mpc_win_usb_choose_driver|3.6]]. | ||
* Select the '''Network adapters''' option. Click on the '''next''' button (optional screen). | * Select the '''Network adapters''' option. Click on the '''next''' button (optional screen). | ||
- | * Select the '''Have disk''' option. Then, Click on the '''Browser''' button, select the driver (< | + | * Select the '''Have disk''' option. Then, Click on the '''Browser''' button, select the driver (<code>.inf</code> file) and click on the '''OK''' button. The driver is available inside the zip file that was used to fix the Diablo kernel (<code>diablo_kernel_usbnet_patch_windows_v0.4.zip</code>). |
* Follow the next steps as with a normal driver installation. | * Follow the next steps as with a normal driver installation. | ||
The new USB Network interface is available on the '''Start - Network Connections''' menu. | The new USB Network interface is available on the '''Start - Network Connections''' menu. | ||
- | |||
- | |||
{| summary="Windows Search and Installation options for USB" | {| summary="Windows Search and Installation options for USB" | ||
Line 247: | Line 225: | ||
[[Image:mpc_win_usb_choose_driver.png|Image mpc_win_usb_choose_driver]] | [[Image:mpc_win_usb_choose_driver.png|Image mpc_win_usb_choose_driver]] | ||
|} | |} | ||
- | |||
- | |||
{| | {| | ||
Line 256: | Line 232: | ||
|} | |} | ||
- | To check if the connection is working, go to Windows command prompt and type < | + | To check if the connection is working, go to Windows command prompt and type <code>ping 192.168.2.15</code>. |
- | + | ||
- | + | ||
{| summary="Manual IP Network configuration dialog for USB" | {| summary="Manual IP Network configuration dialog for USB" | ||
Line 267: | Line 241: | ||
|} | |} | ||
- | + | ==== Configuring USB for Mac OS X ==== | |
- | + | ||
- | === Configuring USB for Mac OS X === | + | |
To enable USB Network to work on Mac OS X you can follow these steps: | To enable USB Network to work on Mac OS X you can follow these steps: | ||
Line 278: | Line 250: | ||
* Click on the '''Network Preferences''' button. | * Click on the '''Network Preferences''' button. | ||
* Click on the '''Apply''' button. Now, you should be able to connect to your Maemo device. | * Click on the '''Apply''' button. Now, you should be able to connect to your Maemo device. | ||
- | |||
- | |||
{| summary="New network interface found pop-up dialog" | {| summary="New network interface found pop-up dialog" | ||
Line 287: | Line 257: | ||
[[Image:mpc_mac_usb_pop_up.png|Image mpc_mac_usb_pop_up]] | [[Image:mpc_mac_usb_pop_up.png|Image mpc_mac_usb_pop_up]] | ||
|} | |} | ||
- | |||
- | |||
{| | {| | ||
|- | |- | ||
| [[Image:dialog-information.png]] | | [[Image:dialog-information.png]] | ||
- | | '''Note:''' If you did not choose the DHCP option on the Maemo device, you need to set up the USB network address manually on '''Network panel'''. For example, < | + | | '''Note:''' If you did not choose the DHCP option on the Maemo device, you need to set up the USB network address manually on '''Network panel'''. For example, <code>IP address: 192.168.2.14</code> <code>Subnet mask: 255.255.255.0</code>, figure [[#fig:pc_connectivity_mpc_mac_usb_tcp_properties|3.9]]. |
|} | |} | ||
- | |||
- | |||
{| summary="Network panel configuration dialog" | {| summary="Network panel configuration dialog" | ||
Line 305: | Line 271: | ||
|} | |} | ||
- | + | === Configuring Bluetooth Network === | |
- | + | ||
- | == Configuring Bluetooth Network == | + | |
With Maemo PC Connectivity, you can configure a Bluetooth network between a Maemo device and a host PC by setting up connection attributes like IP address, network mask, and so on. For that, you have to first install Maemo PC Connectivity to the Maemo device and Host PC Connectivity to the host PC (Linux, Windows or Mac OS X). | With Maemo PC Connectivity, you can configure a Bluetooth network between a Maemo device and a host PC by setting up connection attributes like IP address, network mask, and so on. For that, you have to first install Maemo PC Connectivity to the Maemo device and Host PC Connectivity to the host PC (Linux, Windows or Mac OS X). | ||
- | === Configuring Bluetooth for Maemo device === | + | ==== Configuring Bluetooth for Maemo device ==== |
In order to set up a Bluetooth network for a Maemo device, you should follow these steps: | In order to set up a Bluetooth network for a Maemo device, you should follow these steps: | ||
Line 323: | Line 287: | ||
* The default settings are presented below, you can change them if needed. | * The default settings are presented below, you can change them if needed. | ||
* Finally, click on '''Apply''' to enable the Bluetooth network. | * Finally, click on '''Apply''' to enable the Bluetooth network. | ||
- | |||
- | |||
{| summary="PC Connectivity Manager Bluetooth configuration" | {| summary="PC Connectivity Manager Bluetooth configuration" | ||
Line 332: | Line 294: | ||
[[Image:mpc_maemo_nm_bluetooth.png|Image mpc_maemo_nm_bluetooth]] | [[Image:mpc_maemo_nm_bluetooth.png|Image mpc_maemo_nm_bluetooth]] | ||
|} | |} | ||
- | |||
- | |||
Default values for Maemo device Bluetooth configuration are: | Default values for Maemo device Bluetooth configuration are: | ||
- | * '''DHCP Server:''' < | + | * '''DHCP Server:''' <code>enabled</code> |
- | * '''IP address:''' < | + | * '''IP address:''' <code>192.168.3.15</code> |
- | * '''Gateway:''' < | + | * '''Gateway:''' <code>192.168.3.14</code> |
- | * '''Netmask:''' < | + | * '''Netmask:''' <code>255.255.255.0</code> |
* '''Bluetooth address:''' empty (you should search the host PC to connect to), figure [[#fig:pc_connectivity_mpc_maemo_nm_bluetooth_search|3.11]]. | * '''Bluetooth address:''' empty (you should search the host PC to connect to), figure [[#fig:pc_connectivity_mpc_maemo_nm_bluetooth_search|3.11]]. | ||
- | |||
- | |||
{| summary="Searching Bluetooth devices dialog" | {| summary="Searching Bluetooth devices dialog" | ||
Line 351: | Line 309: | ||
[[Image:mpc_maemo_nm_bluetooth_search.png|Image mpc_maemo_nm_bluetooth_search]] | [[Image:mpc_maemo_nm_bluetooth_search.png|Image mpc_maemo_nm_bluetooth_search]] | ||
|} | |} | ||
- | |||
- | |||
Once you have configured your Bluetooth Network using PC Connectivity Manager, you can enable or disable it easily by using Connection Switcher from the status bar, figure [[#fig:pc_connectivity_mpc_maemo_switcher_bluetooth|3.12]]. | Once you have configured your Bluetooth Network using PC Connectivity Manager, you can enable or disable it easily by using Connection Switcher from the status bar, figure [[#fig:pc_connectivity_mpc_maemo_switcher_bluetooth|3.12]]. | ||
- | |||
- | |||
{| summary="Connection Switcher dialog" | {| summary="Connection Switcher dialog" | ||
Line 365: | Line 319: | ||
|} | |} | ||
+ | ==== Configuring Bluetooth for Linux ==== | ||
- | + | After you have installed the <code>host-pc-connectivity</code> package for your Linux host PC, it is ready for the Bluetooth network. | |
- | + | ||
- | + | ||
- | After you have installed the < | + | |
Or you can configure your Linux host PC manually for Bluetooth following the steps given below. | Or you can configure your Linux host PC manually for Bluetooth following the steps given below. | ||
- | Add these lines to the file < | + | Add these lines to the file <code>/etc/network/interfaces</code>: |
- | + | <pre> | |
- | + | auto bnep0 | |
- | + | iface bnep0 inet dhcp | |
- | + | up iptables -t nat -A POSTROUTING -s 192.168.3.15 -j MASQUERADE | |
- | + | up echo 1 > /proc/sys/net/ipv4/ip_forward | |
- | + | down iptables -t nat -D POSTROUTING -s 192.168.3.15 -j MASQUERADE | |
+ | down echo 0 > /proc/sys/net/ipv4/ip_forward | ||
+ | </pre> | ||
- | Edit the file < | + | Edit the file <code>/etc/default/bluetooth</code> and change these lines: |
- | + | <pre> | |
- | + | BLUETOOTH_ENABLED=1 | |
- | + | ... | |
- | + | PAND_ENABLED=1 | |
- | + | ... | |
+ | PAND_OPTIONS="-listen -role=NAP -e bnep0" | ||
+ | </pre> | ||
Restart the Bluetooth service with the command: | Restart the Bluetooth service with the command: | ||
Line 396: | Line 352: | ||
Now your Linux host PC is ready for the Bluetooth network. | Now your Linux host PC is ready for the Bluetooth network. | ||
- | === Configuring Bluetooth for Windows === | + | ==== Configuring Bluetooth for Windows ==== |
The description of how to configure Bluetooth on a Windows host PC is based on [http://www.bluesoleil.com/ the BlueSoleil application]. BlueSoleil is one of the most popular Windows Bluetooth applications. If you do not use BlueSoleil, the screenshots below can differ from what you see in your host PC, but they can help in understanding what you need to change on your Windows configuration. | The description of how to configure Bluetooth on a Windows host PC is based on [http://www.bluesoleil.com/ the BlueSoleil application]. BlueSoleil is one of the most popular Windows Bluetooth applications. If you do not use BlueSoleil, the screenshots below can differ from what you see in your host PC, but they can help in understanding what you need to change on your Windows configuration. | ||
Line 416: | Line 372: | ||
|- | |- | ||
| [[Image:dialog-information.png]] | | [[Image:dialog-information.png]] | ||
- | | '''Note:''' If you did not choose the DHCP option on the Maemo device, type the following information for the network adapter: < | + | | '''Note:''' If you did not choose the DHCP option on the Maemo device, type the following information for the network adapter: <code>IP address: 192.168.3.14</code> <code>Subnet mask: 255.255.255.0</code>, figure [[#fig:pc_connectivity_mpc_win_bluetooth_tcp|3.18]] |
|} | |} | ||
- | |||
- | |||
{| summary="Bluetooth configuration menu" | {| summary="Bluetooth configuration menu" | ||
Line 427: | Line 381: | ||
[[Image:mpc_win_bluetooth_tray.png|Image mpc_win_bluetooth_tray]] | [[Image:mpc_win_bluetooth_tray.png|Image mpc_win_bluetooth_tray]] | ||
|} | |} | ||
- | |||
- | |||
- | |||
- | |||
{| summary="Bluetooth Accessibility dialog" | {| summary="Bluetooth Accessibility dialog" | ||
Line 438: | Line 388: | ||
[[Image:mpc_win_bluetooth_accessibility.png|Image mpc_win_bluetooth_accessibility]] | [[Image:mpc_win_bluetooth_accessibility.png|Image mpc_win_bluetooth_accessibility]] | ||
|} | |} | ||
- | |||
- | |||
- | |||
- | |||
{| summary="Bluetooth Network Access entry" | {| summary="Bluetooth Network Access entry" | ||
Line 449: | Line 395: | ||
[[Image:mpc_win_bluetooth_services.png|Image mpc_win_bluetooth_services]] | [[Image:mpc_win_bluetooth_services.png|Image mpc_win_bluetooth_services]] | ||
|} | |} | ||
- | |||
- | |||
- | |||
- | |||
{| summary="Bluetooth Properties dialog" | {| summary="Bluetooth Properties dialog" | ||
Line 460: | Line 402: | ||
[[Image:mpc_win_bluetooth_properties.png|Image mpc_win_bluetooth_properties]] | [[Image:mpc_win_bluetooth_properties.png|Image mpc_win_bluetooth_properties]] | ||
|} | |} | ||
- | |||
- | |||
- | |||
- | |||
{| summary="Bluetooth Network properties dialog" | {| summary="Bluetooth Network properties dialog" | ||
Line 471: | Line 409: | ||
[[Image:mpc_win_bluetooth_network.png|Image mpc_win_bluetooth_network]] | [[Image:mpc_win_bluetooth_network.png|Image mpc_win_bluetooth_network]] | ||
|} | |} | ||
- | |||
- | |||
- | |||
- | |||
{| summary="Network Adapter configuration dialog" | {| summary="Network Adapter configuration dialog" | ||
Line 483: | Line 417: | ||
|} | |} | ||
+ | ==== Configuring Bluetooth for Mac OS X ==== | ||
- | + | After installing the <code>PC-Connectivity</code> package to the host PC, your Mac OS X is ready for the Bluetooth network. | |
- | + | ||
- | + | ||
- | After installing the < | + | |
Otherwise, you can configure your Mac OS host PC manually by following these steps. | Otherwise, you can configure your Mac OS host PC manually by following these steps. | ||
Line 500: | Line 432: | ||
|- | |- | ||
| [[Image:dialog-information.png]] | | [[Image:dialog-information.png]] | ||
- | | '''Note:''' If you did not choose the DHCP option on the Maemo device, select the newly created '''Bluetooth PAN''' interface and use the '''Manually''' option in the '''Configure''' field. After that, type the following information: < | + | | '''Note:''' If you did not choose the DHCP option on the Maemo device, select the newly created '''Bluetooth PAN''' interface and use the '''Manually''' option in the '''Configure''' field. After that, type the following information: <code>IP address: 192.168.3.14</code> <code>Subnet mask: 255.255.255.0</code>, figure [[#fig:pc_connectivity_mpc_mac_bluetooth_network_tcp|3.22]] |
|} | |} | ||
- | |||
- | |||
{| summary="System Preferences dialog" | {| summary="System Preferences dialog" | ||
Line 511: | Line 441: | ||
[[Image:mpc_mac_bluetooth_network_preferences.png|Image mpc_mac_bluetooth_network_preferences]] | [[Image:mpc_mac_bluetooth_network_preferences.png|Image mpc_mac_bluetooth_network_preferences]] | ||
|} | |} | ||
- | |||
- | |||
- | |||
- | |||
{| summary="Adding new network interface" | {| summary="Adding new network interface" | ||
Line 522: | Line 448: | ||
[[Image:mpc_mac_bluetooth_network_add.png|Image mpc_mac_bluetooth_network_add]] | [[Image:mpc_mac_bluetooth_network_add.png|Image mpc_mac_bluetooth_network_add]] | ||
|} | |} | ||
- | |||
- | |||
- | |||
- | |||
{| summary="Configuring new Bluetooth interface name" | {| summary="Configuring new Bluetooth interface name" | ||
Line 533: | Line 455: | ||
[[Image:mpc_mac_bluetooth_network_name.png|Image mpc_mac_bluetooth_network_name]] | [[Image:mpc_mac_bluetooth_network_name.png|Image mpc_mac_bluetooth_network_name]] | ||
|} | |} | ||
- | |||
- | |||
- | |||
- | |||
{| summary="Configuring Bluetooth interface network" | {| summary="Configuring Bluetooth interface network" | ||
Line 545: | Line 463: | ||
|} | |} | ||
- | + | === Configuring a WLAN ad-hoc Network === | |
- | + | ||
- | == Configuring a WLAN ad-hoc Network == | + | |
With Maemo PC Connectivity, you can configure a WLAN ad-hoc network for your Maemo device. You can set up connection attributes such as IP address, network mask, and so on. | With Maemo PC Connectivity, you can configure a WLAN ad-hoc network for your Maemo device. You can set up connection attributes such as IP address, network mask, and so on. | ||
- | === Configuring WLAN ad-hoc for a Maemo device === | + | ==== Configuring WLAN ad-hoc for a Maemo device ==== |
To set up a WLAN ad-hoc network for your Maemo device, you need to perform the following configuration steps. | To set up a WLAN ad-hoc network for your Maemo device, you need to perform the following configuration steps. | ||
In Control Panel, open the PC Connectivity Manager widget, figure [[#fig:pc_connectivity_mpc_maemo_nm_wlan_basic|3.23]]. | In Control Panel, open the PC Connectivity Manager widget, figure [[#fig:pc_connectivity_mpc_maemo_nm_wlan_basic|3.23]]. | ||
- | |||
- | |||
{| summary="PC Connectivity Manager - basic mode" | {| summary="PC Connectivity Manager - basic mode" | ||
Line 565: | Line 479: | ||
[[Image:mpc_maemo_nm_wlan_basic.png|Image mpc_maemo_nm_wlan_basic]] | [[Image:mpc_maemo_nm_wlan_basic.png|Image mpc_maemo_nm_wlan_basic]] | ||
|} | |} | ||
- | |||
- | |||
Select the '''WLAN''' check-box and press the '''Apply''' button. A new WLAN ad-hoc connection is created with the following configuration: | Select the '''WLAN''' check-box and press the '''Apply''' button. A new WLAN ad-hoc connection is created with the following configuration: | ||
- | * '''DHCP Server:''' < | + | * '''DHCP Server:''' <code>Enabled</code> |
- | * '''IP Address:''' < | + | * '''IP Address:''' <code>192.168.4.14</code> |
- | * '''Gateway:''' < | + | * '''Gateway:''' <code>192.168.4.15</code> |
- | * '''Netmask:''' < | + | * '''Netmask:''' <code>255.255.255.0</code> |
- | * '''Essid:''' < | + | * '''Essid:''' <code>devel_adhoc</code> |
* '''WEP:''' key empty | * '''WEP:''' key empty | ||
Line 585: | Line 497: | ||
|} | |} | ||
- | The WEP key must have 5, 10 or 13 characters (For example: < | + | The WEP key must have 5, 10 or 13 characters (For example: <code>aaaaa</code>). |
- | + | ||
- | + | ||
{| summary="PC Connectivity Manager - advanced mode" | {| summary="PC Connectivity Manager - advanced mode" | ||
Line 595: | Line 505: | ||
[[Image:mpc_maemo_nm_wlan.png|Image mpc_maemo_nm_wlan]] | [[Image:mpc_maemo_nm_wlan.png|Image mpc_maemo_nm_wlan]] | ||
|} | |} | ||
- | |||
- | |||
Once you have configured your WLAN ad-hoc Network using PC Connectivity Manager, you can enable or disable it easily using Connection Switcher from the status bar, figure [[#fig:pc_connectivity_mpc_maemo_switcher_wlan|3.25]]. | Once you have configured your WLAN ad-hoc Network using PC Connectivity Manager, you can enable or disable it easily using Connection Switcher from the status bar, figure [[#fig:pc_connectivity_mpc_maemo_switcher_wlan|3.25]]. | ||
- | |||
- | |||
{| summary="Connection Switcher dialog" | {| summary="Connection Switcher dialog" | ||
Line 609: | Line 515: | ||
|} | |} | ||
+ | ==== Configuring WLAN ad-hoc for Linux ==== | ||
+ | The <code>iwconfig</code> command is the configuration utility in Linux for WLAN interfaces. It is used to set the parameters of the network interface, which are specific to the wireless operation. The <code>iwconfig</code> command may also be used to display the parameters and the wireless network statistics. It extracts this information from the <code>/proc/net/wireless</code> file. By typing the <code>iwconfig</code> command without any arguments, it displays the current status of all wireless interfaces on the system. | ||
- | + | To configure your host PC to connect with your Maemo device using a WLAN ad-hoc network, you should execute the following steps as <code>root</code> user: | |
- | + | <pre> | |
- | + | $ ifconfig wlan0 up | |
- | + | $ iwconfig wlan0 mode Ad-Hoc | |
- | + | $ iwconfig wlan0 essid devel_adhoc | |
- | + | $ iwconfig wlan0 key off | |
- | + | </pre> | |
- | + | ||
- | + | ||
{| | {| | ||
Line 632: | Line 538: | ||
$ iwconfig wlan0 key 6161616161 | $ iwconfig wlan0 key 6161616161 | ||
- | You must use the same WEP key you used for Maemo device configuration, but as hexadecimal digits (for example, < | + | You must use the same WEP key you used for Maemo device configuration, but as hexadecimal digits (for example, <code>aaaaa</code> is <code>6161616161</code> in hexadecimal). |
- | === Configuring WLAN ad-hoc for Windows === | + | ==== Configuring WLAN ad-hoc for Windows ==== |
To set up a WLAN ad-hoc network that allows others computers to connect to your Windows host PC, follow these steps. | To set up a WLAN ad-hoc network that allows others computers to connect to your Windows host PC, follow these steps. | ||
- | * Connect your Maemo device to < | + | * Connect your Maemo device to <code>devel_adhoc</code>. |
* In the '''System Tray''', right click on the wireless icon. Select the '''View Available Wireless Networks''' option, figure [[#fig:pc_connectivity_mpc_win_wlan_tray|3.26]]. | * In the '''System Tray''', right click on the wireless icon. Select the '''View Available Wireless Networks''' option, figure [[#fig:pc_connectivity_mpc_win_wlan_tray|3.26]]. | ||
- | * The '''Wireless Network Connection''' window displays the < | + | * The '''Wireless Network Connection''' window displays the <code>devel_adhoc</code> network on the list. If you do not see <code>devel_adhoc</code>, click '''Refresh network list''' in the upper left corner, figure [[#fig:pc_connectivity_mpc_win_wlan_selection|3.27]]. |
- | * Select < | + | * Select <code>devel_adhoc</code>, and then click on the '''Connect''' button. |
* If you configured the '''WEP Key''' for your Maemo device, the Windows asks you to write that key at this point, figure [[#fig:pc_connectivity_mpc_win_wlan_key|3.28]]. | * If you configured the '''WEP Key''' for your Maemo device, the Windows asks you to write that key at this point, figure [[#fig:pc_connectivity_mpc_win_wlan_key|3.28]]. | ||
- | |||
- | |||
{| summary="View Available Wireless Networks menu" | {| summary="View Available Wireless Networks menu" | ||
Line 652: | Line 556: | ||
[[Image:mpc_win_wlan_tray.png|Image mpc_win_wlan_tray]] | [[Image:mpc_win_wlan_tray.png|Image mpc_win_wlan_tray]] | ||
|} | |} | ||
- | |||
- | |||
- | |||
- | |||
{| summary="Choose a wireless network dialog" | {| summary="Choose a wireless network dialog" | ||
Line 663: | Line 563: | ||
[[Image:mpc_win_wlan_selection.png|Image mpc_win_wlan_selection]] | [[Image:mpc_win_wlan_selection.png|Image mpc_win_wlan_selection]] | ||
|} | |} | ||
- | |||
- | |||
- | |||
- | |||
{| summary="Wireless network key dialog" | {| summary="Wireless network key dialog" | ||
Line 675: | Line 571: | ||
|} | |} | ||
- | + | ==== Configuring WLAN ad-hoc for Mac OS X ==== | |
- | + | ||
- | === Configuring WLAN ad-hoc for Mac OS X === | + | |
To configure a WLAN ad-hoc network for your Mac OS X host PC, follow these steps. | To configure a WLAN ad-hoc network for your Mac OS X host PC, follow these steps. | ||
- | * Connect your maemo device to < | + | * Connect your maemo device to <code>devel_adhoc</code>. |
- | * On the '''Menu Bar''', click on the wireless icon and select the < | + | * On the '''Menu Bar''', click on the wireless icon and select the <code>devel_adhoc</code> network. |
* If you configured '''WEP Key''' for your Maemo device, the Mac OS X asks you to write that key at this point. | * If you configured '''WEP Key''' for your Maemo device, the Mac OS X asks you to write that key at this point. | ||
* The wireless icon should change to inform that it is now connected. | * The wireless icon should change to inform that it is now connected. | ||
- | = Using Configuration Environments = | + | == Using Configuration Environments == |
- | With Maemo PC Connectivity, it is possible to use configuration environments for your Maemo device. For example, you can create an environment named < | + | With Maemo PC Connectivity, it is possible to use configuration environments for your Maemo device. For example, you can create an environment named <code>Home</code> that has the USB connection and the NFS disk mounts configured, and an environment named <code>Office</code> that has the WLAN connection and the SBRSH tool configured. When you are at home you can select a <code>Home</code> environment for your Maemo device and all previously stored connection and tool configurations in the <code>Home</code> environment are restored for your Maemo device. |
To create or modify new configuration environments for your Maemo device you need to launch the Environment Manager widget, figure [[#fig:pc_connectivity_mpc_maemo_nm_env_create|3.29]]. | To create or modify new configuration environments for your Maemo device you need to launch the Environment Manager widget, figure [[#fig:pc_connectivity_mpc_maemo_nm_env_create|3.29]]. | ||
- | |||
- | |||
{| summary="Environment Manager" | {| summary="Environment Manager" | ||
Line 700: | Line 592: | ||
[[Image:mpc_maemo_nm_env_create.png|Image mpc_maemo_nm_env_create]] | [[Image:mpc_maemo_nm_env_create.png|Image mpc_maemo_nm_env_create]] | ||
|} | |} | ||
- | |||
- | |||
To create a new environment you should follow these steps: | To create a new environment you should follow these steps: | ||
Line 714: | Line 604: | ||
After you have created new environments, you can switch between them using the Connection Switcher widget, figure [[#fig:pc_connectivity_mpc_maemo_switcher_env|3.30]]. | After you have created new environments, you can switch between them using the Connection Switcher widget, figure [[#fig:pc_connectivity_mpc_maemo_switcher_env|3.30]]. | ||
- | |||
- | |||
{| summary="Connection Switcher" | {| summary="Connection Switcher" | ||
Line 723: | Line 611: | ||
[[Image:mpc_maemo_switcher_env.png|Image mpc_maemo_switcher_env]] | [[Image:mpc_maemo_switcher_env.png|Image mpc_maemo_switcher_env]] | ||
|} | |} | ||
- | |||
- | |||
To change between stored environments using Connection Switcher: | To change between stored environments using Connection Switcher: | ||
Line 734: | Line 620: | ||
Also, the PC Connectivity Manager widget can be used to switch between stored environments, figure [[#fig:pc_connectivity_mpc_maemo_nm_env_basic|3.31]]. | Also, the PC Connectivity Manager widget can be used to switch between stored environments, figure [[#fig:pc_connectivity_mpc_maemo_nm_env_basic|3.31]]. | ||
- | |||
- | |||
{| summary="PC Connectivity Manager - Basic mode" | {| summary="PC Connectivity Manager - Basic mode" | ||
Line 743: | Line 627: | ||
[[Image:mpc_maemo_nm_env_basic.png|Image mpc_maemo_nm_env_basic]] | [[Image:mpc_maemo_nm_env_basic.png|Image mpc_maemo_nm_env_basic]] | ||
|} | |} | ||
- | |||
- | |||
* Run '''Settings - Control Panel - Connectivity - PC Connectivity Manager'''. | * Run '''Settings - Control Panel - Connectivity - PC Connectivity Manager'''. | ||
Line 751: | Line 633: | ||
You can modify stored configuration environments with the PC Connectivity Manager widget in its '''Advanced''' mode, figure [[#fig:pc_connectivity_mpc_maemo_nm_env_advanced|3.32]]. | You can modify stored configuration environments with the PC Connectivity Manager widget in its '''Advanced''' mode, figure [[#fig:pc_connectivity_mpc_maemo_nm_env_advanced|3.32]]. | ||
- | |||
- | |||
{| summary="PC Connectivity Manager - Advanced mode" | {| summary="PC Connectivity Manager - Advanced mode" | ||
Line 760: | Line 640: | ||
[[Image:mpc_maemo_nm_env.png|Image mpc_maemo_nm_env]] | [[Image:mpc_maemo_nm_env.png|Image mpc_maemo_nm_env]] | ||
|} | |} | ||
- | |||
- | |||
* Run '''Settings - Control Panel - Connectivity - PC Connectivity Manager'''. | * Run '''Settings - Control Panel - Connectivity - PC Connectivity Manager'''. | ||
* Click on the '''Advanced''' button. | * Click on the '''Advanced''' button. | ||
* Change the environment configuration. For example, USB connection and/or X11VNC tool. | * Change the environment configuration. For example, USB connection and/or X11VNC tool. | ||
- | * Click on the '''Apply''' button. All configurations, including changes, are saved and | + | * Click on the '''Apply''' button. All configurations, including changes, are saved and applied |
[[Category:Documentation]] | [[Category:Documentation]] |
Latest revision as of 14:25, 20 October 2010
Contents |
[edit] Connection Establishment
On a Maemo device, connections can be easily configured using Maemo PC Connectivity applets. It is possible to configure a Maemo device to use USB, Bluetooth and WLAN connection types.
USB connection type sets a USB mode (Network, Mass Storage or Host) to be used between a Maemo device and a host PC.
Bluetooth connection type sets a Bluetooth network over TCP/IP between a Maemo device and a host PC.
WLAN connection type sets a WLAN ad-hoc network between a Maemo device and a host PC.
On the host PC side (Linux, Windows and Mac OS X), the Host PC Connectivity product provides some tools to make it easier to configure the chosen connection type between the Maemo device and the host PC. Next the configuration of each supported connection type (USB, Bluetooth and WLAN) between the Maemo device and host PC are described briefly.
[edit] Configuring USB Network
For Maemo Diablo devices, the USB connection has been configured to Mass storage mode by default. That is, when connected to a host PC via USB cable, the Maemo device is visible as a memory card for the host PC.
For Fremantle, when a Maemo device is connected to the host PC via USB cable, the Maemo device shows a default pop-up menu where the USB mode can be selected. the choices given are Mass storage or PC Suite mode. You must NOT use this default USB pop-up menu if you have installed Maemo PC Connectivity to the N900 device! Just click outside this default USB pop-up menu to close it and use Maemo PC Connectivity widgets to change the USB mode.
File:Dialog-information.png | Note: With the Maemo Fremantle platform and N900 device, if Maemo PC Connectivity has been installed, the USB connection is used in a different way beyond the default Mass storage and PC Suite modes and thus ONLY Maemo PC Connectivity applets can be used to change the USB mode for the Maemo N900 device. |
For USB connection type it is possible to set following options for a Maemo device:
- Network
- sets a USB network over TCP/IP between the Maemo device and host PC.
- Mass storage
- sets the Maemo device file system to be accessible from the host PC as a memory card.
- PC Suite
- sets the Maemo device to be accessible by Nokia applications like Nokia PC Suite.
- Host
- sets the Maemo device to USB Host mode, where it allows external USB devices (such as hard drives, digital cameras, card readers, input devices, and so on) to be connected to the Maemo device, just like to a regular PC.
File:Dialog-information.png | Note: Maemo Diablo N800 and N810 devices do not support PC Suite mode. Due to hardware limitations, Maemo Fremantle device N900 does not support USB Host mode. |
The description of how to setup a USB connection to Mass storage, PC Suite and Host modes is skipped, since the configuration is simply to select and apply the desired mode on a Maemo device using Maemo PC Connectivity. Next, it is explained how to configure a USB network over TCP/IP between a Maemo device and host PC through Maemo PC Connectivity. Before that, you must install the maemo-pc-connectivity
meta package on the Maemo device and the host-pc-connectivity
package on the host PC (Linux, Windows and Mac OS).
[edit] Configuring USB for Maemo devices
To set up a USB network for a Maemo device you need to start PC Connectivity Manager, figure 3.1.
Follow these steps to enable USB Networking:
- Disconnect the USB cable from Maemo device
- Run Settings - Control Panel - Connectivity - PC Connectivity Manager
- Check USB option
- Press Apply button
- Connect the USB cable to the host PC.
- Press the Advanced button and PC Connectivity Manager switches to advanced mode, if you want to change the default values.
- Change network options such as DHCP Server, IP address, Gateway and Netmask.
- Click on the Apply button.
The USB Networking must have the following default values, figure 3.2.
- DHCP Server:
enabled
- IP address:
192.168.2.15
- Gateway:
192.168.2.14
- Netmask:
255.255.255.0
Once you have configured your USB Network using PC Connectivity Manager, you can enable or disable it easily by using Connection Switcher from the status bar, figure 3.3.
If you prefer, you can follow the steps below to configure USB Network manually for a Maemo device (Diablo):
- Run Utilities - X Terminal
- Type
sudo gainroot
- Type
insmod /mnt/initfs/lib/modules/2.6.21-omap1/g_ether.ko
- Edit the
/etc/network/interfaces
file to configure the IP address of theusb0
interface:
The /etc/network/interfaces
file should have following entries in it:
auto usb0 iface usb0 inet static address 192.168.2.15 netmask 255.255.255.0
- Type
ifup usb0
- Plug in the USB cable
To disable USB Network manually on a Maemo device (Diablo), follow these steps:
- Run Utilities - X Terminal
- Type
sudo gainroot
- Type
ifdown usb0
- Type
rmmod g_ether
[edit] Configuring USB for Linux
If you install the host-pc-connectivity
package, your Linux host PC is ready for USB Network.
Otherwise, you can configure your Linux host PC manually following the steps below:
On Ubuntu, you need to edit the /etc/udev/rules.d/85-ifupdown.rules
file and replace the following line:
SUBSYSTEM=="net", DRIVERS=="?*", GOTO="net_start"
with this line:
SUBSYSTEM=="net", GOTO="net_start"
If this workaround is not done, the usb0
interface does not get its IP address back when you unplug and plug back the Maemo device to the host PC. Therefore, you must restart the network manually with the command /etc/init.d/networking restart
to get the usb0
IP address back. This is a known issue on Ubuntu (see the related bug report here).
On Debian, this workaround is not needed.
Add the following lines to the network configuration file /etc/network/interfaces
:
auto usb0 allow-hotplug usb0 mapping hotplug script grep map usb0 iface usb0 inet dhcp up iptables -t nat -A POSTROUTING -s 192.168.2.15 -j MASQUERADE up echo 1 > /proc/sys/net/ipv4/ip_forward down iptables -t nat -D POSTROUTING -s 192.168.2.15 -j MASQUERADE down echo 0 > /proc/sys/net/ipv4/ip_forward
You can now connect the USB cable. With this configuration, you ensure that the ifup usb0
command sets up the IP address correctly on the host PC since it is using DHCP. Also, it allows a Maemo device to access the Internet from the host PC through the usb0
interface.
If you are using VMware:
- Connect USB cable.
- Go to VMware - Devices - Netchip RNDIS/Ethernet Gadget and click on the Connect (Disconnect from host) option. If VMware hangs, unplug the USB cable and wait for a short period of time. You get two
device in use
error messages, one from Native OS and another from VMware (likely because of automatic USB Mass Storage mode). - Connect the USB cable. Repeat the previous steps if any problems are encountered.
Invoke the sudo ifdown usb0
and sudo ifup usb0
commands. The down/up sequence ensures that the host PC attempts to reconnect the usb0
interface.
If this results in a lot of Failed to bring up usb0
errors, try again a few times. There can be a delay until the host PC and Maemo device become aware of each other. If it does not succeed but no error message is displayed, you can unplug and plug back the USB cable.
Test the usb0
connection with the following command ping 192.168.2.15
If you do not get the ping working, try again a few times. This can be an annoying process, especially in VMware where the USB connection may be automatically configured to Mass Storage mode every time you plug the USB cable into the host PC. It may even require restarting VMware in some cases.
[edit] Configuring USB for Windows
In order to get USB Networking functioning between a Windows host PC and a Diablo Maemo device, you must replace the original Diablo kernel with a new one that fixes some generic Linux USB Networking issues.
To replace the Diablo kernel, follow these steps:
- Download the file
diablo_kernel_usbnet_patch_windows_v0.4.zip
from Maemo Development Environment Downloads page. - Unzip the file.
- Replace the Diablo kernel by reflashing it using the flasher-3.5 application from the same Maemo Development Environment Downloads page.
$ flasher-3.5 -k diablo_kernel_usbnet_windows/zImage -f -R
Now, you can get USB Network working between a Diablo Maemo device and a Windows host PC.
File:Dialog-information.png | Note: On Fremantle and the N900 device this kernel fix has already been applied by default. |
After reflashing the kernel to the Maemo Diablo device and installing the PC-Connectivity.exe
package to the host PC, your Windows host PC is ready for USB Network. That is, Windows detects and configures the Maemo device automatically when you plug in the USB cable. Remember to activate USB Network on your Maemo device before plugging the cable into the Windows host PC.
If you did not enable the DHCP option for the Maemo device, you need to configure the USB Network address for the host PC through the application available on the Windows Start menu Start - Programs - PC-Connectivity - UsbNetworking, figure 3.4.
If you do not install the PC-Connectivity
package, you have to configure the USB network manually on your Windows host PC. For that, you must follow the steps below:
- Activate USB Network on the Maemo device.
- Plug in the USB cable between the Maemo device and the Windows host PC.
- Windows detects the device.
In the Found New Hardware Wizard, figure 3.5, proceed as follows:
- Select the No, not this time option. Click on the Next button, figure 3.5.
- Select the Install from a list or specific location (Advanced) option. Click on the Next button.
- Select the Don't search, I will choose the driver to install option.
- Click on the Next button, figure 3.6.
- Select the Network adapters option. Click on the next button (optional screen).
- Select the Have disk option. Then, Click on the Browser button, select the driver (
.inf
file) and click on the OK button. The driver is available inside the zip file that was used to fix the Diablo kernel (diablo_kernel_usbnet_patch_windows_v0.4.zip
). - Follow the next steps as with a normal driver installation.
The new USB Network interface is available on the Start - Network Connections menu.
File:Dialog-information.png | Note: If you did NOT choose the DHCP option on the Maemo device, you need to set up the network using the following information: IP address: 192.168.2.14 Subnet mask: 255.255.255.0, figure 3.7. |
To check if the connection is working, go to Windows command prompt and type ping 192.168.2.15
.
[edit] Configuring USB for Mac OS X
To enable USB Network to work on Mac OS X you can follow these steps:
- Activate USB network on the Maemo device.
- Plug in the USB cable between Maemo device and the Mac OS X host PC.
- The following pop-up should appear, figure 3.8.
- Click on the Network Preferences button.
- Click on the Apply button. Now, you should be able to connect to your Maemo device.
File:Dialog-information.png | Note: If you did not choose the DHCP option on the Maemo device, you need to set up the USB network address manually on Network panel. For example, IP address: 192.168.2.14 Subnet mask: 255.255.255.0 , figure 3.9.
|
[edit] Configuring Bluetooth Network
With Maemo PC Connectivity, you can configure a Bluetooth network between a Maemo device and a host PC by setting up connection attributes like IP address, network mask, and so on. For that, you have to first install Maemo PC Connectivity to the Maemo device and Host PC Connectivity to the host PC (Linux, Windows or Mac OS X).
[edit] Configuring Bluetooth for Maemo device
In order to set up a Bluetooth network for a Maemo device, you should follow these steps:
- Run Settings - Control Panel - Connectivity - PC Connectivity Manager.
- Click on the Advanced button.
- Select an environment or create a new one.
- Select the Bluetooth option as shown in Figure 3.10.
- Click on Search to find the host PC.
- Once the host PC is found, mark its name and then click Select, figure 3.11.
- The default settings are presented below, you can change them if needed.
- Finally, click on Apply to enable the Bluetooth network.
Default values for Maemo device Bluetooth configuration are:
- DHCP Server:
enabled
- IP address:
192.168.3.15
- Gateway:
192.168.3.14
- Netmask:
255.255.255.0
- Bluetooth address: empty (you should search the host PC to connect to), figure 3.11.
Once you have configured your Bluetooth Network using PC Connectivity Manager, you can enable or disable it easily by using Connection Switcher from the status bar, figure 3.12.
[edit] Configuring Bluetooth for Linux
After you have installed the host-pc-connectivity
package for your Linux host PC, it is ready for the Bluetooth network.
Or you can configure your Linux host PC manually for Bluetooth following the steps given below.
Add these lines to the file /etc/network/interfaces
:
auto bnep0 iface bnep0 inet dhcp up iptables -t nat -A POSTROUTING -s 192.168.3.15 -j MASQUERADE up echo 1 > /proc/sys/net/ipv4/ip_forward down iptables -t nat -D POSTROUTING -s 192.168.3.15 -j MASQUERADE down echo 0 > /proc/sys/net/ipv4/ip_forward
Edit the file /etc/default/bluetooth
and change these lines:
BLUETOOTH_ENABLED=1 ... PAND_ENABLED=1 ... PAND_OPTIONS="-listen -role=NAP -e bnep0"
Restart the Bluetooth service with the command:
$ sudo /etc/init.d/bluetooth restart
Now your Linux host PC is ready for the Bluetooth network.
[edit] Configuring Bluetooth for Windows
The description of how to configure Bluetooth on a Windows host PC is based on the BlueSoleil application. BlueSoleil is one of the most popular Windows Bluetooth applications. If you do not use BlueSoleil, the screenshots below can differ from what you see in your host PC, but they can help in understanding what you need to change on your Windows configuration.
You should follow the next steps to get the Bluetooth network configured in your Windows host PC (with BlueSoleil).
- In the System tray, right click on the Bluetooth icon .
- Select the Bluetooth Configuration option, figure 3.13.
- In the Bluetooth Configuration dialog, select the Accessibility tab.
- Check the Let other Bluetooth devices discover this computer option, figure 3.14.
- In the Bluetooth Configuration dialog, select the Local Services tab.
- Mark the Network Access service and click the Properties... button, figure 3.15.
- If you want to share Internet over Bluetooth, select Allow other devices to access the Internet/LAN via this computer on the Select the type of the service to offer remote devices option.
- Click on the Configure Network Adapter button, figure 3.16.
- Double click on the Internet Protocol (TCP/IP) option, figure 3.17.
- For all opened dialogs, press the OK button.
File:Dialog-information.png | Note: If you did not choose the DHCP option on the Maemo device, type the following information for the network adapter: IP address: 192.168.3.14 Subnet mask: 255.255.255.0 , figure 3.18
|
[edit] Configuring Bluetooth for Mac OS X
After installing the PC-Connectivity
package to the host PC, your Mac OS X is ready for the Bluetooth network.
Otherwise, you can configure your Mac OS host PC manually by following these steps.
- Go to System Preferences and click on the Network icon, figure 3.19.
- Add a new network interface, figure 3.20.
- For the Interface field, select Bluetooth PAN type.
- For the Service Name field, write the interface name, figure 3.21.
- Press the Apply button.
File:Dialog-information.png | Note: If you did not choose the DHCP option on the Maemo device, select the newly created Bluetooth PAN interface and use the Manually option in the Configure field. After that, type the following information: IP address: 192.168.3.14 Subnet mask: 255.255.255.0 , figure 3.22
|
[edit] Configuring a WLAN ad-hoc Network
With Maemo PC Connectivity, you can configure a WLAN ad-hoc network for your Maemo device. You can set up connection attributes such as IP address, network mask, and so on.
[edit] Configuring WLAN ad-hoc for a Maemo device
To set up a WLAN ad-hoc network for your Maemo device, you need to perform the following configuration steps.
In Control Panel, open the PC Connectivity Manager widget, figure 3.23.
Select the WLAN check-box and press the Apply button. A new WLAN ad-hoc connection is created with the following configuration:
- DHCP Server:
Enabled
- IP Address:
192.168.4.14
- Gateway:
192.168.4.15
- Netmask:
255.255.255.0
- Essid:
devel_adhoc
- WEP: key empty
If you want to change these default values, press the Advanced button, go to WLAN ad-hoc connection type and change the values. Then, press the Apply button, figure 3.24.
File:Dialog-information.png | Note: By default, the WEP key is not used for new WLAN networks but for security reasons it is highly recommended to set also the wireless key. |
The WEP key must have 5, 10 or 13 characters (For example: aaaaa
).
Once you have configured your WLAN ad-hoc Network using PC Connectivity Manager, you can enable or disable it easily using Connection Switcher from the status bar, figure 3.25.
[edit] Configuring WLAN ad-hoc for Linux
The iwconfig
command is the configuration utility in Linux for WLAN interfaces. It is used to set the parameters of the network interface, which are specific to the wireless operation. The iwconfig
command may also be used to display the parameters and the wireless network statistics. It extracts this information from the /proc/net/wireless
file. By typing the iwconfig
command without any arguments, it displays the current status of all wireless interfaces on the system.
To configure your host PC to connect with your Maemo device using a WLAN ad-hoc network, you should execute the following steps as root
user:
$ ifconfig wlan0 up $ iwconfig wlan0 mode Ad-Hoc $ iwconfig wlan0 essid devel_adhoc $ iwconfig wlan0 key off
File:Dialog-information.png | Note: The example below disables the usage of wireless key, but for security reasons it is highly recommended to set also the wireless key. |
To set the wireless key for your WLAN ad-hoc network, you should give the following command (using your own key value).
$ iwconfig wlan0 key 6161616161
You must use the same WEP key you used for Maemo device configuration, but as hexadecimal digits (for example, aaaaa
is 6161616161
in hexadecimal).
[edit] Configuring WLAN ad-hoc for Windows
To set up a WLAN ad-hoc network that allows others computers to connect to your Windows host PC, follow these steps.
- Connect your Maemo device to
devel_adhoc
. - In the System Tray, right click on the wireless icon. Select the View Available Wireless Networks option, figure 3.26.
- The Wireless Network Connection window displays the
devel_adhoc
network on the list. If you do not seedevel_adhoc
, click Refresh network list in the upper left corner, figure 3.27. - Select
devel_adhoc
, and then click on the Connect button. - If you configured the WEP Key for your Maemo device, the Windows asks you to write that key at this point, figure 3.28.
[edit] Configuring WLAN ad-hoc for Mac OS X
To configure a WLAN ad-hoc network for your Mac OS X host PC, follow these steps.
- Connect your maemo device to
devel_adhoc
. - On the Menu Bar, click on the wireless icon and select the
devel_adhoc
network. - If you configured WEP Key for your Maemo device, the Mac OS X asks you to write that key at this point.
- The wireless icon should change to inform that it is now connected.
[edit] Using Configuration Environments
With Maemo PC Connectivity, it is possible to use configuration environments for your Maemo device. For example, you can create an environment named Home
that has the USB connection and the NFS disk mounts configured, and an environment named Office
that has the WLAN connection and the SBRSH tool configured. When you are at home you can select a Home
environment for your Maemo device and all previously stored connection and tool configurations in the Home
environment are restored for your Maemo device.
To create or modify new configuration environments for your Maemo device you need to launch the Environment Manager widget, figure 3.29.
To create a new environment you should follow these steps:
- Run Settings - Control Panel - Connectivity - PC Connectivity Manager.
- Click on the Advanced button.
- Click on the ... button.
- Click on the New button.
- Set the environment name. For example, Home, and click on the Ok button.
- Configure connections and tools to be used with this environment. For example, USB connection and NFS tool.
- Click on the Save button.
After you have created new environments, you can switch between them using the Connection Switcher widget, figure 3.30.
To change between stored environments using Connection Switcher:
- Run Connection Switcher from the status bar.
- Select an environment.
All stored configuration information for the chosen environment are applied to the Maemo device.
Also, the PC Connectivity Manager widget can be used to switch between stored environments, figure 3.31.
- Run Settings - Control Panel - Connectivity - PC Connectivity Manager.
- Select an environment.
- Click on the Apply button.
You can modify stored configuration environments with the PC Connectivity Manager widget in its Advanced mode, figure 3.32.
- Run Settings - Control Panel - Connectivity - PC Connectivity Manager.
- Click on the Advanced button.
- Change the environment configuration. For example, USB connection and/or X11VNC tool.
- Click on the Apply button. All configurations, including changes, are saved and applied
- This page was last modified on 20 October 2010, at 14:25.
- This page has been accessed 11,750 times.