It works just fine when I use it on ItsyBitsy 32U4 builds.
Code: Select all
Arduino: 1.8.13 (Linux), Board: "Adafruit Trinket M0, Small (-Os) (standard), Arduino, Off"
Archiving built core (caching) in: /tmp/arduino_cache_195164/core/core_adafruit_samd_adafruit_trinket_m0_opt_small,usbstack_arduino,debug_off_d53cd4b49ba6ff60d7721159bd65a417.a
/home/bram/.arduino15/packages/adafruit/tools/arm-none-eabi-gcc/9-2019q4/bin/../lib/gcc/arm-none-eabi/9.2.1/../../../../arm-none-eabi/bin/ld: sketch/RawHID.cpp.o: in function `RawHID_::getInterface(unsigned char*)':
sketch/RawHID.cpp:65: undefined reference to `USB_SendControl(unsigned char, void const*, unsigned char)'
/home/bram/.arduino15/packages/adafruit/tools/arm-none-eabi-gcc/9-2019q4/bin/../lib/gcc/arm-none-eabi/9.2.1/../../../../arm-none-eabi/bin/ld: sketch/RawHID.cpp.o: in function `RawHID_::getDescriptor(USBSetup&)':
sketch/RawHID.cpp:81: undefined reference to `USB_SendControl(unsigned char, void const*, unsigned char)'
collect2: error: ld returned 1 exit status
exit status 1
Error compiling for board Adafruit Trinket M0.
USB_SendControl() is part of the core API, as can be seen here:
https://github.com/arduino/ArduinoCore- ... i/USBAPI.h