arduino / arduino/ArduinoCore-API

Each core provides a different USBAPI

Đang mở
#141 2 bình luận 1 reaction 0 người được giao Xem trên GitHub
Ngôn ngữ chính
C++
Star
306
Fork
150
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

The Arduino Core API defines a very low level USB api in [api/USBAPI.h](https://github.com/arduino/ArduinoCore-API/blob/master/api/USBAPI.h). This API is implemented by the avr core in [cores/arduino/USBCore.cpp](https://github.com/arduino/ArduinoCore-avr/blob/master/cores/arduino/USBCore.cpp). But it is not implemented by samd core, which implements the same functionality but in its own [`USBDeviceClass` class](https://github.com/arduino/ArduinoCore-samd/blob/master/cores/arduino/USB/USBCore.cpp). The USB implementation in megaavr core (`USBCore.cpp`) is a copy of the avr usb implementation with some deviations. The mbed core implements its own version of the `PluggableUSBModule`.

As a result, each core implements its own USB API which is incompatible with the others, there exist many code duplicates and users of the USB API have to understand and adapt their code to each individual core implementation.

Are there any plans to improve this situation?

Hướng dẫn đóng góp

Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này

Hướng nghiên cứu

Bắt đầu với api/USBAPI.h và so sánh các phần triển khai trong các đường dẫn core avr, samd, megaavr và mbed được nêu trong issue, bao gồm USBCore.cpp, USBDeviceClass và PluggableUSBModule. Issue không xác định một thay đổi cụ thể, vì vậy trước tiên hãy xác lập phạm vi tương thích dự kiến; công việc được xem là hoàn tất khi đạt được thống nhất về một USB API chung giữa các core bị ảnh hưởng.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Đánh giá

Công nghệ
cpp
Lĩnh vực
api, embedded-iot
Loại issue
Tính năng
Độ khó
5/5
Thời gian dự kiến
Hơn một tuần
Mức độ hoạt động
Đình trệ
Độ rõ ràng
Cần làm rõ
Mức phù hợp với người mới
25/100

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.