micro-ROS / micro-ROS/micro_ros_espidf_component
Issues compiling with W5500 enabled
Chưa có ai nhận issue này.
- Ngôn ngữ chính
- C
- Star
- 419
- Fork
- 124
- Merge trung bình
- 21 giờ 35 phút
- Pull request đã merge (30 ngày)
- 3
Mô tả
Issue template
- Hardware description: ESP32 with W5500
- RTOS: freeRTOS
- Installation type: idf 5.2 in vscode
- Version or commit hash: ROS Iron, Micro-ROS commit 2b541f8
Steps to reproduce the issue
Create a new project using the pub/sub example.
Configure project to use W5500
Expected behavior
Code compiles and is able to run on the ESP32
Actual behavior
I instead get the following when compling:
/home/kevin/projects/esp32/hello_world/components/micro_ros_espidf_component/network_interfaces/uros_ethernet_netif.c: In function 'uros_network_interface_initialize':
/home/kevin/projects/esp32/hello_world/components/micro_ros_espidf_component/network_interfaces/uros_ethernet_netif.c:78:21: error: implicit declaration of function 'esp_eth_set_default_handlers' [-Werror=implicit-function-declaration]
78 | ESP_ERROR_CHECK(esp_eth_set_default_handlers(eth_netif));
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/kevin/esp/v5.2/esp-idf/components/esp_common/include/esp_err.h:117:30: note: in definition of macro 'ESP_ERROR_CHECK'
117 | esp_err_t err_rc_ = (x); \
| ^
/home/kevin/projects/esp32/hello_world/components/micro_ros_espidf_component/network_interfaces/uros_ethernet_netif.c:139:74: error: macro "ETH_W5500_DEFAULT_CONFIG" requires 2 arguments, but only 1 given
139 | eth_w5500_config_t w5500_config = ETH_W5500_DEFAULT_CONFIG(spi_handle);
| ^
In file included from /home/kevin/esp/v5.2/esp-idf/components/esp_eth/include/esp_eth_driver.h:9,
from /home/kevin/esp/v5.2/esp-idf/components/esp_eth/include/esp_eth.h:15,
from /home/kevin/projects/esp32/hello_world/components/micro_ros_espidf_component/network_interfaces/uros_ethernet_netif.c:6:
/home/kevin/esp/v5.2/esp-idf/components/esp_eth/include/esp_eth_mac.h:623: note: macro "ETH_W5500_DEFAULT_CONFIG" defined here
623 | #define ETH_W5500_DEFAULT_CONFIG(spi_host, spi_devcfg_p) \
|
/home/kevin/projects/esp32/hello_world/components/micro_ros_espidf_component/network_interfaces/uros_ethernet_netif.c:139:39: error: 'ETH_W5500_DEFAULT_CONFIG' undeclared (first use in this function)
139 | eth_w5500_config_t w5500_config = ETH_W5500_DEFAULT_CONFIG(spi_handle);
| ^~~~~~~~~~~~~~~~~~~~~~~~`
Additional information
Only change to the basic component it to allow pin 35 to be selected for MISO.
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Hướng nghiên cứu
Bắt đầu với network_interfaces/uros_ethernet_netif.c, đặc biệt là các lệnh gọi ở dòng 78 và 139, rồi so sánh các API đó với các header của ESP-IDF 5.2 được hiển thị trong đầu ra của trình biên dịch. Chạy lại ví dụ pub/sub được cấu hình cho W5500; được xem là hoàn tất khi component biên dịch thành công và ESP32 có thể chạy nó.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- c
- Lĩnh vực
- embedded-iot
- Loại issue
- Lỗi
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Khá rõ ràng
- Mức phù hợp với người mới
- 35/100