Post Go back to editing

[CN0409] Calculate the level of water turbidity

Hi all,

I'm developing a Water Turbidity Sensor based on CN0409.

After got grateful help from @Yoleri Yigit I solved some of issues with ADPD1080 driver.

But, the return signal of photodiodes still too noises, details of issues I have been declare here:

I also have some other questions, please make me clearly understand it !

  1. After got the values from Data registers, The next step to calculate the Turbidity level is follow your formula ?


  1. In above formulas: the values of D2, D4, x, y are corresponding value of the data registers (0x64 to 0x6B) ?
  2. I seen the return signal too sensitive with the LED light source (May be the intensity of LED too high), in my application the LED and 2 photodiodes assembly too close, So I afraid that the result values always return zero. In this case, May I need to adjust the Time (LED_PULSE) and Time (LED_PERIOD) for reduce the light source or another solution ?

Thanks all !

  • Hi Lee,

    1. The above formulas are for non-ratio and ratio measurements, respectively. You are correct that the values in D2 and D4 can be directly obtained from registers 0x64 to 0x6B if the detectors are not saturated. For x and y, these are ratios of D2/D4 for the timeslot using LED1 or D4/D2 for the timeslot using LED2.

    2. The LED pulse and period affects the active time, average current. You can also decrease the current to the LEDs using the LED Control Registers for the LEDX_peak. However, increasing the LED current using the same methods increases the SNR of the measurement. Just be sure to operate below saturation. You can read more on this in the Optimizing SNR section in the ADPD1080 datasheet.

    I have checked the document in the link you sent and I have a couple of questions:

    • Are you using only one light source? The measurement for FTU using the equations above will be more accurate using two light sources.
    • When reading data from the ADPD1080, are you directly reading from the registers or are you using the FIFO? Also are you using the interrupt or non-interrupt method? It is possible that the registers were getting re-written before the read operation was completed.
    • Have you tried increasing the number of samples for averaging in register 0x15? In the document it is set to 8.
    • Can you describe your setup in terms of ambient lighting conditions? You can also check on using integrator chopping to add another "high pass filter" for the low frequency noise.



  • Dear

    Thank so much for your information !

    • Yes, I'm using one light source LED in my current design. The LED connected to LEDx1 and 2 photodiodes connected to PD1 and PD2. In my case, may I use the formulas like as CN0409 solution for calculate turbidity level ?
    • When reading data from the ADPD1080, I'm directly reading data from the registers (0x64 to 0x6B) and I'm using non-interrupt method to reading data.
    • I also increasing the number of samples for averaging in register 0x15 to 128 but It still not working. The SNR still too high.
    • Here is my setup for testing, the sensor probe just placed on the desk without any cover. I also Immerse the probe into the water, the result same as in the air.
  • Hi Lee,

    • Yes you can still use the formula from the CN0409 document to calculate turbidity.
    • Do you disable sample updates when you're reading the data in non-interrupt mode?
    • How high is the noise in your measurements? Also, can you send me the same charts in the images from the document in the google drive with the new settings you placed? We can check the effects of increasing the number of samples to average using it.
    • I am curious have you tried placing an object in between the LEDS and photodiodes in you probe? We can check for changes in the measurements.



  • Hi

    Yes, I have been disable sample updates when reading the data in non-interrupt mode.

    I also configure the ADPD1080 to working in TIA ADC MODE by following page 43 on the datasheet.

    But the return value is not like as describe on datasheet, please refer below document for more information about my inssues:

  • Hi Lee,

    I have checked the document that you linked. I think this is a problem with TIA saturation. I see that you have followed the TIA ADC mode section. Did you sweep the values for the AFE offset and to come up with the 22us value that you used?

    The saturation problem is a common issue when using large photodiodes such as the OPF430. What happens with the TIA in these situations is also described in page 43. Additionally, you should also set bit 7 of register 0x58 to enable the configuration of the integrator as a buffer in TIA ADC mode.