如何在 Huawei MediaPad M3 上启用 logcat 输出

How to enable logcat output on Huawei MediaPad M3

MediaPad M3 不会记录与我正在开发的应用程序相关的任何内容(与其他 Android 设备相比)。据我所知,通常可以通过隐藏菜单在华为设备上设置日志级别。

我在搜索解决方案时多次遇到这些说明:https://gist.github.com/Shallong11/8403487

但是,这是一个表格,不支持 GSM 和拨号器/Phone 应用程序。所以我在第一步失败了:拨打 ##2846579##.

更新 #1:我已经尝试了此处列出的所有内容:https://android.stackexchange.com/questions/59259/typing-dialer-secret-codes-in-devices-other-than-phones 什么都不管用。我得到的唯一反应是:使用 Intent.ACTION_DIAL 的 startActivity 调用由联系人应用程序处理。很奇怪有联系人应用程序但没有拨号器...

添加显示调试日志但不显示应用程序崩溃的堆栈跟踪可能有意义。

更新#2:我也试过其中一些密码;没有任何作用:http://mobilespecs.net/phone/codes/Huawei/Huawei_MediaPad_M2.html

因为平板没有拨号盘,横向打开计算器,输入 "()()2846579()()=" 隐藏菜单应该会出现。

Here's a video demonstration.

另请注意,之后您需要重启设备才能应用更改。