i.mx8dxl - lpspi - using 3 chip select lines on the same bus (2 native and 1 gpio)

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

i.mx8dxl - lpspi - using 3 chip select lines on the same bus (2 native and 1 gpio)

302 Views
davisroman3
Contributor III

Hello,

We're using i.mx8dxl and the reference manual says that lpspi only supports two native chip select lines per bus. We have a use case where we need 3 chip select lines on the same bus. ( No, it is not possible for our hardware team to route 2 chip select lines on one spi bus and another chip select line on another spi bus).

We've read that it is possible to use gpio as a chip select line. Are there any disadvantages of using the two native lines along with one gpio chip select line on the same bus? Will I need to run the clock at a lower rate because one of the chip select lines is a gpio?

Do you have an example for how to configure an lpspi with 2 native chip select lines and 1 gpio chip select line?

 

 

0 Kudos
3 Replies

279 Views
Chavira
NXP TechSupport
NXP TechSupport

Hi @davisroman3!
Thank you for contacting NXP Support!

Sorry, we don´t have examples for that configuration, but is possible.

Please check the property "cs-gpios" in the Linux Documentation, in the link below you can find the documentation for the implementation.

https://github.com/nxp-imx/linux-imx/blob/770c5fe2c1d1529fae21b7043911cd50c6cf087e/Documentation/dev...


Best Regards!
Alejandro

0 Kudos

267 Views
davisroman3
Contributor III

This is good information however what is the trade off when using a gpio chip select over a native chip select?

0 Kudos

253 Views
Chavira
NXP TechSupport
NXP TechSupport

Hi @davisroman3!

The difference in the cs is the way that is asserted.

The native cs is configured and asserted by the hardware implemented on the chip and the gpio used as a cs are solved by software in this case by Linux.

Best Regards!
Chavira

0 Kudos