Skip to main content

Class Mcp23x1x

Represent an MCP23x1x I2C port expander

Assembly: Mcp23xxx.dll
View Source
Declaration
public abstract class Mcp23x1x : Mcp23xxx, IDigitalInputOutputController, IDigitalInputController, IDigitalOutputController, ISpiPeripheral, II2cPeripheral, IDigitalInterruptController, IPinController

Inheritance: System.Object -> Meadow.Foundation.ICs.IOExpanders.Mcp23xxx

Derived:
Meadow.Foundation.ICs.IOExpanders.Mcp23017

Implements:
Meadow.Hardware.IDigitalInputOutputController, Meadow.Hardware.IDigitalInputController, Meadow.Hardware.IDigitalOutputController, Meadow.Hardware.ISpiPeripheral, Meadow.Hardware.II2cPeripheral, Meadow.Hardware.IDigitalInterruptController, Meadow.Hardware.IPinController

Properties

Pins

MCP23x17 pin definitions

View Source
Declaration
public Mcp23x1x.PinDefinitions Pins { get; }

NumberOfPins

The number of IO pins available on the device

View Source
Declaration
public override int NumberOfPins { get; }

Methods

IsValidPin(IPin)

Is the pin valid for this device instance

View Source
Declaration
protected override bool IsValidPin(IPin pin)
Returns

System.Boolean: True if pin is valid

Parameters
TypeNameDescription
Meadow.Hardware.IPinpinThe IPin to validate

GetPin(string)

Get pin reference by name

View Source
Declaration
public override IPin GetPin(string pinName)
Returns

Meadow.Hardware.IPin: IPin reference if found

Parameters
TypeNameDescription
System.StringpinNameThe pin name as a string

Implements

  • Meadow.Hardware.IDigitalInputOutputController
  • Meadow.Hardware.IDigitalInputController
  • Meadow.Hardware.IDigitalOutputController
  • Meadow.Hardware.ISpiPeripheral
  • Meadow.Hardware.II2cPeripheral
  • Meadow.Hardware.IDigitalInterruptController
  • Meadow.Hardware.IPinController