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.

Working of AFE4490

Other Parts Discussed in Thread: AFE4490

Hi,

Can anyone over here, explain about the Timing of the LED's ?

How to enable 2 LED's in SFH7050 alternatively  ?

What's the setting for that ? ( I meant on which Registers) ?

Actually I am getting RED LED always ON on SFH7050 Sensor.

I am able to read only 2 0r 3 values for some time on the last 2 registers, after subtraction from the Ambient component.

Why it is not able to read continuous data ? can anyone give suggestion on this please.

  • Hello Harini,

    Refer to Table 2, Figure 63 and Figure 64 of the AFE4490 datasheet to understand how to program the start and end instants for turning on/off the 2 LEDs, sampling, ADC reset and conversion phases along with the information on which registers to program.

    You will need to read the ADC data based on the ADC_RDY signal. At the rising edge of the ADC_RDY signal, the contents of all six ADC result registers can be read out.

    Depending on the pulse repetition frequency, you may not be able to visually notice the LEDs toggling.
  • Hi Praveen,

    Thanks for the reply. Why no reply, for any of the private messages ?

    What is that Conversion of LED2 & LED1 Phase exactly refers to ?

    Is that, ADC_RDY signal is must to access the ADC Registers.

    Actually I am able to read only 2 or 3 values from the last 2 ADC Registers, without the access of ADC_RDY Signal..

    Actually in my case, ADC_RDY signal is connected to one of the Port of the Microcontroller, not the Interrupt Pin.

    Can I read the same signal & access the ADC Values or not possible ?

    What should be the value of PRF & PRPCOUNT value for the AFE4490 ?

  • Hello Harini,

    LED2, LED1, LED2_amb, LED1_amb convert phases refer to the conversion done by the ADC on the voltage sampled on the Cled2, Cled1, Cled2_amb, Cled1_amb capacitors during the respective sampling phases.

    Yes we recommend using the ADC_RDY signal to access the ADC registers.
    The AFE updates the ADC data to the respective ADC registers based on the ADC Reset signals. (Refer Figure 71 from AFE4490 datasheet).
    If you are reading the ADC registers at arbitrary intervals, you might end up reading the ADC registers while the ADC is updating the registers or read incorrect samples.

    Could you elaborate more on what you meant by read only 2 or 3 values from the ADC registers?

    PRF refers to the Pulse Repetition Frequency. It is the rate at which samples from each of the four phases are output from the AFE.
    With PRF = 500Hz, the AFE outputs 500 samples per sec.

    PRPCOUNT refers to the high count value that sets the PRF with 4MHz internal AFE clock.
    So for PRF = 500Hz, with CLK_ADC = 4MHz, PRPCOUNT = 8000 - 1. (-1 is since the count value begins from 0)
  • Hi Praveen,

    How to check ADC Register Values w.r.t ADC Reset Signals & ADC_RDY ?

    Please tell me on this briefly w.r.t both Hardware & Software Settings ?

    ADC_RDY signal has to be accessed only w.r.t Interrupt ? Can't this be done, with any other port connection &  reading it ?

    And I meant, about reading 2 or 3 values, i.e., Readings from these 2 registers, LED2-ALED2VAL & LED1-ALED1VAL I can get only0 twice or thrice data & other readings or zero's..

    Please help me on reading the ADC Register Values..

    Waiting for your kind reply.

    Thanks & Regards,

    Harini B

  • Hello Harini,

    Please refer to section 8.4.1 of the AFE4490 datasheet for an understanding on how the AFE updates the ADC results to the respective registers. I would highly recommend to comprehend the AFE4490 datasheet (especially section 8) to get an understanding how the AFE4490 device functions.

    The active high pulse (125ns) on the ADC_RDY signal during every PRF indicates to the host processor that the ADC results can be read out through SPI. Providing this low dutycycle signal to a non-interruptible GPIO on the host processor is not a feasible option.

    Regarding reading only 2 - 3 valid values,
    1. how many samples did you read?
    2. do you read the ADC result registers based on a timer (set to PRF) running on the host processor?
    3. Can you monitor the ADC_RDY signal on the oscilloscope?
    4. Could you also check if the AFE is inadvertently being programmed/configured to
    a. stop the timer
    b. be in write mode
    c. powerdown the RX etc.
    5. Is the optical sensor always turned on even when you are reading zeros from the ADC result registers?
    6. What are the contents of other ADC result registers (reg 42 through 45)?
  • Hi Praveen,

    Okay Thanks for such a clear explanation.

    1. I am reading the all the Registers continuously, connecting to the UART. I am not able to get how many samples ? How to get to know that ?

    2. Yes I guess. I have written PRPCOUNT = 0x001F3F & doing it ? Is that correct ?

    3. Nope I didn't do that. I am just checking ADC_RDY signal value, in main program inside the while(1) loop.

    4.

    5. Yes SFH is always, even while reading the data.

    6. All registers from 42 to 45 are reading the same value. (For Eg., E0 00 E9)