Reset the expander to a known state and configure pins
1
2
gpio.ResetToDefault();// all pins become inputs with pull-upsgpio.SetPinDirection(0,PACL95555::GPIODir::Output);
Toggle outputs and read inputs
1
2
gpio.WritePin(0,true);boolinput=gpio.ReadPin(1);
Handle interrupts (optional)
1
2
3
4
autocallback=[](uint16_tstatus){// respond to interrupts here};gpio.SetInterruptCallback(callback);
These minimal steps bring the expander online. The library exposes many more
functions for configuring pull resistors, drive strength and polarity. Refer to
the API Reference once you are comfortable with the basics.