如何在Android user 版本下打开UART log
1个回答
推荐于2016-10-05 · 知道合伙人数码行家
huanglenzhi
知道合伙人数码行家
向TA提问 私信TA
知道合伙人数码行家
采纳数:117538
获赞数:517201
长期从事计算机组装,维护,网络组建及管理。对计算机硬件、操作系统安装、典型网络设备具有详细认知。
向TA提问 私信TA
关注
展开全部
如果为了调试
1. 打开一个文件:
alps/mediatek/config/common/autoconfig/kconfig/USER
查看是否存在CONFIG_COMLINE=”console=ttyMT3,921600n1 loglevel=0”,如果存在,则把loglevel=0修改为loglevel = 8
然后
./mk n k
./mk bootimage
2. 如不存在CONFIG_COMMLINE,则查看alps/bootable/bootloader/lk/app/mt_boot/mt_boot.c的boot_linux()函数:
if (!has_set_p2u) {
#ifdef USER_BUILD
sprintf(cmdline,"%s%s",cmdline," printk.disable_uart=1");
#else
sprintf(cmdline,"%s%s",cmdline," printk.disable_uart=0");
#endif
}
修改为:
if (!has_set_p2u) {
#ifdef USER_BUILD
sprintf(cmdline,"%s%s",cmdline," printk.disable_uart=0 ignore_loglevel");
#else
sprintf(cmdline,"%s%s",cmdline," printk.disable_uart=0");
#endif
}
1. 打开一个文件:
alps/mediatek/config/common/autoconfig/kconfig/USER
查看是否存在CONFIG_COMLINE=”console=ttyMT3,921600n1 loglevel=0”,如果存在,则把loglevel=0修改为loglevel = 8
然后
./mk n k
./mk bootimage
2. 如不存在CONFIG_COMMLINE,则查看alps/bootable/bootloader/lk/app/mt_boot/mt_boot.c的boot_linux()函数:
if (!has_set_p2u) {
#ifdef USER_BUILD
sprintf(cmdline,"%s%s",cmdline," printk.disable_uart=1");
#else
sprintf(cmdline,"%s%s",cmdline," printk.disable_uart=0");
#endif
}
修改为:
if (!has_set_p2u) {
#ifdef USER_BUILD
sprintf(cmdline,"%s%s",cmdline," printk.disable_uart=0 ignore_loglevel");
#else
sprintf(cmdline,"%s%s",cmdline," printk.disable_uart=0");
#endif
}
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询