如何使用adb唤醒Android - 我想在调试每个新版本的应用程序之前唤醒(如果睡着了)Android终端.
典型的流程是:1.我在Eclipse中做了一些更改.2.在此期间屏幕是否熄灭.我运行"调试"并想要强制屏幕唤醒.
我发现了一种带有"电源键"仿真的方法,但它没有将其打开,而是切换电源状态.我不想在我的应用程序中添加额外的代码.有什么其他方法可以做这么琐碎的任务,请帮忙.
由于AndroidStudio更新2.2,我的本机代码应用程序启动需要很长时间(我看到一个空白屏幕约20秒).
我的猜测是,这是因为c ++调试器需要很长时间才能解决.
可以禁用它(并且只使用好的旧java调试器)吗?
在调试应用程序并在断点处停止时,Android会反复显示"<应用程序>没有响应.是否要关闭它?" 带有"等待"和"确定"选项的对话框.有没有办法在调试应用程序时禁用它们?
从Java断点恢复后,即使我与调试器断开连接,甚至拔掉USB电缆,我的Android应用程序也会运行缓慢(几乎冻结)。在尝试过的每台设备和模拟器上,我都会得到相同的行为。在达到第一个断点之前,性能一直很好,但是恢复后就无法使用了,必须将其杀死。非常令人沮丧。
它曾经很不错,但是它始于Android Studio 3.1.x,在我升级到3.2.1,然后是当前最新的稳定版本3.3.2之后,它仍然在发生。在同一个应用程序上工作的我的同事都没有这个问题,因此可能不是代码。我怀疑我在某处有配置问题。
我不知道开始时发生了什么变化。无论断点在哪里,它都会发生。我在LogCat中没有看到任何错误。
我正在使用运行OSX 10.13.6的MacBook Pro(15英寸,2017年),运行Studio P的Android Studio 3.3.2和运行P的Pixel XL。还有运行P的各种模拟器。
任何想法或建议,不胜感激。
注意:它发生在Java断点上,但不是在Kotlin上。
注意:我无法使用简单的默认应用程序进行复制,因此它是特定于项目的,但仅在我的计算机上。
在迁移我的某个应用程序以使用Android 6.0权限系统时,我发现使用模拟器调试权限非常困难.
发现:
requestPermissions()方法时,禁用应用信息屏幕中的权限不会重新显示授予权限对话框.使用Android模拟器调试权限的正确方法是什么?
android android-permissions android-debug android-6.0-marshmallow runtime-permissions
我已经构建了一个运行良好的Android应用程序,正如预期的平板电脑:Acer.7英寸API 21.
我最近买了一台新平板电脑:宏基.10英寸API 22.
现在,我正在使用此行发送垃圾邮件.
04-12 18:23:27.371 8776-9082/com.callbell.callbell D/Surface: Surface::setBuffersDimensions(this=0x7f9aa44000,w=800,h=1280)
Run Code Online (Sandbox Code Playgroud)
并且屏幕将以随机间隔冻结并变为空白.我没有在日志中看到任何错误,我可以找到这个日志行的唯一参考
更新 我在一些设备上尝试过这种方法并取得了不同的成功.
没有问题:
三星Galaxy Tab 7"
三星Galaxy Tab 10"
宏碁Iconia 8"
问题:
宏碁Iconia 10"
我通过下载库,将其添加到工作区,然后将其作为库引用,使Google Maps Android API v2在我的Android应用程序上完美运行.
但是一旦包含Map Fragment的活动开始,我仍然会收到此错误
Could not find class 'maps.i.k', referenced from method maps.z.ag.a
Run Code Online (Sandbox Code Playgroud)
顺便说一下,我正在使用支持地图片段
这个错误似乎不会影响我,也不会崩溃应用程序或任何东西,我是否应该费心修复它?
添加了清单 PS E_SelectJourney是我显示和使用地图的地方
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.HelloMap.AndroidApp"
android:versionCode="1"
android:versionName="1.0" >
<uses-sdk
android:minSdkVersion="8"
android:targetSdkVersion="17" />
<uses-feature
android:glEsVersion="0x00020000"
android:required="true" />
<permission
android:name="com.HelloMap.AndroidApp.permission.MAPS_RECEIVE"
android:protectionLevel="signature" />
<uses-permission android:name="com.HelloMap.AndroidApp.permission.MAPS_RECEIVE" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="com.google.android.providers.gsf.permission.READ_GSERVICES" />
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.GET_ACCOUNTS" />
<application
android:allowBackup="true"
android:configChanges="orientation"
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"
android:screenOrientation="portrait"
android:theme="@style/Theme.Sherlock" >
<uses-library
android:name="com.google.android.maps"
android:required="true" />
<activity
android:name="com.HelloMap.AndroidApp.A_SplashScreen" …Run Code Online (Sandbox Code Playgroud) android android-maps android-library google-maps-mobile android-debug
我使用Visual Studio 2015 RC在我的Samsung Galaxy S5上构建和调试Android应用程序.今天我从android 4.3更新到5.0,调试停止工作.这是我得到的信息:

谁知道如何解决这个问题?
debugging android visual-studio android-debug vs-2015-preview
我正在玩我的平板电脑并测试我的程序,当有通知表明已经捕获了错误报告以及我是否愿意分享它.之前我没有看过这条消息所以我点击了Yes,然后我在警告对话框中单击了OK,要求我只与我信任的人分享.之后打开了gmail应用程序,其中包含我的平板电脑的屏幕截图,以及附加到其上的文件bugreport<some numbers, date and time I think>.txt.我没有发送错误报告,因为我不确定它是什么以及它会去哪里.不过我的问题是,
这个错误报告究竟是什么?
它是由我测试的代码生成的吗?或者它是由android系统本身生成的?
当我按下硬件按钮时,我是否在不知不觉中触发了某些内容(平板电脑只有3个硬件按钮,音量增大/减小和电量)?
我一直在尝试,但我无法再显示该消息,当我使用我的文件查看器应用程序搜索bug*.txt时,我找不到该文件.哪个附加到错误报告的.txt文件保存在我的平板电脑上?
我想在模拟器上运行我的应用程序.它曾经工作,但现在它没有正确加载.我得到的调试错误是:
static = libcore.io.Posix
Exception = {android.system.ErrnoException@3564}
Run Code Online (Sandbox Code Playgroud)
当我右键单击Exception行和Copy Value时,我得到:
android.system.ErrnoException: stat failed: ENOENT (No such file or directory)
Run Code Online (Sandbox Code Playgroud)
我的应用程序没有任何编程的文件,因此异常必须与系统所需的内容相关.
回顾一下LogCat,我得到了ENOENT的匹配,以前的几行是:
com.google.process.location W/art? Suspending all threads took: 7.795ms
com.google.process.location I/art? Background partial concurrent mark sweep GC freed 2094(165KB) AllocSpace objects, 0(0B) LOS objects, 40% free, 3MB/5MB, paused 9.486ms total 274.854ms
com.google.process.location I/GCoreUlr? DispatchingService.onCreate()
com.google.process.location I/GCoreUlr? WorldUpdater received intent Intent { act=com.google.android.location.reporting.ACTION_UPDATE_WORLD cmp=com.google.android.gms/com.google.android.location.reporting.service.DispatchingService (has extras) } with receiverAction android.location.PROVIDERS_CHANGED
com.google.process.location E/copresGcore? Couldn't load settings: /data/data/com.google.android.gms/files/copresence_settings: open failed: ENOENT (No such file or …Run Code Online (Sandbox Code Playgroud)