2

I have an application installed on an android tv-box. is it possible to get logcat readings from the tv box through a logcat reader app? I'm hoping there is an app I can install on my mobile phone and once plugging the phone to the tv box I will be able to get logcat readings.

Am I dreaming or there is such a thing?

Bhargav Rao
  • 50,140
  • 28
  • 121
  • 140
Saeed Joul
  • 244
  • 2
  • 15
  • If you plug your development machine into the Android TV device, you can use ordinary development tools, like Android Studio. The Android SDK will allow you to view the contents of Logcat from a debuggable device. – CommonsWare Jul 27 '19 at 11:35
  • @CommonsWare ya thats what I currently do. But TV boxes will be installed in multiple locations and at some locations it wont be practical to use my laptop. I was hoping for something with better mobility such as a mobile phone. – Saeed Joul Jul 27 '19 at 11:37

1 Answers1

2

To get logs from the TV you need to use ADB over TCP/IP.

  1. Enable Developer options: Press Home and select Settings. In the TV row, select About. Scroll down to and click on Build several times until a dialog appears with the message "You are now a developer" appears.
  2. Enable Debugging: Press Home and go back into the Settings menu. In the System Preferences row, select Developer options, select Debugging, select ADB Debugging, select On.
  3. Find the TV IP address: Press Home and select Network Settings.
  4. Make sure your TV and your computer are connected to the same local network.
  5. On your computer, open a terminal and type: adb connect <IP address of your TV>
  6. In the Allow debugging? dialog, select Always allow from this computer and select OK.
  7. You can verify the connection is established by typing: adb devices
  8. To get a log, type: adb logcat
GOVIND DIXIT
  • 1,748
  • 10
  • 27