ADC SPI issue


I am using a RCM3200 core for interfacing to TI ADS8345 SPI ADC. To initiate the conversion, I need to send the control byte and then after a gap of 1 SCLK, I need to read in 2 bytes. Simple operation! Being my first time using the Rabbit, it certainly has been anything but that. I tried modifiying a sample SPI code for my ADC but I have not been able to achieve my objective. The issues I face are:

  1. Viewing the clock pulses on a scope for a single write, I could count only 7 pulses rather than 8. Reasons??

  2. I tried to output different values on the DOUT but the output remained high; hence not allowing me to send the control byte.

Help me out fellows.



I am having the same issue with a ADC7806 12 ADC SPI chip. I found that I need to BitWrPortE to get the control bit to go from 0 to 1, like that problem you were having.

I also seem to only get 7 bits out of the ADC, it shifts everything to the left by one so my values are doubled, but I think there are bits missing as well, so a simple shift registers won’t do the trick.

I think it has something to do with the polarity of the clock signal, when I change this in the rabbit io lib utility, it seems to reset everytime I reopen the library.

There has to be an easy explanation of this. If anyone has experience reading 2 bytes from a SPI ADC, please help!!!