public class SysFsDeviceFactory extends BaseNativeDeviceFactory
closed, deviceStates
DEFAULT_SPI_BUFFER_SIZE, SPI_PREFIX
I2C_PREFIX
Constructor and Description |
---|
SysFsDeviceFactory() |
getBoardInfo, getBoardPinInfo, getVRef, initialiseBoardInfo, registerDeviceFactory
createI2CKey, createPinKey, createSpiKey, deviceClosed, deviceOpened, getDevice, getDevice, isClosed, isDeviceOpened
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
loadInstances
provisionDigitalInputDevice, provisionDigitalInputOutputDevice, provisionDigitalOutputDevice
createSpiKey, getSpiBufferSize, provisionSpiDevice
createI2CKey, provisionI2CDevice
provisionPwmOutputDevice
provisionAnalogInputDevice
provisionAnalogOutputDevice
createI2CKey, createPinKey, createSpiKey, deviceClosed, deviceOpened, getDevice, getDevice, isClosed, isDeviceOpened
public void close()
close
in interface DeviceFactoryInterface
close
in interface Closeable
close
in interface AutoCloseable
close
in class BaseNativeDeviceFactory
public boolean isExported(int gpio)
gpio
- GPIO pinpublic String getName()
public int getBoardPwmFrequency()
public void setBoardPwmFrequency(int pwmFrequency)
public GpioDigitalInputDeviceInterface createDigitalInputDevice(String key, PinInfo pinInfo, GpioPullUpDown pud, GpioEventTrigger trigger) throws RuntimeIOException
RuntimeIOException
public GpioDigitalOutputDeviceInterface createDigitalOutputDevice(String key, PinInfo pinInfo, boolean initialValue) throws RuntimeIOException
RuntimeIOException
public GpioDigitalInputOutputDeviceInterface createDigitalInputOutputDevice(String key, PinInfo pinInfo, DeviceMode mode) throws RuntimeIOException
RuntimeIOException
public PwmOutputDeviceInterface createPwmOutputDevice(String key, PinInfo pinInfo, int pwmFrequency, float initialValue) throws RuntimeIOException
RuntimeIOException
public AnalogInputDeviceInterface createAnalogInputDevice(String key, PinInfo pinInfo) throws RuntimeIOException
RuntimeIOException
public AnalogOutputDeviceInterface createAnalogOutputDevice(String key, PinInfo pinInfo) throws RuntimeIOException
RuntimeIOException
public SpiDeviceInterface createSpiDevice(String key, int controller, int chipSelect, int frequency, SpiClockMode spiClockMode, boolean lsbFirst) throws RuntimeIOException
RuntimeIOException
public I2CDeviceInterface createI2CDevice(String key, int controller, int address, int addressSize, int clockFrequency) throws RuntimeIOException
RuntimeIOException
Copyright © 2016–2018 mattjlewis. All rights reserved.