SPI config

cancel
Showing results for 
Search instead for 
Did you mean: 

SPI config

453 Views
Contributor I

I was using FRDM-KL25Z SPI example code but it seems like it is only limited to 8 or 16-bit data. Is there any other way I can use other method maybe using GPIO and create a 24 or 32bit data instead?

Benson

0 Kudos
4 Replies

1 View
NXP TechSupport
NXP TechSupport

Hi Benson,

I think you have to use the GPIO to simulate the SPI if you want to achieve the 24 or 32 bit serial frame size.
Have a great day,
Ping

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos

1 View
Contributor I

Do you know any example code that use GPIO to simulate SPI?

Benson

0 Kudos

1 View
Senior Contributor III

I put some optimized full GPIO SPI code in:

Confirming K22F Clock Frequency

0 Kudos

1 View
Senior Contributor III

You should be able to use the SPI hardware/code like it is, EXCEPT you just control the slave Chip Select with manual GPIO commands to enclose 'as many transfer sections' as need to be considered by the slave as 'one transaction'.

0 Kudos