Closed AxelLin closed 11 months ago
Thanks for opening the issue! We have merged the fix for it yesterday, should appear on Github soon. Merge commit ID will be 8545f8595f2591e1d172e127e13d2eb0f6145149. Will backport to release/v5.1 as well.
BTW, I hit another build error when try to compile with esp-idf-lib.
/home/axel/esp/esp-idf-dev/esp-idf-lib/components/mhz19b/mhz19b.c:64:23: error: 'UART_SCLK_APB' undeclared (first use in this function); did you mean 'UART_SCLK_RTC'?
64 | .source_clk = UART_SCLK_APB,
| ^~~~~
| UART_SCLK_RTC
I'm not sure if this is esp-idf-lib issue or esp-idf issue. (UART_SCLK_APB does not exist for esp32c6 target.)
The reference to UART_SCLK_APB is in esp-idf-lib, so yes, i think it's an issue there: https://github.com/UncleRus/esp-idf-lib/blob/15c4da67ef7ec713d9ab6d87c54c4445742620f8/components/mhz19b/mhz19b.c#L63-L65. I think it can be changed to UART_SCLK_DEFAULT.
@igrr I don't think this was uploaded to github yet, correct? Any ETA? or can you explain how can I fix it locally so I can continue developing?
FYI, I also got below warnings when CONFIG_ESP_CONSOLE_UART_DEFAULT=n with 5.1 branch.
Building C object esp-idf/console/CMakeFiles/__idf_console.dir/esp_console_repl.c.obj/home/axel/esp/esp-idf/components/console/esp_console_repl.c:479:13: warning: 'esp_console_repl_task' defined but not used [-Wunused-function]
479 | static void esp_console_repl_task(void *args)
| ^~~~~~~~~~~~~~~~~~~~~
/home/axel/esp/esp-idf/components/console/esp_console_repl.c:375:18: warning: 'esp_console_common_init' defined but not used [-Wunused-function]
375 | static esp_err_t esp_console_common_init(size_t max_cmdline_length, esp_console_repl_com_t *repl_com)
| ^~~~~~~~~~~~~~~~~~~~~~~
/home/axel/esp/esp-idf/components/console/esp_console_repl.c:354:18: warning: 'esp_console_setup_history' defined but not used [-Wunused-function]
354 | static esp_err_t esp_console_setup_history(const char *history_path, uint32_t max_history_len, esp_console_repl_com_t *repl_com)
| ^~~~~~~~~~~~~~~~~~~~~~~~~
/home/axel/esp/esp-idf/components/console/esp_console_repl.c:329:18: warning: 'esp_console_setup_prompt' defined but not used [-Wunused-function]
329 | static esp_err_t esp_console_setup_prompt(const char *prompt, esp_console_repl_com_t *repl_com)
| ^~~~~~~~~~~~~~~~~~~~~~~~
Thanks for opening the issue! We have merged the fix for it yesterday, should appear on Github soon. Merge commit ID will be 8545f85. Will backport to release/v5.1 as well.
Just remind v5.1 branch still needs fix.
Thanks for opening the issue! We have merged the fix for it yesterday, should appear on Github soon. Merge commit ID will be 8545f85. Will backport to release/v5.1 as well.
Just remind v5.1 branch still needs fix.
@igrr Recent v5.1 update does not include this fix, I'm wondering if it's missed? I hope a compile fix can be applied asap.
@AxelLin You are right, sorry, I couldn't get it merged yet due to some of the tests failing... I was looking at this yesterday, hope to get this resolved soon.
This has been backported to release/v5.1 in https://github.com/espressif/esp-idf/commit/a803c846aaacbc60d3fa5b3d45059616312d65a4.
Answers checklist.
IDF version.
v5.1.1-439-gcb174b0fe1
Operating System used.
Linux
How did you build your project?
Command line with idf.py
If you are using Windows, please specify command line type.
None
What is the expected behavior?
build ok.
What is the actual behavior?
Build error if hitting below settings:
idf.py set-target esp32c6
Using below config:
CONFIG_ESP_CONSOLE_UART_DEFAULT is not set
CONFIG_ESP_CONSOLE_USB_SERIAL_JTAG=y
CONFIG_ESP_CONSOLE_UART_CUSTOM is not set
CONFIG_ESP_CONSOLE_NONE is not set
CONFIG_ESP_CONSOLE_SECONDARY_NONE=y
~~~~~~~ /home/axel/esp/esp-idf/components/esp_hw_support/sleep_modes.c:478:113: note: in expansion of macro 'UART_FLUSH_US_PER_CHAR' 478~~~~~ /home/axel/esp/esp-idf/components/esp_hw_support/sleep_modes.c:152:61: note: each undeclared identifier is reported only once for each function it appears in 152~~~~~~~ /home/axel/esp/esp-idf/components/esp_hw_support/sleep_modes.c:478:113: note: in expansion of macro 'UART_FLUSH_US_PER_CHAR' 478Also note, got below error if build with idf.py set-target esp32c3:
/home/axel/esp/esp-idf/examples/system/light_sleep/main/uart_wakeup.c: In function 'uart_initialization': /home/axel/esp/esp-idf/examples/system/light_sleep/main/uart_wakeup.c:100:23: error: 'CONFIG_ESP_CONSOLE_UART_BAUDRATE' undeclared (first use in this function); did you mean 'CONFIG_ESP_CONSOLE_UART_NUM'? 100 | .baud_rate = CONFIG_ESP_CONSOLE_UART_BAUDRATE, | ^
~~~~~~~ | CONFIG_ESP_CONSOLE_UART_NUMSteps to reproduce.
build examples/system/light_sleep with below settings:
CONFIG_ESP_CONSOLE_UART_DEFAULT is not set
CONFIG_ESP_CONSOLE_USB_SERIAL_JTAG=y
CONFIG_ESP_CONSOLE_UART_CUSTOM is not set
CONFIG_ESP_CONSOLE_NONE is not set
CONFIG_ESP_CONSOLE_SECONDARY_NONE=y
Build or installation Logs.
No response
More Information.
No response