Exemplo n.º 1
0
 public MCP23008(byte I2CAddress = 0x20, int InteruptPin = 0)
 {
     PORT_EXPANDER_I2C_ADDRESS = I2CAddress;
     if (InteruptPin != 0)
     {
         interuptA = new GPIOAccess.PinIn(InteruptPin, false);
     }
     else
     {
         interuptA = null;
     }
     //set interupt b to null since there is only one register.
     interuptB = null;
 }
Exemplo n.º 2
0
 public MCP23017(byte I2CAddress = 0x20, int InteruptPinA = 0, int InteruptPinB = 0)
 {
     PORT_EXPANDER_I2C_ADDRESS = I2CAddress;
     if (InteruptPinA != 0)
     {
         interuptA = new GPIOAccess.PinIn(InteruptPinA, false);
     }
     else
     {
         interuptA = null;
     }
     if (InteruptPinB != 0)
     {
         interuptB = new GPIOAccess.PinIn(InteruptPinB, false);
     }
     else
     {
         interuptB = null;
     }
 }