ADS8674: Noisy sample readings occur every few minutes

Part Number: ADS8674

Tool/software:

Hi there,

I am using 2x ADS8674 to measure two batteries as they discharge. Some of the channels are being used to measure current and some are being used to measure battery voltage. 

I am using the CS lines to query each ADS8674 sequentially on the same SPI bus. Every minute or two I am getting a voltage reading that is about 20mV above or below the true battery voltage from the ADS8674. The current readings are very stable so it would appear that the SPI communication is working well (at least for the current channels). 

I am sampling (getting a new sample every 500uS) at 2KHZ and communicating at 12 mhz.  I have tried experimenting with a lower frequency (e.g 6 mhz) but the phenomon still occurs. Also if it were a communication issue I would assume the readings would not only be within the 20mV I am getting.

My question is why I keep getting these sporadic fluctuations? I have checked the SPI signals and CS lines with an oscilloscope and everything seems pretty clean and timing is according to the datasheet. Note that the input to the ADC also has some filtering so that should take care of noisy signals. In the diagram below I am using Ch3 and Ch2 to measure the voltages (at the plus and minus of the battery terminals) and Ch1 and Ch0 to measure the currents at two different points. Below is shown one ADC, there is another identical ADC connected to the same SPI bus. 

The below time span recording in CCS is about 10 minutes:

Note that this phenomenon occurs on both ADCs voltage channels only. Current readings are clean.

Thanks in advance for your  help.

  • Hi Steven!

    So, just to clarify, you see the same behavior on both voltage channels (CH2 and CH3) from both ADC's?  In the CCS plot, is the Y axis Voltage (3.294V to 3.350V)?  Are the spikes in the graph the issue you are dealing with?

  • Hi Tom,

    Thanks for your quick reply. Yes, your summary/assumption is correct. That is the correct voltage range as well, and the issue is the spikes.

    I am not sure if it helps but I am querying the ADC every 500 uS with the below code:

    //

    ch0_voltage_mV[0] = spi_SendCmd_ADC(0xC400,0);//set to manual mode ch1, we read from channel 0 here
    ch1_voltage_mV[0] = spi_SendCmd_ADC(0xC800,0);//set to manual mode ch2, we read from channel 1 here
    ch2_voltage_mV[0] = spi_SendCmd_ADC(0xCC00,0);//set to manual mode ch3, we read from channel 2 here
    ch3_voltage_mV[0] = spi_SendCmd_ADC(0xC000,0);//set to manual mode ch0, we read from channel 3 here


    ch0_voltage_mV[1] = spi_SendCmd_ADC(0xC400,1);//set to manual mode ch1, we read from channel 0 here
    ch1_voltage_mV[1] = spi_SendCmd_ADC(0xC800,1);//set to manual mode ch2, we read from channel 1 here
    ch2_voltage_mV[1] = spi_SendCmd_ADC(0xCC00,1);//set to manual mode ch3, we read from channel 2 here
    ch3_voltage_mV[1] = spi_SendCmd_ADC(0xC000,1);//set to manual mode ch0, we read from channel 3 here

    //

    This adc function looks like:

    uint16_t spi_SendCmd_ADC(uint16_t arg, uint8_t device)
    {
    uint16_t ret = 0x0000;
    //MSB bit IE left bit of ARG is sent first.
    uint8_t i = 0x00;
    //SD_CmdAnswer_typedef retr = {0xFF, 0xFF , 0xFF, 0xFF, 0xFF};
    uint16_t frame;

    frame = arg; /*!< Construct 16bit command message */

    adc_cs_on(device);

    SPI_writeDataNonBlocking(SPIA_BASE, frame);
    RxData_SPIA[0] = SPI_readDataBlockingNonFIFO(SPIA_BASE); /*!< Read return 16 bit data, no data expected yet */
    SPI_writeDataNonBlocking(SPIA_BASE, 0x00);//dont care
    RxData_SPIA[1] = SPI_readDataBlockingNonFIFO(SPIA_BASE); /*!< Read return 16 bit data */


    ret = (RxData_SPIA[1]>>2)&((uint16_t)(0x3FFF)); //data is only 14 bits (MSb of 14 bits starts at 16 bit)


    adc_cs_off(device);

    return ret;

    }

  • Thank you Steven for verifying.

    It looks like you are perhaps in some sort of charge/discharge cycle?  What causes the (what seems to be a) consistent RC rise/fall times?  It's a little odd to me why the spikes are fairly consistent in magnitude as well with the majority of them occurring right around the 3.312V level.  Is there any periodic switching in your setup?  Something that might cause an occasional glitch on the CS line by chance?  There is nothing inside the ADS8674 that I can think of that would cause this to happen.

  • Hi Tom,

    Sorry for my late response as I was on vacation. This is indeed a battery discharge cycle.

    What is strange to me is that I don't get the reading glitches on the current channels. I tried switching the read order around in case the start/end of the ADC read sequence is causing problems but I still don't get glitches on the current lines and still get glitches on the voltage lines. 

    I also added stronger pull downs on the ADS8674 SDO lines (from 100K to 10K) but this had no effect. (I am reading the two ADS8674 SDO outputs via an OR gate).  

    I also cannot think of anything that would cause a CS glitch. If this were to occur I would expect an issue on the current signals as well? 

    It is a bit of a headscratcher but please let me know if you think of anything else I can try. 

  • Hi Steven,

    No worries - a lot of folks were out last week.  If you look at your raw data, do all of the spikes start around the same voltage levels as I noted above?  Can you let me know what input voltage range you are using for current and voltage channels?  Is there any timing skew going through your isolators? 

  • Hi Tom,

    Just to let you know I have now put this issue down to a float conversion problem which appears to be a silicon errata issue for the f280025c. I will open this up on the appropriate forum. Thanks again for your help.  

  • Interesting - let me know what you find out in the end.