I have configured MibSPI for master comms to an external ADC (8 channels, 12 bits), SPI Configuration is done in mode 1, frequency 400kHz, word size 16 bit. Format of the word: typical 8 bits output data with ADC channel address to read + 8 bit 0x00 to retreive ADC result).
On the test bench, the ADC is forced to 0V in all channels. So the answer on the MISO is consistenly 0xF000 for all channels. Frames check on a logic analyzer consistenly show 0xF000 shwoing the conversion done at the ADC. The edges are sharp and it really does not seem there could be a HW issue (I have set the freq real slow).
The problem is that when I look in the MultiBuffer Ram RXDATA, some times (let's say 70% of the transactions) I get a wrong value: 0x3800 or 0x7800. Instead of the 0xF000 seen on the scope. It really looks like as if the module is "shifting" right the RX word before storing it in MultiBuffer Ram RXDATA,
The ctrl part of the MultiBuffer RAM is showing a 0x000F which tells me no errors are detected. I have checked no loop-back mode is set. And honestly speaking I am quite lost at this point. Any hint on what to look for, or registers to check would be appreciated.
Regards,