SparkFun_APDS-9960_Sensor_Arduino_Library icon indicating copy to clipboard operation
SparkFun_APDS-9960_Sensor_Arduino_Library copied to clipboard

Add digitalPinToInterrupt()

Open ShawnHymel opened this issue 9 years ago • 2 comments

As per new Arduino library, digitalPinToInterrupt() needs to be added to attachInterrupt().

ShawnHymel avatar Jan 11 '16 17:01 ShawnHymel

Do I change this in the loop, or in the initialize isr? or both? Every example from this library works flawlessly except the gesture sensor example. Seems to work fine, but nothing is read.

BigSamosa avatar Apr 04 '17 03:04 BigSamosa

Yeah, 18 months later, and this still isn't fixed, and it bit me trying to run it on a Teensy LC. Line 73 should be changed to read

attachInterrupt(digitalPinToInterrupt(APDS9660_INT), interruptRoutine, FALLING);

jcwren avatar Aug 15 '17 01:08 jcwren