Android Debugging
Debugging methods for Android
Contents
[hide]
Debuggers
Kernel and User co-debug with GDB on Android
This presentation covers lots of Android debug resources provided by Linaro, presented by Zach Pfeffer in Spring 2012. Included is information about how to debug kernel and user simultaneously with gdb.
See Media:Zach Pfeffer Next Gen Android 2012.pdf
loggers
kernel message log
The Linux kernel has a message log in an internal ring buffer. You can access the contents of this log using the 'dmesg' command.
You can add timing information to the printk messages, by adding "time" to the Linux kernel command line.
init logging
The Android init program outputs some messages to the kernel log, as it starts the system. You can increase the verbosity of init, using the "loglevel" command in the /init.rc file.
The default loglevel is 3, but you can change it to 8 (the highest) by changing the following line in the /init.rc file. Change:
loglevel 3
to
loglevel 8
Android logging system
The Android application framework has a built-in logging system, which goes through a special driver in the kernel. It is described at:http://developer.android.com/guide/developing/tools/adb.html#logcat
Note that although the log dumper (logcat) is described on the Android developer site on the 'adb' page, there is a native logcat command included in the Android distribution (that is, available on the target file system, which can be run locally).
tracers
strace
You can use strace on Android. It is included in the Android open source project (at least as of Android 2.1), and appears to be automatically installed in engineering builds of the software.
To use strace during early initialization, you can put it in the /init.rc file. For example, to trace zygote initialization, change the following line in /init.rc.
service zygote /system/bin/app_process -Xzygote /system/bin --zygote --start-system-server
should be changed to:
service zygote /system/xbin/strace -tt -o/data/boot.strace /system/bin/app_process -Xzygote /system/bin --zygote --start system-server
Dalvik Method Tracer
See http://developer.android.com/guide/developing/tools/traceview.html
Android Debugging的更多相关文章
- android Can't bind to local 86XX for debugger
For some reason eclipse DDMS always gives the error 'Can't bind to local 86XX for debugger' every ti ...
- 北京联想招聘-Android Framework高级工程师(7-10年) 加入qq 群:220486180 或者直接在此 留言咨询
Job ID #: 45038 Position Title: Android Framework高级工程师 Location: CHN-Beijing Functional Area: Resear ...
- Android Platform Guide
This guide shows how to set up your SDK environment to deploy Cordova apps for Android devices, and ...
- Introducing Visual Studio’s Emulator for Android
visual studio 2015支持Android开发了. Microsoft released Visual Studio 2015 Preview this week and with it ...
- Android开源项目收集
软件名:gaeproxy软件作用:Android手机配置GoAgentFQ.项目地址:https://github.com/madeye/gaeproxy.git 软件名:ProxyDroid软件作用 ...
- Backup your Android without root or custom recovery -- adb backup
ecently discovered a neat new way to back up apps on my Android without having to use Titanium Backu ...
- Android平台上优秀的开源项目
软件名:gaeproxy 软件作用:Android手机配置GoAgent. 项目地址:https://github.com/madeye/gaeproxy.git 软件名:ProxyDroid 软件作 ...
- [Call Vibrator] How to Enable Outgoing Call Vibration without ROOT
Call Vibrator requires the radio log of phone to detect when outgoing call is answered. But since An ...
- OnePlus安装Kali-NetHunter
1.关于 Kali NetHunter Kali NetHunter 是一款由 Offensive Security 团队研发设计的,以 Nexus(手机/平板)为基本 硬件设备,基于原生 Andro ...
随机推荐
- Eclipse字体大小设置
打开Eclipse,在主界面下Window->Preferences->General->Appearance->Colors and Fonts, 然后在右边展开框Basic ...
- ansible 使用方法
免密钥方式登陆: [root@yizhen ~]# ssh-keygen -t rsa[root@yizhen ~]# ssh-copy-id -i ~/.ssh/id_rsa.pub 192.168 ...
- hdu2923 最短路floyd
建图还是有点烦人的. #include<map> #include<string> #include<stdio.h> #include<iostream&g ...
- 【UVALive 3905】BUPT 2015 newbie practice #2 div2-D-3905 - Meteor
http://acm.hust.edu.cn/vjudge/contest/view.action?cid=102419#problem/D The famous Korean internet co ...
- Yii2.0 对数据库 查询的简单操作
User::find()->all(); 此方法返回所有数据: User::findOne($id); 此方法返回 主键 id=1 的一条数据(举个例子): User::find()->w ...
- TCP和Http的区别
相信不少初学手机联网开发的朋友都想知道Http与Socket连接究竟有什么区别,希望通过自己的浅显理解能对初学者有所帮助. 1.TCP连接 手机能够使用联网功能是因为手机底层实现了TCP/IP协议,可 ...
- DLUTOJ 1033 Matrix
传送门 Time Limit: 2 Sec Memory Limit: 128 MB Description We often use the matrix to analyze reality m ...
- hihocoder 1154 Spring Outing
传送门 #1154 : Spring Outing 时间限制:20000ms 单点时限:1000ms 内存限制:256MB 描述 You class are planning for a spring ...
- HDU 2242 考研路茫茫----空调教室
传送门 考研路茫茫——空调教室 Time Limit: 4000/2000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)T ...
- POJ2299Ultra-QuickSort(归并排序 + 树状数组求逆序对)
树状数组求逆序对 转载http://www.cnblogs.com/shenshuyang/archive/2012/07/14/2591859.html 转载: 树状数组,具体的说是 离散化+树 ...