Edit

Share via


Mcp23xxx Constructors

Definition

Overloads

Mcp23xxx(Mcp23xxx+BusAdapter, Int32, Int32, Int32, GpioController, BankStyle)
Mcp23xxx(Mcp23xxx+BusAdapter, Int32, Int32, Int32, GpioController, BankStyle, Boolean)

A general purpose parallel I/O expansion for I2C or SPI applications.

Mcp23xxx(Mcp23xxx+BusAdapter, Int32, Int32, Int32, GpioController, BankStyle)

protected Mcp23xxx (Iot.Device.Mcp23xxx.Mcp23xxx.BusAdapter bus, int reset = -1, int interruptA = -1, int interruptB = -1, System.Device.Gpio.GpioController masterController = default, Iot.Device.Mcp23xxx.BankStyle bankStyle = Iot.Device.Mcp23xxx.BankStyle.Sequential);
new Iot.Device.Mcp23xxx.Mcp23xxx : Iot.Device.Mcp23xxx.Mcp23xxx.BusAdapter * int * int * int * System.Device.Gpio.GpioController * Iot.Device.Mcp23xxx.BankStyle -> Iot.Device.Mcp23xxx.Mcp23xxx
Protected Sub New (bus As Mcp23xxx.BusAdapter, Optional reset As Integer = -1, Optional interruptA As Integer = -1, Optional interruptB As Integer = -1, Optional masterController As GpioController = Nothing, Optional bankStyle As BankStyle = Iot.Device.Mcp23xxx.BankStyle.Sequential)

Parameters

reset
Int32
interruptA
Int32
interruptB
Int32
masterController
GpioController
bankStyle
BankStyle

Applies to

Mcp23xxx(Mcp23xxx+BusAdapter, Int32, Int32, Int32, GpioController, BankStyle, Boolean)

A general purpose parallel I/O expansion for I2C or SPI applications.

protected Mcp23xxx (Iot.Device.Mcp23xxx.Mcp23xxx.BusAdapter bus, int reset = -1, int interruptA = -1, int interruptB = -1, System.Device.Gpio.GpioController? controller = default, Iot.Device.Mcp23xxx.BankStyle bankStyle = Iot.Device.Mcp23xxx.BankStyle.Sequential, bool shouldDispose = true);
protected Mcp23xxx (Iot.Device.Mcp23xxx.Mcp23xxx.BusAdapter bus, int reset = -1, int interruptA = -1, int interruptB = -1, System.Device.Gpio.GpioController? gpioController = default, Iot.Device.Mcp23xxx.BankStyle bankStyle = Iot.Device.Mcp23xxx.BankStyle.Sequential, bool shouldDispose = true);
new Iot.Device.Mcp23xxx.Mcp23xxx : Iot.Device.Mcp23xxx.Mcp23xxx.BusAdapter * int * int * int * System.Device.Gpio.GpioController * Iot.Device.Mcp23xxx.BankStyle * bool -> Iot.Device.Mcp23xxx.Mcp23xxx
new Iot.Device.Mcp23xxx.Mcp23xxx : Iot.Device.Mcp23xxx.Mcp23xxx.BusAdapter * int * int * int * System.Device.Gpio.GpioController * Iot.Device.Mcp23xxx.BankStyle * bool -> Iot.Device.Mcp23xxx.Mcp23xxx
Protected Sub New (bus As Mcp23xxx.BusAdapter, Optional reset As Integer = -1, Optional interruptA As Integer = -1, Optional interruptB As Integer = -1, Optional controller As GpioController = Nothing, Optional bankStyle As BankStyle = Iot.Device.Mcp23xxx.BankStyle.Sequential, Optional shouldDispose As Boolean = true)
Protected Sub New (bus As Mcp23xxx.BusAdapter, Optional reset As Integer = -1, Optional interruptA As Integer = -1, Optional interruptB As Integer = -1, Optional gpioController As GpioController = Nothing, Optional bankStyle As BankStyle = Iot.Device.Mcp23xxx.BankStyle.Sequential, Optional shouldDispose As Boolean = true)

Parameters

bus
Mcp23xxx.BusAdapter

The bus the device is connected to.

reset
Int32

The output pin number that is connected to the hardware reset.

interruptA
Int32

The input pin number that is connected to the interrupt for Port A (INTA).

interruptB
Int32

The input pin number that is connected to the interrupt for Port B (INTB).

controllergpioController
GpioController

The controller for the reset and interrupt pins. If not specified, the default controller will be used.

bankStyle
BankStyle

The current bank style of the ports. This does not set the bank style- it tells us what the bank style is. It is highly recommended not to change the bank style from the default as there is no direct way to detect what style the chip is in and most apps will fail if the chip is not set to defaults. This setting has no impact on 8-bit expanders.

shouldDispose
Boolean

True to dispose the Gpio Controller

Applies to