cancel
Showing results for 
Search instead for 
Did you mean: 

Question about GPIO port defined as AF

romey
Associate II
Posted on December 04, 2012 at 19:17

I noticed on the STM3210E-EVAL board design and in the demo code GPIO port A was defined as AF for SPI1 and for USART. The chip select pin for the SPI flash memory was defined as pin 2 in GPIO port B. Does it mean once port A is defined as AF, all the pins have to be AF? Can I define Port A poin 4 as SPI flash chip select?

2 REPLIES 2
Posted on December 04, 2012 at 19:24

AF is Alternate Function, ie Controlled by the peripheral

It is a per-pin designation.

The Chip Select uses a GPIO mode so it can be controlled manual, rather than by the peripheral.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
romey
Associate II
Posted on December 04, 2012 at 20:53

So it's OK to define Chip Select on the same port A. Many thanks for the quick reply.