Hi, I am trying to configure my SPI2 port for operation using processor expert. But I see that there are already designated CS pins for operation. Could I configure the TCR register with PCS[0:3] and initiate transfer and manually control another GPIO pin as CS by pulling low? If so, what is the effect on the pin specified in the PCS field of the TCR register?
It is a possible but somewhat overcombined way. SPI transfer is initiated when CS is low but according CLK clock.
If you drive CS line manually by general purpose output, content of TCR[PCS] is irrelevant.
But the TCR[PCS] points to some CS line always. Which means the line being pointed will get low whenever a transfer is initiated. Or is there a configuration on the SPI registers where it can ignore the TCR[PCS] setting?
Yes, but it is internal signal. If there is no routing done by PORT module (this internal signal to pin), it does not have any relevance.
If I understand this correctly, if the pin is not routed as ALT function to serve as PCS using the PORT engine, then this TCR[PCS] shall not have any effect on the pin.
Yes, you are right.
Kudos, thanks for the quick support!