Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
how to add MCP23017 by i2c on Raspberry pi CM4 to extend GPIOs
#1
1. connect MCP23017 i2c module with KinCony Server-Mini's i2c extend terminal. so that you can extend 16 GPIOs for switch or binary sensor in home assistant.
   
   

2. enable i2c for home assistant.

Add files to enable I2C
In the root of the hassos-boot partition, add a new folder called CONFIG.
In the CONFIG folder, add another new folder called modules.
Inside the modules folder add a text file called rpi-i2c.conf with the following content:
i2c-dev

In the root of the hassos-boot partition, edit the file called config.txt add two lines to it:
dtparam=i2c_vc=on
dtparam=i2c_arm=on

3. MCP23008/MCP23017 implementation for Home Assistant (HA)
https://github.com/jpcornil-git/HA-mcp23017

   
   
Reply


Forum Jump:


Users browsing this thread:
1 Guest(s)