UPGRADE YOUR BROWSER

We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

cancel
Showing results for 
Search instead for 
Did you mean: 
Observer cmuhlbauer
Observer
1,009 Views
Registered: ‎02-14-2018

SPI Automatic Slave Select Mode

When using SPI Automatic Slave Select Mode, it is not clear how the slave is selected.  In UG1087 (v1.6), Config (SPI) Register Bit-Field Summary, field "CS" description:

 

    "Peripheral chip select lines; valid only if [Manual_CS] = 1."

 

So how can the slave be selected when Manual_CS=0?  I think there is some missing information here.

 

 

0 Kudos
5 Replies
Xilinx Employee
Xilinx Employee
961 Views
Registered: ‎10-30-2017

Re: SPI Automatic Slave Select Mode

Hi @cmuhlbauer,

 

The Description for automatic slave select is given in ug1085 guide chapter 23 page number 633 (v1.8) please check the TRM.

Please check the below once also.

spi_slave.PNG

 

Best Regards,
Srikanth
----------------------------------------------------------------------------------------------
Kindly note- Please mark the Answer as "Accept as solution" if information provided is helpful.

Give Kudos to a post which you think is helpful and reply oriented.

0 Kudos
Xilinx Employee
Xilinx Employee
953 Views
Registered: ‎01-21-2013

Re: SPI Automatic Slave Select Mode

Hi @cmuhlbauer

 

In addition to @savula reply, in UG1085, you’ll see that the Manual Slave Select method is selected by software using the setting spi.Config [Manual_CS]

bit = 1.

Please review the section “Auto/Manual Slave Select and Start” in UG1085, under SPI Data Transfers as mentioned above.

 

An example that may also be useful for you can be found in the software install location, similar to <Xilinx>\SDK\2018.2\data\embeddedsw\XilinxProcessorIPLib\drivers\spips_v3_1\examples

 

Thanks,
Wendy
Xilinx Technical Support
-------------------------------------------------------------------------
Don’t forget to reply, kudo, and accept as solution.
-------------------------------------------------------------------------
0 Kudos
Observer cmuhlbauer
Observer
939 Views
Registered: ‎02-14-2018

Re: SPI Automatic Slave Select Mode

OK, maybe my post wasn't clear enough.  My problem is I don't know how to select between the three chip selects.  My guess would be to use the "CS" bits in the same way they are used for the Manual_CS, but UG1085 says these bits are only valid for Manual_CS.

0 Kudos
Moderator
Moderator
903 Views
Registered: ‎07-31-2012

Re: SPI Automatic Slave Select Mode

Hi @cmuhlbauer

 

Our PS SPI driver supports only manual CS and auto start .

You may need to write custom driver for auto SS replacing manual in register bit which is valid only for manual CS and do auto start ( i.e. transmit as soon as there is data in the TX FIFO) which would be straight.

 

If you want auto SS with manual start the sequence need to modify driver for auto SS selection as said above and need to use TX FIFO not empty flag for SS to toggle.

TX FIFO full to be used to not load data to TX FIFO.

 

Regards

Praveen


-------------------------------------------------------------------------
Don’t forget to reply, kudo, and accept as solution.
-------------------------------------------------------------------------
0 Kudos
Highlighted
Visitor yang_hailei
Visitor
578 Views
Registered: ‎07-08-2018

Re: SPI Automatic Slave Select Mode

I also have some question.

If the [Manual_CS] = 1 is just for manual sitiation. Do we need control the select lines?

If we need control the select lines, What is the meanning of the 'CS'? It sames excess. If we don't need control the select lines, I think the  [Manual_CS] should be changed as [Auto_CS]

 

CS:

Peripheral chip select lines; valid only if [Manual_CS] = 1.
xxx0: slave 0 selected
xx01: slave 1 selected
x011:
slave 2 selected
0111: reserved
1111: No slave selected

0 Kudos