cancel
Showing results for 
Search instead for 
Did you mean: 

NSS pin as GPIO when using SPI interface

DiBosco
Senior
Posted on September 23, 2010 at 18:56

NSS pin as GPIO when using SPI interface

4 REPLIES 4
Singh.Harjit
Senior II
Posted on May 17, 2011 at 14:08

You can indeed do what you are asking - I have it working. I had to try different coding things to make it work.

The comment from my (working) code is:

// Set Software slave management amd make the SSI bit one.

Then, as long as the SPI_CR1_SPE is set, the SPI interface will work.
DiBosco
Senior
Posted on May 17, 2011 at 14:08

Thanks, Harjit. this still doesn't work though.

Edit: yes it does. You seem to have to set both the bits at the same time.

Singh.Harjit
Senior II
Posted on May 17, 2011 at 14:08

Glad you got it working.

The documentation is very confusing on this topic. I wish they had spelled out what it took to support each way.
DiBosco
Senior
Posted on May 17, 2011 at 14:08

The documentation on a lot of the STM32 stuff is absolutely terrible. I don't know whether a non-native English speaker wrote it or they just didn't take enough time over it. It's made me look at going back to Atmel or NXP for future products now other people have Cortex devices out there.

It may be a cultural ST thing because their web site is also terrible!