1

I have interfaced a sensor to my imx6 processor which has a linux kernel. I am using spi protocol. the driver code for spi operation i am using is this_link . But my sensor registers are of 24-bits. I am trying to use the same code for reading and writing data to my sensors. I am not getting the proper values after reading. I have written a value of 6000 into a register then when i am trying to read it, i got a value 16777215 (i.e. all 3bytes are high). Can anyone please let me know where i am going wrong? And could anyone tell me how can i check what data is written in the registers other that using read()?

Regards,

Sathya Prasad P

Sathya
  • 23
  • 3
  • Often, in this scenario I will use a logic analyzer to verify that the protocol is correct. You can check the waveforms against the sensor's spec sheet, and also at the same time ensure that the connections are setup correctly. – nneonneo Dec 17 '14 at 03:34

0 Answers0