Project

General

Profile

DeprecatedReplicant60USBNetworking » History » Version 5

Wolfgang Wiedmeyer, 03/08/2017 06:29 PM
Replicant 6.0 update third part

1 1 Wolfgang Wiedmeyer
h1. Replicant USB Networking
2
3 2 Wolfgang Wiedmeyer
This page explains how to connect your Replicant device to the Internet via an USB connection to a computer connected to the Internet.
4 1 Wolfgang Wiedmeyer
5 4 Wolfgang Wiedmeyer
h2. Replicant 6.0
6 1 Wolfgang Wiedmeyer
7 4 Wolfgang Wiedmeyer
Replicant USB Networking requires a script: "usb_networking_device.sh":https://git.replicant.us/replicant/user-scripts/raw/replicant-6.0/networking/usb/usb_networking_device.sh
8 1 Wolfgang Wiedmeyer
Make sure to have [[ADB]] installed and to have the host daemon running as root.
9
10 5 Wolfgang Wiedmeyer
h3. Preparing the device
11 1 Wolfgang Wiedmeyer
12 5 Wolfgang Wiedmeyer
Push the script on the device, make it executable and run the first part of the script:
13
14 1 Wolfgang Wiedmeyer
<pre>
15 4 Wolfgang Wiedmeyer
adb push usb_networking_device.sh /data/
16
adb shell chmod a+x /data/usb_networking_device.sh
17 1 Wolfgang Wiedmeyer
adb shell /data/usb_networking_device.sh start1
18
</pre>
19
20 5 Wolfgang Wiedmeyer
h3. Setting up the connection on the PC
21 1 Wolfgang Wiedmeyer
22 5 Wolfgang Wiedmeyer
The network manager applet on your PC (usually accessible through the network icon on your taskbar) should now display the device as a new wired interface. Below the name of the device should be a list of available connections. Depending on your network configuration, the list might be empty or offers one or more entries.
23
24
If your PC is connected to the Internet via Ethernet, a connection with the name "Auto-Ethernet" or a similar name could be available. Selecting this option should be enough to configure the connection and you can skip most of the steps below and continue with step 5. If there are issues with your connection, you will have to start again and do the rest of the steps, too.
25
26
If your PC uses Wi-Fi and Ethernet-based connections are suggested for your device, selecting one of them will likely not work. You will have to set up a new Ethernet-based connection.
27
28
The following steps are required to set up a new network connection for the device:
29
30
1. In the network manager applet, create a new "Ethernet" or "Wired" connection.
31
2. In the tab for IPv4 settings, select the method "Shared to other computers".
32
3. Save the connection, preferably with a distinguishable name
33
4. Select this connection for your device.
34 3 Wolfgang Wiedmeyer
5. Now run the second part of the script on the device:
35 1 Wolfgang Wiedmeyer
36 4 Wolfgang Wiedmeyer
<pre>
37 1 Wolfgang Wiedmeyer
adb shell /data/usb_networking_device.sh start2
38
</pre>
39
40 5 Wolfgang Wiedmeyer
The connection should now work.
41 1 Wolfgang Wiedmeyer
42 5 Wolfgang Wiedmeyer
The new connection is saved on your PC and you don't have to recreate it when connecting the device again. It is then only necessary to run the first part of the script, selecting the network connection for the device in case it is not auto-selected and to run the second part of the script.
43
44
h3. Stopping the network connection
45
46
To disconnect the device, run:
47
48 1 Wolfgang Wiedmeyer
<pre>
49
adb shell /data/usb_networking_device.sh stop
50
</pre>
51 4 Wolfgang Wiedmeyer
52 1 Wolfgang Wiedmeyer
h3. Known issues
53 4 Wolfgang Wiedmeyer
54 5 Wolfgang Wiedmeyer
Some apps won't connect to the Internet if cellular data is disabled. This also affects the latest version of F-Droid (see "this issue":https://gitlab.com/fdroid/fdroidclient/issues/816). A workaround is to enable cellular data before doing the configuration steps for usb tethering. The previously described configuration steps will overwrite the cellular data connection and the connection via USB tethering will be used.
55
56
If you are not able to enable cellular data, you will have to downgrade F-Droid to version 0.101 to make it usable.