Hello, everyone!
I can't understand pin numbering using ioabstraction lib.
For example:
#include <IoAbstraction.h>
#include <IoAbstractionWire.h>
IoAbstractionRef ioExpander1;
IoAbstractionRef ioExpander2;
void setup() {
ioExpander1 = ioFrom8574(0x27);
ioExpander2 = ioFrom8574(0x28);
// put your setup code here, to run once:
}
void loop() {
// put your main code here, to run repeatedly:
}
I set io to input using pinDirection(). If I want to read value from pin there is no problem. I can use ioDeviceDigitalRead with unit ref and pin number. I want to addSwitch() function witch only have "pin" parameter. And now I can't understand...? For example I want to addswitch to pin 3 ioExpander1 and to pin 5 ioExpander2. What pin numbers I should print in addSwitch() function?