I recently installed the Arduino IDE (v. 1.8.6) on Linux Mint and followed that up with the Digistump DigiKeyboard library. I've done this in the past but this time, I'm getting the following errors when I try to compile anything with the include for the DigiKeyboard.h file:
Arduino: 1.8.6 (Linux), Board: "Digispark (Default - 16.5mhz)"
In file included from /home/{{USER}}/.arduino15/packages/arduino/tools/avr-gcc/4.8.1-arduino5/avr/include/avr/io.h:99:0,
from /home/{{USER}}/.arduino15/packages/digistump/hardware/avr/1.6.7/libraries/DigisparkKeyboard/usbportability.h:121,
from /home/{{USER}}/.arduino15/packages/digistump/hardware/avr/1.6.7/libraries/DigisparkKeyboard/usbdrvasm.S:19:
/home/{{USER}}/.arduino15/packages/digistump/hardware/avr/1.6.7/libraries/DigisparkKeyboard/usbdrv.h:662:33: error: operator '*' has no left operand
# define USB_INTR_PENDING GIFR
^
/home/{{USER}}/.arduino15/packages/digistump/hardware/avr/1.6.7/libraries/DigisparkKeyboard/usbdrvasm.S:74:5: note: in expansion of macro 'USB_INTR_PENDING'
#if USB_INTR_PENDING < 0x40 /* This is an I/O address, use in and out */
^
exit status 1
Error compiling for board Digispark (Default - 16.5mhz).
This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.
This doesn't seem to be the issue on OSX. Does anyone have any suggestions on how to fix this? There was one suggestion made in the forum to update commenting on new lines, but that hasn't proven to work yet.
SOLVED (sort of): For folks who are having trouble with the DigiStump AVR boards, specifically when including the DigiKeyboard.h library in the Arduino IDE version 1.8.6, there is a light at the end of the tunnel. Simply put, use version 1.8.5. I tested the following versions as well and they all were affected:
1.8.6 - stable
1.8.6 - nightly build
1.9.0 - beta
There has been some allusion to the fact that there is a bug with regards to comments being on the same line as statements. I have tried to debug this and haven't found that to be credible (at least in my tests). If this isn't filed as an issue, I can file it shortly.
pennsylforniageek:
This doesn't seem to be the issue on OSX.
It happens for me on Windows.
pennsylforniageek:
There has been some allusion to the fact that there is a bug with regards to comments being on the same line as statements. I have tried to debug this and haven't found that to be credible (at least in my tests).