You can update this text in your control panel, under Theme Options. Nam massa. Ut tempor augue non sapien lobortis aliquam. Maecenas.

Reading the logs of Android on your computer

August 16th, 2009

Sometimes i need to see the system log from my android mobile. As root on android i can see this in the terminal with dmesg. But i want to see it on my desktop computer.

The Android SDK has the solution. Simple setup adb to work proper and then type adb logcat in the desktop shell. (be warned this put large text message in your shell)

[android@fedora android]$ ./adb logcat
V/WifiMonitor( 1075): Event [CTRL-EVENT-STATE-CHANGE id=1 state=7]
V/WifiStateTracker( 1075): Changing supplicant state: GROUP_HANDSHAKE ==> COMPLETED
D/dalvikvm( 1360): GC freed 611 objects / 28528 bytes in 193ms
D/dalvikvm( 1360): GC freed 558 objects / 26376 bytes in 188ms
D/dalvikvm( 1360): GC freed 523 objects / 24848 bytes in 495ms
V/GameService( 1430): mobi.sportstap.provider.schedule.ACTION_SCHEDULE_ALARM
V/GameService( 1430): RefreshSchedule
V/GameService( 1430): mobi.sportstap.provider.schedule.ACTION_AUDIT_ALARM
V/GameService( 1430): game update alarm set
V/GameService( 1430): schedule refresh alarm set: 16 Aug 2009 15:50:13 GMT
V/ScheduleBroadcastReceiver( 1430): Intent received: mobi.sportstap.broadcast.widget.APPWIDGET_NO_NET
D/dalvikvm( 1430): GC freed 669 objects / 37848 bytes in 188ms
[... and so on]

To stop type STRG+C. The command adb logcat > log_android.txt generate a textfile with the log messages.

Tags: , , , , ,

4 Responses to Reading the logs of Android on your computer

  1. Johan says:

    You can actually type “lolcat” instead of “logcat” :P someone on Google was a bit bored i think.

    And if you want timestamps, write “adb logcat -v time”, and another way to pipe the output is to do “adb logcat -f /sdcard/log_blabla”, but it has to be a path on the device :)
    “adb logcat -c” clears the buffer from messages.

  2. koy says:

    DDMS will also give you this, but slightly clearer to read ;)

  3. Steffen Lindner says:

    Thanks for your tips. Especially for lolcat :-)

Leave a Reply

Name and Email Address are required fields. Your email will not be published or shared with third parties.