Libimobiledevice: Difference between revisions
imported>Onny No edit summary |
mNo edit summary |
||
| (11 intermediate revisions by 6 users not shown) | |||
| Line 1: | Line 1: | ||
{{DISPLAYTITLE:libimobiledevice}} | |||
The [https://libimobiledevice.org/ libimobiledevice] project provides libraries and tools to connect and transfer data between iOS devices and Linux machines. | |||
== Usage == | == Usage == | ||
In order to be able to automatically mount your iOS device (such as an iPhone) when connecting it, you need to install <code>libimobiledevice</code> and to activate the <code>usbmuxd</code> service. | === Preparation === | ||
In order to be able to automatically mount your iOS device (such as an iPhone) when connecting it or to enable USB tethering, you need to install <code>libimobiledevice</code> and to activate the <code>usbmuxd</code> service. | |||
Add the following to your <code>configuration.nix</code>: | Add the following to your <code>configuration.nix</code>: | ||
| Line 8: | Line 12: | ||
<syntaxhighlight lang="nix"> | <syntaxhighlight lang="nix"> | ||
services.usbmuxd.enable = true; | services.usbmuxd.enable = true; | ||
environment.systemPackages = with pkgs; [ | environment.systemPackages = with pkgs; [ | ||
libimobiledevice | libimobiledevice | ||
| Line 14: | Line 19: | ||
</syntaxhighlight> | </syntaxhighlight> | ||
If you experience issues mounting or pairing your device (for example as described [https://github.com/NixOS/nixpkgs/issues/152592 here]), you can try to switch the <code>usbmuxd</code> daemon package to an alternative more updated implementation, <code>usbmuxd2</code>. | |||
<syntaxhighlight lang="nix"> | |||
services.usbmuxd = { | |||
enable = true; | |||
package = pkgs.usbmuxd2; | |||
}; | |||
</syntaxhighlight> | |||
=== Mounting === | |||
Mounting the device via iFuse is possible with the following commands | |||
<syntaxhighlight> | <syntaxhighlight> | ||
$ mkdir /tmp/iphone | $ mkdir /tmp/iphone | ||
$ ifuse /tmp/iphone | $ ifuse /tmp/iphone | ||
</syntaxhighlight> | </syntaxhighlight> | ||
=== Tethering === | |||
Tethering on iOS is possible via Wifi hotspot, Bluetooth or USB. In order to enable USB tethering, first enable tethering in the iOS networking settings. After that run following command | |||
<syntaxhighlight> | <syntaxhighlight> | ||
$ | $ idevicepair pair | ||
</syntaxhighlight> | </syntaxhighlight> | ||
== | Confirm pairing by accepting the connection on your iOS device. After that an ethernet device will appear in your network device list. | ||
== Maintenance == | |||
=== Factory reset === | === Factory reset === | ||