pi4j-v1
pi4j-v1 copied to clipboard
GpioPinAnalogValueChangeEvent not firing as expected
Using a potentiometer with MCP3008 and Raspberry Pi 3. Executed MCP3008GpioExample.java, unmodified from GitHub, Set eventThreshold to 5 and setMonitorInterval to 5 milliseconds.
GpioPinAnalogValueChangeEvent is not registering every change of eventThreshold when I actuate the potentiometer very slowly. Especially near the low end. Not sure why. To make sure I wasn't losing my mind, in the Thread.sleep loop I added a println to .getValue. Sure enough, the value is changing, but the GpioPinAnalogValueChangeEvent doesn't register it.
Am I missing something?