1 week, 1 day ago.

Problems to use MCP23S17

I use this program to drive MCP23S17. (Refer below code.) /media/uploads/aaaaaYukiaaaaa/main.cpp A purpose of this program is to output by MCP23S17. Not need to think about inputting. I only want to output. In the real, I use 4 MCPS17. So I use "for loop". Mbed is master, a slave is MCP23S17.

I could compile it. It had no errors. But It didn't work well... I checked signals on scl, mosi, miso(SPI signals). Correct logic comes to slave pins surely. But MCP23S17 pins won't try to output...

In addition, I checked register of MCP23S17 written on the datasheet. It is correct. I can't find the wrong points of my code.

Do you know why it doesn't work well? If you know, pls teach me!

Comment on this question
Be the first to answer this question.

To post an answer, please log in.