how to send 32 bit data with S12 SPI

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

how to send 32 bit data with S12 SPI

840 Views
keli
Contributor I

Hi, there,

 

I need to send 32 bit data through SPI. I am using s12P. The datasheet says 8 or 16 bit transfer width. any thought?

Labels (1)
0 Kudos
3 Replies

523 Views
iggi
NXP Employee
NXP Employee

Hello,

you should use GPIO pin on the Master to toggle SS line (Slave Slelect, Chip Select) of the Slave and send two packets of 16-bit data or 4 packets of 8-bit.

Note that SS line on Slave is active low. When the transfer finishes, toggle it high.

Hope it make sense.

Regards,
Ivan

523 Views
keli
Contributor I

Ivan,

Thanks for your response. That was the first thing pop up in my head. I am thinking of timing and reduce the overhead of CPU. Lock the interrupt may hurt other tasks. Driven by interrupt may introduce unexpected timing jitter. If the module could do the job, that would be wonderful.

0 Kudos

523 Views
iggi
NXP Employee
NXP Employee

Unfortunately, there isn't a 32-bit buffer, so SPI data width is 16-bit max.

0 Kudos