public class DebouncedDigitalInputDevice extends WaitableDigitalInputDevice
device
activeHigh
gpio
Constructor and Description |
---|
DebouncedDigitalInputDevice(int gpio) |
DebouncedDigitalInputDevice(int gpio,
GpioPullUpDown pud,
float debounceTime) |
DebouncedDigitalInputDevice(int gpio,
GpioPullUpDown pud,
float debounceTime,
GpioEventTrigger trigger) |
Modifier and Type | Method and Description |
---|---|
void |
setDebounceTime(float debounceTime) |
disableDeviceListener, valueChanged, waitForActive, waitForActive, waitForInactive, waitForInactive, waitForValue
close, getPullUpDown, getTrigger, getValue, isActive, removeListener, setListener
enableDeviceListener, isActiveHigh, whenActivated, whenDeactivated
addListener, removeAllListeners, removeListener
getGpio
public DebouncedDigitalInputDevice(int gpio) throws RuntimeIOException
RuntimeIOException
public DebouncedDigitalInputDevice(int gpio, GpioPullUpDown pud, float debounceTime) throws RuntimeIOException
gpio
- GPIOpud
- Pull-up/down configuratoindebounceTime
- Specifies the length of time (in seconds) that the component
will ignore changes in state after an initial change. This
defaults to 0 which indicates that no bounce compensation will
be performed.RuntimeIOException
- if an I/O error occurspublic DebouncedDigitalInputDevice(int gpio, GpioPullUpDown pud, float debounceTime, GpioEventTrigger trigger) throws RuntimeIOException
RuntimeIOException
Copyright © 2016–2017 mattjlewis. All rights reserved.