Android Debug Bridge (adb)

To improve usability and user experience of the system remap some of the keys of the Logitech Harmony Remote and the Logitech Keyboard. Note that the Mi Box S bluetooth remote is compatible with the NVIDIA Shield remote, which we will use when setting up the Harmony Remote.

  1. To install adb on your computer, follow How to install ADB on Windows, macOS, and Linux (beginner's guide) and read Android Debug Bridge (adb) (Android adb documentation). You will need it to interact with your device in the following cases:
    • change settings, for example when using the Button Mapper
    • copy files and folders into an apps restricted storage space
  2. Enable USB debugging in Settings –> Device Preferences –> Developer options. You might need to Revoke USB debugging authorizations first if the device does not prompt you to allow connections from your computer.
  3. Connect and disconnect to the device on default port 5555
    adb connect <IP address>
    adb disconnect
    exit
  4. You will need to confirm the connection on your device the first time you connect
  5. List connected devices with
    adb devices -l
  6. Make sure there is only one device listed, otherwise you need to specify the device the command should be sent to for every adb command
  7. To create a folder and copy a file to it, follow the example of adding a font file to kodi's settings directory, the file system path of /storage/emulated/0/ can usually be accessed with the alias /sdcard/ and is equivalent to Main Storage/:
    adb shell mkdir -p /sdcard/Android/data/org.xbmc.kodi/files/.kodi/media/Fonts
    adb push <fontfile> /sdcard/Android/data/org.xbmc.kodi/files/.kodi/media/Fonts/
  8. To copy an entire folder from your computer to the device copy the folder with a file manager app to a location on your device outside of the restricted app storage, for example /sdcard/Download/. After that open a adb shell and move the folder to the app storage space, here I use as example a custom skin folder for Kodi:
    adb shell
    $ cd /sdcard/Android/data/org.xbmc.kodi/files/.kodi/addons/
    $ mv /sdcard/Download/skin.estuary.custom .
    $ exit
  9. I'm using FX file manager which is available for Android TV. The paid version (3 USD) allows to copy from a network path which is great as you don't need to continuously plug and unplug a USB drive.