Nodemcu v3 connected in 2 pcf8574 with 8relays and push button

If that's all the hardware you are going to use, then you can hook up your buttons directly to digital pins and do the same for the 8 outputs, or you can use a shift register for them. This will reduce the complexity and the overhead. Also, I suggest that you start on a smaller scale; for instance, with just 2 buttons (like you seem to have done already) and 2 relays, or even 2 simple LEDs to emulate what you want the relays to do.

But one issue remains, and it is of importance, so don't overlook it: what on earth do you want your prototype to do? What behaviour are you after? And, last but not least, what have you tried?

1 Like