Library for PCF8575 I2C Expander

Library for PCF8575 I2C Expander

PCF8575 is 16-bit I/O expander for the two-line bidirectional bus (I2C). It features 16-bit quasi-bidirectional I/O port, P07-P00 and P17-P10. It can easily be switched from output to input; write I/O with “1” to be used as an input. Quasi-bidirectional means that outputs can be used both as an input and output without the need to reconfigure the port. There are 8 address combinations (A2 A1 A0) so it is possible to have eight I2C expanders on same I2C bus. Connection PCF8575 – STM32 is plain simple. There is no need for external pull-up resistors…