Posts: 6
Joined: Sun Sep 10, 2017 9:09 am

Controlling and sensing 14 relays

Fri Mar 30, 2018 1:44 pm

I plan to automate the lights in my house controlled by a raspberry pi.
Currently I have 14 latching relays controlling the light in my house and I'll add another actor (raspberry) to them by using this relay module: ... elay+modul

To sense if the light is already switched on I installed latching relays with two separate loops, so one is for the light to be powered the other one will be connected to the raspberry. If the loop is closed the raspberry can identify the current state of the light.

The problem is - this will take up 14 GPIO pins for switching and another 14 GPIO pins for sensing.
I thought of buying this extension board: ... il_0?psc=1 but I'm not sure if this will actually extend the amount of GPIOs available.

Maybe someone could give me a hint on which board to use or which is the best way to achieve this.

Alex Konshin
Posts: 45
Joined: Sun Jan 29, 2017 10:02 pm
Location: Boston MA, USA

Re: Controlling and sensing 14 relays

Sat Mar 31, 2018 12:00 am

Buy or make a board with MCP23017. Something like this:
I use it in one of my projects to control 2 boards like yours (32 relays) from one Raspberry Pi.

Return to “Automation, sensing and robotics”