问题描述
如何运行 systrace
来显示它的HTML输出?看着谷歌I / O 2012的谈话黄油或更糟后我有麻烦 systrace
使用运行果冻豆4.1模拟器在Windows 7上工作
How can I run systrace
to show its html output? After watching the Google I/O 2012 talk "For Butter or Worse" I am having trouble getting systrace
to work on Windows 7 using the emulator running Jelly Bean 4.1.
我做了以下内容:
- 在安装了Python 2.7,并增加了安装文件夹到我的PATH
- 冉以下内容:
C:\ Android的SDK \平台工具\ systrace>蟒蛇systrace.py
(与旧的软件开发工具包:C: \ Android的SDK \工具\ systrace>蟒蛇systrace.py
)
- Installed Python 2.7, and added the install folder to my PATH
- Ran the following:
C:\android-sdk\platform-tools\systrace>python systrace.py
(with older SDKs:C:\android-sdk\tools\systrace>python systrace.py
)
但我得到在cmd中出现以下错误:
But I get the following error in cmd:
Traceback (most recent call last):
File "systrace.py", line 212, in <module>
main()
File "systrace.py", line 124, in main
ready = select.select([adb.stdout, adb.stderr], [], [adb.stdout, adb.stderr])
select.error: (10093, 'Either the application has not called WSAStartup, or WSAStartup failed')
请注意:
- 我已经启用了模拟器的痕迹:
设置&gt;开发人员选项&gt;启用痕迹
- 我也尝试过使用Python 3.2
推荐答案
在systrace python脚本使用select()系统调用,并且不能在Windows工作。的Android的SDK工具的最新preVIEW (ADT21 RC9)包括从内部收集系统跟踪支持监视工具。
The systrace python script uses the select() system call, and that doesn't work on Windows.The latest preview (ADT21 rc9) of the Android SDK tools include support for collecting system trace from within the monitor tool.
发射显示器为:
./tools/monitor &
点击的设备上,并在设备面板的右上方,你应该有一个工具栏itemn,使您可以收集系统跟踪。
Click on a device, and at the top right of the device panel, you should have an toolbar itemn that allows you to collect system trace.
这篇关于使用果冻豆4.1仿真器上运行Windows 7 systrace工具亚行错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!