This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

ADS8584S: ADS8584S in serial mode frozen output

Part Number: ADS8584S

I'm trying to sample 4 channels at around 100ksps using an ADS8584S in serial mode with an STM32H7 microcontroller. I got it working fine at low sampling rates (accurately sampling a dc voltage) and briefly at 100 ksps it was putting out accurate data into my spi buffer, but after I tried to add some signal processing code the data stopped making sense. I looked on the scope and it was still outputting bits on the clock edges I was providing, but those bits didn't change in response to the voltage at the analog inputs. It kept doing this even after I reverted my code to the working version from earlier. I'm wondering if there's some kind of shutdown mode or error message that's causing this? Thanks so much!

  • Hi Bobby,

    Welcome to TI E2E forum.

    Can you please post your SPI timings captured with a scope or logic analyzer? What kind of code did you add?

    BR,

    Dale

  • https://drive.google.com/file/d/1KzBLmfPJ2KugAqcB6VlBiYuuOrHuoBjs/view?usp=sharing

    https://drive.google.com/file/d/1KzBLmfPJ2KugAqcB6VlBiYuuOrHuoBjs/view?usp=sharing

    Hi Dale, thanks for the response. The images above show traces from my spi conversation - the yellow on top is CONVST, blue is data out from the ADC, and purple is the chip select (clock isn't shown). Both are for the same input voltage to the ADC, but in the first image its giving the "frozen" response that I keep seeing even when I change the input voltage. The second one is where it actually seems to be giving accurate values when I decode it. 

    As far as firmware, I'm generating CONVST and chip select with two synchronized timers, and then using that same timer to trigger a HAL spi driver function: 

    void HAL_TIM_PeriodElapsedCallback(TIM_HandleTypeDef *htim) {
    	if (telemetry_update_counter >= 150){
    		HAL_SPI_Receive_DMA(&hspi1, spi_rx_buffer, BUFFER_SIZE);
    		telemetry_update_counter = 0;
    	} else {
    		telemetry_update_counter++;
    	}
    }

    Because of how fast I'm sampling, calling HAL_SPI_Receive_DMA() for each sample of the ADC takes too long, so instead I'm trying to call it once with a really long buffer which hopefully I'll be able to splice later. 

  • Oh wait I sent the same image twice. This is the frozen one where its not responding to changes in voltage: https://drive.google.com/file/d/1IF2gDAQZ4SxYt79Sig-5Gz6Nt0w39-wk/view?usp=sharing

  • Hi Bobby,

    We can not access google drive. Please upload your timing directly. Also, the primary support engineer will come back to office next Tuesday because of holiday in the US, so please allow a delay on response.

    Thanks&regards,

    Dale

  • Did that work? The one on the right is what I don't want - for some reason it always starts with a bunch of 1s no matter what the voltage being measured is. 

  • Hi Bobby,

    Thanks for your response and patience. It looks like you have a lot of ringing on your SPI lines. Do you have any damping resistors on the SPI lines to reduce this ringing?

    Additionally, where are you getting the HAL_DMA function? Instead of a loop, could you try only calling the function once or twice?

    There are a few different modes of operations (including shut down mode) defined for this device in the datasheet section 8.4.2.1. Could you let me know if it is possible the device may be entering any one of these? Apart from that, a reason the new samples are not showing up is because the ADC is not registering the CONVST signal correctly. On power cycle, does the ADC resume correct operation?

    Best regards,

    Samiha

  • Hi Samiha, 

    I forgot to add damping resistors to the SPI lines but I definitely will for future iterations, thanks for pointing that out. I think the issue had to do with my reset signals to the ADC - I changed some things to make them cleaner and more spaced from subsequent data reads and everything is working fine now at 125 ksps. Thanks so much for the help!