Analog and Digital Pins
Posted:
Tue Nov 07, 2017 2:04 pm
by sprinkfitter
I am doing a project that would require more digital pins than my esp8266 12e has. I have used a mcp3008 and made more analog pins but now I need a couple more digital pins. Can someone point me in the direction how I go about doing this. I have a total of 8 relays I have to control. Thanks for the help
Ray
Re: Analog and Digital Pins
Posted:
Tue Nov 07, 2017 11:51 pm
by trackerj
Re: Analog and Digital Pins
Posted:
Wed Nov 08, 2017 5:04 am
by lethe
Since you only need outputs, you can also use shift registers. Using 3 I/O you can get any number of outputs (8 per register & you can daisy chain as many as needed).
They are also dirt cheap and easy to use, just google for 74hc595 and you'll find plenty of examples.
Re: Analog and Digital Pins
Posted:
Wed Nov 08, 2017 6:10 am
by jarnoldbrown
Or, since:
a) You're already using SPI for the ADC.
b) There are apparently libraries for it
Why not look at the MCP23S17 ?