Tuesday, April 23, 2013

Enabling Android Logcat on a Huawei Smartphone

Getting your debug to work on a Huawei smartphone is a bit tricky, since the LogCat is disabled by default for (useless) security reasons.

First of all, to enable the LogCat you must take all the usual steps to debug an Android app on a real device under Eclipse. Then, you must take the following further steps to get the work done:


  1. on the smartphone press the number *#*#2846579#*#* which will show you a secret menu, quite common to find on android devices;
  2. choose ProjectMenu >> Background setting >> Log setting;
  3. now you will see 2 entries: "Log switch" and "Log level setting"; just choose the second one to set the minimum debugging level shown and confirm on the popup dialog, then choose "Log ON" on the first entry and confirm again;
  4. reboot the device.

Connect the Huawei to your PC via USB and... ta-daa! Eclipse will show you the LogCat.

Have fun!