Package com.kosdev.kos.core.service.gpio
Interface GpioPinChangeCallback
public interface GpioPinChangeCallback
Listener for gpio input pin changes. This interface has a single method to make
it lambda friendly, but
GpioInputPinDef has separate listeners for pin
on and off events, avoiding the need to check the value.- Since:
- 9
- Version:
- 9
-
Method Summary
Modifier and TypeMethodDescriptionvoidonPinChange(GpioInputPin pin, boolean val) Called when the pin changes state.
-
Method Details
-
onPinChange
Called when the pin changes state.- Parameters:
pin- the pin that changedval- the new value of the pin- Since:
- 9
-