orrmany / SDAntplus

A Nordic SoftDevice powered ANT+ library for the Arduino framework, intended to coexist with Adafruit Bluefruit52
Other
19 stars 5 forks source link

Adafruit TinyUSB Library issue #7

Open kalyanbhetwal opened 1 year ago

kalyanbhetwal commented 1 year ago

Hi,

I have been following your blog lately and it has been super-helpful. I am trying to get data from Garmin lidar lite v4 over ANT+ in Adafruit Bluefruit nrf82450. I already have the bootloader following your blog. But I couldn't succeed in compiling this particular repo.

Compiling .pio/build/adafruit_feather_nrf52840_s340/lib83e/Adafruit TinyUSB Library/class/cdc/cdc_device.c.o .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:48:28: error: 'uint8_t Adafruit_USBD_CDC::_instance_count' is not a static data member of 'class Adafruit_USBD_CDC' uint8_t Adafruit_USBD_CDC::_instance_count = 0; ^~~~~~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:50:49: error: no 'uint8_t Adafruit_USBD_CDC::getInstanceCount()' member function declared in class 'Adafruit_USBD_CDC' uint8_t Adafruit_USBD_CDC::getInstanceCount(void) { return _instance_count; } ^ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp: In constructor 'Adafruit_USBD_CDC::Adafruit_USBD_CDC()': .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:52:46: error: '_instance' was not declared in this scope Adafruit_USBD_CDC::Adafruit_USBD_CDC(void) { _instance = INVALID_INSTANCE; } ^~~~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:52:46: note: suggested alternative: 'isspace' Adafruit_USBD_CDC::Adafruit_USBD_CDC(void) { _instance = INVALID_INSTANCE; } ^~~~~ isspace .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:52:58: error: 'INVALID_INSTANCE' was not declared in this scope Adafruit_USBD_CDC::Adafruit_USBD_CDC(void) { _instance = INVALID_INSTANCE; } ^~~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp: At global scope: .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:55:68: error: no 'uint16_t Adafruit_USBD_CDC::getInterfaceDescriptor(uint8_t, uint8_t, uint16_t)' member function declared in class 'Adafruit_USBD_CDC' uint16_t bufsize) { ^ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp: In member function 'void Adafruit_USBD_CDC::begin(uint32_t)': .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:74:7: error: 'isValid' was not declared in this scope if (isValid()) { ^~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:79:9: error: '_instance_count' was not declared in this scope if (!(_instance_count < CFG_TUD_CDC)) { ^~~~~~~ In file included from /Users/ant/.platformio/packages/framework-arduinoadafruitnrf52/cores/nRF5/TinyUSB/Adafruit_TinyUSB_ArduinoCore/Adafruit_TinyUSB_Core.h:36:0, from /Users/ant/.platformio/packages/framework-arduinoadafruitnrf52/cores/nRF5/Arduino.h:72, from .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/webusb/Adafruit_USBD_WebUSB.cpp:30: /Users/ant/.platformio/packages/framework-arduinoadafruitnrf52/cores/nRF5/TinyUSB/Adafruit_TinyUSB_ArduinoCore/Adafruit_USBD_CDC.h:66:26: error: cannot declare variable 'Serial' to be of abstract type 'Adafruit_USBD_CDC' extern Adafruit_USBD_CDC Serial; ^~ /Users/ant/.platformio/packages/framework-arduinoadafruitnrf52/cores/nRF5/TinyUSB/Adafruit_TinyUSB_ArduinoCore/Adafruit_USBD_CDC.h:31:7: note: because the following virtual functions are pure within 'Adafruit_USBD_CDC': class Adafruit_USBD_CDC : public Stream, public Adafruit_USBD_Interface ^~~~~ In file included from .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_Device.h:28:0, from .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/webusb/Adafruit_USBD_WebUSB.h:29, from .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/webusb/Adafruit_USBD_WebUSB.cpp:29: .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_Interface.h:40:20: note: virtual uint16_t Adafruit_USBD_Interface::getInterfaceDescriptor(uint8_t, uint8_t, uint16_t) virtual uint16_t getInterfaceDescriptor(uint8_t itfnum, uint8_t *buf, ^~~~~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:83:3: error: '_instance' was not declared in this scope _instance = _instance_count++; ^~~~~ Compiling .pio/build/adafruit_feather_nrf52840_s340/lib83e/Adafruit TinyUSB Library/class/cdc/cdc_host.c.o .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:83:3: note: suggested alternative: 'isspace' _instance = _instance_count++; ^~~~~ isspace .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:83:15: error: '_instance_count' was not declared in this scope _instance = _instance_count++; ^~~~~~~ ** [.pio/build/adafruit_feather_nrf52840_s340/lib83e/Adafruit TinyUSB Library/arduino/webusb/Adafruit_USBD_WebUSB.cpp.o] Error 1 .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:85:3: error: 'TinyUSBDevice' was not declared in this scope TinyUSBDevice.addInterface(this); ^~~~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:85:3: note: suggested alternative: 'USBDevice' TinyUSBDevice.addInterface(*this); ^~~~~ USBDevice .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp: In member function 'void Adafruit_USBD_CDC::end()': .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:95:3: error: 'TinyUSBDevice' was not declared in this scope TinyUSBDevice.clearConfiguration(); ^~~~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:95:3: note: suggested alternative: 'USBDevice' TinyUSBDevice.clearConfiguration(); ^~~~~ USBDevice .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:96:3: error: '_instance_count' was not declared in this scope _instance_count = 0; ^~~~~~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:97:3: error: '_instance' was not declared in this scope _instance = INVALID_INSTANCE; ^~~~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:97:3: note: suggested alternative: 'isspace' _instance = INVALID_INSTANCE; ^~~~~ isspace .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:97:15: error: 'INVALID_INSTANCE' was not declared in this scope _instance = INVALID_INSTANCE; ^~~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp: In member function 'uint32_t Adafruit_USBD_CDC::baud()': .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:101:8: error: 'isValid' was not declared in this scope if (!isValid()) { ^~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:106:29: error: '_instance' was not declared in this scope tud_cdc_n_get_line_coding(_instance, &coding); ^~~~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:106:29: note: suggested alternative: 'isspace' tud_cdc_n_get_line_coding(_instance, &coding); ^~~~~ isspace .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp: In member function 'uint8_t Adafruit_USBD_CDC::stopbits()': .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:112:8: error: 'isValid' was not declared in this scope if (!isValid()) { ^~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:117:29: error: '_instance' was not declared in this scope tud_cdc_n_get_line_coding(_instance, &coding); ^~~~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:117:29: note: suggested alternative: 'isspace' tud_cdc_n_get_line_coding(_instance, &coding); ^~~~~ isspace .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp: In member function 'uint8_t Adafruit_USBD_CDC::paritytype()': .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:123:8: error: 'isValid' was not declared in this scope if (!isValid()) { ^~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:128:29: error: '_instance' was not declared in this scope tud_cdc_n_get_line_coding(_instance, &coding); ^~~~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:128:29: note: suggested alternative: 'isspace' tud_cdc_n_get_line_coding(_instance, &coding); ^~~~~ isspace .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp: In member function 'uint8_t Adafruit_USBD_CDC::numbits()': .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:134:8: error: 'isValid' was not declared in this scope if (!isValid()) { ^~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:139:29: error: '_instance' was not declared in this scope tud_cdc_n_get_line_coding(_instance, &coding); ^~~~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:139:29: note: suggested alternative: 'isspace' tud_cdc_n_get_line_coding(_instance, &coding); ^~~~~ isspace .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp: At global scope: .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:144:32: error: no 'int Adafruit_USBD_CDC::dtr()' member function declared in class 'Adafruit_USBD_CDC' int Adafruit_USBD_CDC::dtr(void) { ^ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp: In member function 'Adafruit_USBD_CDC::operator bool()': .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:153:8: error: 'isValid' was not declared in this scope if (!isValid()) { ^~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:157:34: error: '_instance' was not declared in this scope bool ret = tud_cdc_n_connected(_instance); ^~~~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:157:34: note: suggested alternative: 'isspace' bool ret = tud_cdc_n_connected(_instance); ^~~~~ isspace .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp: In member function 'virtual int Adafruit_USBD_CDC::available()': .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:168:8: error: 'isValid' was not declared in this scope if (!isValid()) { ^~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:172:40: error: '_instance' was not declared in this scope uint32_t count = tud_cdc_n_available(_instance); ^~~~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:172:40: note: suggested alternative: 'isspace' uint32_t count = tud_cdc_n_available(_instance); ^~~~~ isspace .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp: In member function 'virtual int Adafruit_USBD_CDC::peek()': .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:184:8: error: 'isValid' was not declared in this scope if (!isValid()) { ^~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:189:25: error: '_instance' was not declared in this scope return tud_cdc_n_peek(_instance, &ch) ? (int)ch : -1; ^~~~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:189:25: note: suggested alternative: 'isspace' return tud_cdc_n_peek(_instance, &ch) ? (int)ch : -1; ^~~~~ isspace .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp: In member function 'virtual int Adafruit_USBD_CDC::read()': .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:193:8: error: 'isValid' was not declared in this scope if (!isValid()) { ^~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:196:35: error: '_instance' was not declared in this scope return (int)tud_cdc_n_read_char(_instance); ^~~~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:196:35: note: suggested alternative: 'isspace' return (int)tud_cdc_n_read_char(_instance); ^~~~~ isspace .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp: At global scope: .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:200:8: error: prototype for 'size_t Adafruit_USBD_CDC::read(uint8_t, size_t)' does not match any in class 'Adafruit_USBD_CDC' size_t Adafruit_USBD_CDC::read(uint8_t buffer, size_t size) { ^~~~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:192:5: error: candidate is: virtual int Adafruit_USBD_CDC::read() int Adafruit_USBD_CDC::read(void) { ^~~~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp: In member function 'virtual void Adafruit_USBD_CDC::flush()': .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:210:8: error: 'isValid' was not declared in this scope if (!isValid()) { ^~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:214:25: error: '_instance' was not declared in this scope tud_cdc_n_write_flush(_instance); ^~~~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:214:25: note: suggested alternative: 'isspace' tud_cdc_n_write_flush(_instance); ^~~~~ isspace .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp: In member function 'virtual size_t Adafruit_USBD_CDC::write(const uint8_t*, size_t)': .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:220:8: error: 'isValid' was not declared in this scope if (!isValid()) { ^~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:225:40: error: '_instance' was not declared in this scope while (remain && tud_cdc_n_connected(_instance)) { ^~~~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:225:40: note: suggested alternative: 'isspace' while (remain && tud_cdc_n_connected(_instance)) { ^~~~~ isspace .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp: In member function 'virtual int Adafruit_USBD_CDC::availableForWrite()': .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:240:8: error: 'isValid' was not declared in this scope if (!isValid()) { ^~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:243:36: error: '_instance' was not declared in this scope return tud_cdc_n_write_available(_instance); ^~~~~ .pio/libdeps/adafruit_feather_nrf52840_s340/Adafruit TinyUSB Library/src/arduino/Adafruit_USBD_CDC.cpp:243:36: note: suggested alternative: 'isspace' return tud_cdc_n_write_available(_instance); ^~~~~ isspace *** [.pio/build/adafruit_feather_nrf52840_s340/lib83e/Adafruit TinyUSB Library/arduino/Adafruit_USBD_CDC.cpp.o] Error 1 ==================================== [FAILED] Took 10.01 seconds ====================================