S32K SPI Transfer

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

S32K SPI Transfer

Jump to solution
543 Views
PhilVgt
Contributor II

Good Afternoon Community,

 

I'm trying to read Pressure/Temperature Data of a Bosch SMP581 Sensor using a S32K118 and S32 Design Studio (with Processor Expert).

The Sensor requires 16 Bits of data and exact 16 clock cycles while CS is set low.

After Power on, the sensor transmits (regardless the Master Comand) a fixed 16 Bit Word in first Transfer. This is working and the received data are as expected.

AFter this first transfer, the master must send 1 of 4 possible comands, for example 0b0101000000000000 to get Temperature data. 

If i send this comand, i don't get an answer. If i set LSB to 1 (0b0101000000000001) i get "invalid Comand) as answer (as expected). Even if i send 0b0101001, i get the same answer. 

But i get only an answer, when i set the "1" as LSB. Otherwise no response.

I tried dozens of different settings and delays, but everything leads to no answer (even for start up). Seems alle the settings are fine.

 

PhilVgt_0-1707926774753.png

 

 

Could anyone support me in this case to solve this issue?

 

Thanks in advance!

Tags (2)
0 Kudos
1 Solution
485 Views
PhilVgt
Contributor II
0 Kudos
3 Replies
486 Views
PhilVgt
Contributor II

Problem solved.

0 Kudos
527 Views
VaneB
NXP TechSupport
NXP TechSupport

Hi @PhilVgt 

According to the information provided, it seems that the SPI behavior is as expected, but communication with the sensor is not being achieved properly. Please make sure that the module configuration matches the specifications of your sensor.

Also, if you observe with an oscilloscope the SPI signals, did you see any irregularity? 

 

B.R.

VaneB

0 Kudos
524 Views
PhilVgt
Contributor II

Hi VaneB,

 

Thanks for your fast reply. I did not have the chance to check the signals with an oscilloscope yet and it will be quite hard to do that (only possible connection would be the small test points of the ECU). But it seems to be necessary.

Nevertheless, I attached the datasheet of the sensor. I'm using the 16 Bit "out of frame" device (I'm not sure what it actually means). Do you see any special required settings?

 

Thank you for your support.

Note: The attached file was removed due to IP concerns, our apologies for the inconvenience.

0 Kudos