编译usb_cdc_4g_module工程示例出现找不到函数的错误?紧急!!

Moderator: ESP_Bob

linshc
Posts: 59
Joined: Mon Feb 21, 2022 2:06 am

编译usb_cdc_4g_module工程示例出现找不到函数的错误?紧急!!

Postby linshc » Fri Apr 29, 2022 3:14 am

D:/esp/esp-iot-solution-usb-add_usb_solutions/components/usb/esp_usbh_cdc/esp_usbh_cdc.c: In function '_usb_get_dev_desc':
D:/esp/esp-iot-solution-usb-add_usb_solutions/components/usb/esp_usbh_cdc/esp_usbh_cdc.c:703:5: error: implicit declaration of function 'usb_print_device_descriptor'; did you mean 'usb_print_descriptors'? [-Werror=implicit-function-declaration]
usb_print_device_descriptor(dev_desc);
^~~~~~~~~~~~~~~~~~~~~~~~~~~
usb_print_descriptors
D:/esp/esp-iot-solution-usb-add_usb_solutions/components/usb/esp_usbh_cdc/esp_usbh_cdc.c: In function '_usb_get_config_desc':
D:/esp/esp-iot-solution-usb-add_usb_solutions/components/usb/esp_usbh_cdc/esp_usbh_cdc.c:754:5: error: implicit declaration of function 'usb_print_config_descriptor'; did you mean 'usb_print_descriptors'? [-Werror=implicit-function-declaration]
usb_print_config_descriptor(cfg_desc, NULL);
^~~~~~~~~~~~~~~~~~~~~~~~~~~
usb_print_descriptors
cc1.exe: some warnings being treated as errors
/-----------------------------------------------------------------------------------------------------------------------------------------------------------/
D:/esp/esp-iot-solution-usb-add_usb_solutions/components/usb/uvc_stream/uvc_stream.c: In function '_usb_get_dev_desc':
D:/esp/esp-iot-solution-usb-add_usb_solutions/components/usb/uvc_stream/uvc_stream.c:833:5: error: implicit declaration of function 'usb_print_device_descriptor'; did you mean 'usb_print_descriptors'? [-Werror=implicit-function-declaration]
usb_print_device_descriptor(dev_desc);
^~~~~~~~~~~~~~~~~~~~~~~~~~~
usb_print_descriptors
D:/esp/esp-iot-solution-usb-add_usb_solutions/components/usb/uvc_stream/uvc_stream.c: In function '_usb_get_config_desc':
D:/esp/esp-iot-solution-usb-add_usb_solutions/components/usb/uvc_stream/uvc_stream.c:885:5: error: implicit declaration of function 'usb_print_config_descriptor'; did you mean 'usb_print_descriptors'? [-Werror=implicit-function-declaration]
usb_print_config_descriptor(cfg_desc, _print_uvc_class_descriptors_cb);
^~~~~~~~~~~~~~~~~~~~~~~~~~~
usb_print_descriptors
cc1.exe: some warnings being treated as errors
/-----------------------------------------------------------------------------------------------------------------------------------------------------------/
我在使用IDF-4.4编译esp-iot-solution中的usb_cdc_4g_module示例工程时,出现了如上的错误。找不到usb_print_device_descriptor()和usb_print_device_descriptor()这两个函数的实现方法,请问该如何解决呢?

ESP_Bob
Posts: 80
Joined: Fri Nov 27, 2020 12:52 pm

Re: 编译usb_cdc_4g_module工程示例出现找不到函数的错误?紧急!!

Postby ESP_Bob » Sat May 07, 2022 1:34 pm

请使用 ESP-IDF v4.4.1 以上版本, 低版本缺少部分 API

linshc
Posts: 59
Joined: Mon Feb 21, 2022 2:06 am

Re: 编译usb_cdc_4g_module工程示例出现找不到函数的错误?紧急!!

Postby linshc » Tue May 10, 2022 8:16 am

使用了ESP-IDF V4.4.1版本,解决了这个问题。感谢!

Who is online

Users browsing this forum: No registered users and 37 guests