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.

ADS1015: Single shot wait time, averaging, hardware vs software comparator

Part Number: ADS1015

Tool/software:

I'm working on a project that includes an ADS1015 ADC. 

I've read here that single shot mode is preferred over continuous mode so I was wondering which is the best way to wait for the conversion to complete. 

I have a function that checks bit 15 for a 1 or 0 to see if the ADC is still busy. Is this the best way to wait for the conversion to complete? Or should I just use a static delay based on sample rate? Or maybe even use the alert pin to alert the MCU when the conversion is complete?

My second question is about averaging samples to weed out any noise in the signal. I am currently taking 10 samples and averaging the sum but I was wondering if there might be a better way to do this. 

And lastly, what advantages is there to use the built in hardware comparator vs just using the mcu to check against the same constraints. So far I have just use single-shot measurements to do everything but my design does have the alert pin connected to the MCU so I could use it if needed. 

Thank you!

  • Hi DBC,

    1)

    As you mention, there are multiple ways to monitor for when new conversion data is ready. 

    You can determine data is ready through hardware by configuring the ALERT/RDY pin as a conversion ready pin, and monitor the pin for when data is ready by setting up an Interrupt Service Routine in your MCU that detects changes in the ALERT/RDY pin.

    You could also set up a polling routine through software that monitors the configuration register (bit 15) to determine if a conversion has completed. 

    Delaying based on the sample rate and then reading the conversion result also works, but may be a bit harder to verify if the result read is new, compared to the previous methods described. It is best to add a bit of extra delay to account for the +/-10% Data Rate variation. 

    All methods are valid, it just depends on what method you wish to implement for your application.

    2)

    Taking multiple measurements and averaging them is a valid approach.

    Since the ADS1015 is a delta sigma converter, it works on the principle of over sampling and noise shaping to reduce noise.

    This means that using the highest OSR setting, or 128SPS in this case will have the lowest noise levels. 

    You can learn more about the operation of delta sigma ADC's here: Precision labs series: Analog-to-digital converters (ADCs) | TI.com

    Also using anti-aliasing input filtering and following good PCB layout guidelines is recommended for best performance of the device. 

    3) 

    I can't think of any inherent advantages of using the ADC's comparator vs the MCU if you are already collecting the data, other than offloading some of the MCU's processing, but shouldn't make much of a difference. Just different approaches

    Best Regards,

    Angel