简体   繁体   English

通过uart的esp32 printf通道(esp-idf)

[英]esp32 printf channel through uart (esp-idf)

I try to disable all logs on my program, I did disable esp logs but when I use printf in my channel and open make monitor printf still works. 我尝试禁用程序上的所有日志,但确实禁用了esp日志,但是当我在通道中使用printf并打开make monitor printf仍然可以使用。

how and why? 如何以及为什么? I want to disable it. 我要禁用它。

The system logs and printf are two different things over here. 系统日志和printf是这里的两件事。 In your project sdkconfig file check if the parameter ' CONFIG_CONSOLE_UART_DEFAULT ' is set. 在项目sdkconfig文件中,检查是否设置了参数“ CONFIG_CONSOLE_UART_DEFAULT ”。

This defines where all your console outputs are dumped into. 这定义了所有控制台输出转储到的位置。

In your case you want to disable all the printf logs, you can try setting ' CONFIG_CONSOLE_UART_NONE =y'. 如果要禁用所有printf日志,可以尝试设置' CONFIG_CONSOLE_UART_NONE = y'。

If you are doing it thourgh make menuconfig of esp-idf, it will come under - component config > ESP32-Specific > UART for console output (Default: UART0, TX=GPIO1, RX=GPIO3) > None 如果您正在执行esp-idf的menuconfig设置,它将位于- 组件配置> ESP32特定>控制台输出的UART(默认值:UART0,TX = GPIO1,RX = GPIO3)>无

Hope I answered to your question. 希望我回答了你的问题。 :) :)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM