I'm building a digital organ and have used MCP23S17 expanders with Arduino Nanos with a fair measure of success. However, I want to tidy it all up and make the organ idiot-proof. When I switch on the Arduino starts up, but the expanders don't. If I press the reset on the Nano then it restarts and everything works. I've tried various solutions, putting a delay in the setup() code before initialising the expanders. I even tried putting a capacitor between the Nano rst pin and ground but that seems to prevent uploading new code, so I had to remove it. According to the MCP23S17 datasheet it has a builtin POR which should handle any initial setup at that end. If it is the expanders, I don't see why resetting the Nano would clear the problem. Can anyone help?
I'm happy to provide more detailed information if you say what is needed.
Have you added a pull up resistor (say 10k) to the reset pin of the MCP23S17 ? The data sheet says this must be externally biased so can't be left floating. Even if you control this over an Arduino pin, a resistor is necessary because an Arduino pin is floating at power on.
Thanks for the pointer!
If you come back the next step is to get a review of your code and a schematic diagram.
Connect the MCP23S17 reset pin to an output pin. In setup() cycle the MCP reset.
This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.