In file included from usbdrv.c:12:0:
usbdrv.h:473:6: error: variable 'usbDescriptorDevice' must be const in order to be put into read-only section by means of '__attribute__((progmem))'
char usbDescriptorDevice[];
^
usbdrv.h:479:6: error: variable 'usbDescriptorConfiguration' must be const in order to be put into read-only section by means of '__attribute__((progmem))'
char usbDescriptorConfiguration[];
^
usbdrv.h:485:6: error: variable 'usbDescriptorHidReport' must be const in order to be put into read-only section by means of '__attribute__((progmem))'
char usbDescriptorHidReport[];
^
usbdrv.h:491:6: error: variable 'usbDescriptorString0' must be const in order to be put into read-only section by means of '__attribute__((progmem))'
char usbDescriptorString0[];
^
usbdrv.h:497:5: error: variable 'usbDescriptorStringVendor' must be const in order to be put into read-only section by means of '__attribute__((progmem))'
int usbDescriptorStringVendor[];
^
usbdrv.h:503:5: error: variable 'usbDescriptorStringDevice' must be const in order to be put into read-only section by means of '__attribute__((progmem))'
int usbDescriptorStringDevice[];
^
usbdrv.h:509:5: error: variable 'usbDescriptorStringSerialNumber' must be const in order to be put into read-only section by means of '__attribute__((progmem))'
int usbDescriptorStringSerialNumber[];
^
usbdrv.c:70:14: error: variable 'usbDescriptorString0' must be const in order to be put into read-only section by means of '__attribute__((progmem))'
PROGMEM char usbDescriptorString0[] = { /* language descriptor */
^
usbdrv.c:80:14: error: variable 'usbDescriptorStringVendor' must be const in order to be put into read-only section by means of '__attribute__((progmem))'
PROGMEM int usbDescriptorStringVendor[] = {
^
usbdrv.c:89:14: error: variable 'usbDescriptorStringDevice' must be const in order to be put into read-only section by means of '__attribute__((progmem))'
PROGMEM int usbDescriptorStringDevice[] = {
^
usbdrv.c:111:14: error: variable 'usbDescriptorDevice' must be const in order to be put into read-only section by means of '__attribute__((progmem))'
PROGMEM char usbDescriptorDevice[] = { /* USB device descriptor */
^
usbdrv.c:142:14: error: variable 'usbDescriptorConfiguration' must be const in order to be put into read-only section by means of '__attribute__((progmem))'
PROGMEM char usbDescriptorConfiguration[] = { /* USB configuration descriptor */
^
我用1.0.1和1.0.5版都不行,我去下个1.0.6试试
刚下了,出现这样的问题
:
This report would have more information with
"Show verbose output during compilation"
enabled in File > Preferences.
Arduino: 1.0.6 (Windows 7), Board: "Arduino Uno"
usbdrv.c.o: In function `usbBuildTxBlock':
C:\Users\ADMINI~1\AppData\Local\Temp\build1866609749723809719.tmp/usbdrv.c:536: undefined reference to `usbCrc16Append'
usbdrv.c.o: In function `usbGenericSetInterrupt':
C:\Users\ADMINI~1\AppData\Local\Temp\build1866609749723809719.tmp/usbdrv.c:240: undefined reference to `usbCrc16Append'
不知如何解决??