Package com.diozero.devices
Class MCP23S17
java.lang.Object
- All Implemented Interfaces:
GpioExpander
,InputEventListener<DigitalInputEvent>
,DeviceFactoryInterface
,GpioDeviceFactoryInterface
,PwmOutputDeviceFactoryInterface
,java.io.Closeable
,java.lang.AutoCloseable
public class MCP23S17 extends MCP23x17
-
Nested Class Summary
Nested classes/interfaces inherited from class com.diozero.internal.provider.mcp23xxx.MCP23x17
MCP23x17.MCP23x17BoardPinInfo
-
Field Summary
Fields inherited from class com.diozero.internal.provider.AbstractDeviceFactory
closed, deviceStates
-
Constructor Summary
Constructors Constructor Description MCP23S17(int address)
MCP23S17(int address, int interruptGpio)
MCP23S17(int address, int interruptGpioA, int interruptGpioB)
MCP23S17(int controller, int chipSelect, int address, int interruptGpio)
MCP23S17(int controller, int chipSelect, int address, int interruptGpioA, int interruptGpioB)
-
Method Summary
Methods inherited from class com.diozero.internal.provider.mcp23xxx.MCP23x17
getBoardPinInfo, getDefValReg, getGPIntEnReg, getGPIOReg, getGPPullUpReg, getIntCapReg, getIntConReg, getIntFReg, getIOConReg, getIODirReg, getIPolReg, getOLatReg
Methods inherited from class com.diozero.internal.provider.mcp23xxx.MCP23xxx
closeGpio, createDigitalInputDevice, createDigitalInputOutputDevice, createDigitalOutputDevice, createPwmOutputDevice, getBoardPwmFrequency, getName, getValue, getValues, initialise, setBoardPwmFrequency, setDirections, setInputMode, setOutputMode, setValue, setValues, valueChanged
Methods inherited from class com.diozero.internal.provider.AbstractDeviceFactory
createI2CKey, createPinKey, createSpiKey, deviceClosed, deviceOpened, getDevice, getDevice, isClosed, isDeviceOpened
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.diozero.internal.provider.DeviceFactoryInterface
createI2CKey, createPinKey, createSpiKey, deviceClosed, deviceOpened, getDevice, getDevice, isClosed, isDeviceOpened
Methods inherited from interface com.diozero.internal.provider.GpioDeviceFactoryInterface
provisionDigitalInputDevice, provisionDigitalInputOutputDevice, provisionDigitalOutputDevice
Methods inherited from interface com.diozero.internal.provider.PwmOutputDeviceFactoryInterface
provisionPwmOutputDevice
-
Constructor Details
-
MCP23S17
- Throws:
RuntimeIOException
-
MCP23S17
- Throws:
RuntimeIOException
-
MCP23S17
- Throws:
RuntimeIOException
-
MCP23S17
public MCP23S17(int controller, int chipSelect, int address, int interruptGpio) throws RuntimeIOException- Throws:
RuntimeIOException
-
MCP23S17
public MCP23S17(int controller, int chipSelect, int address, int interruptGpioA, int interruptGpioB) throws RuntimeIOException- Throws:
RuntimeIOException
-
-
Method Details
-
close
- Specified by:
close
in interfacejava.lang.AutoCloseable
- Specified by:
close
in interfacejava.io.Closeable
- Specified by:
close
in interfaceDeviceFactoryInterface
- Specified by:
close
in interfaceGpioExpander
- Overrides:
close
in classMCP23xxx
- Throws:
RuntimeIOException
-
readByte
protected byte readByte(int register) -
writeByte
protected void writeByte(int register, byte value)
-