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.

FDC2112: Unable to see/read result

Part Number: FDC2112
Other Parts Discussed in Thread: FDC2114

Hi,

we are trying to interface TI’s FDC2112 with one of our products. 

We tried configuring the IC as per the datasheet and were unable to see any result. We are able to read the Device ID properly.

We also referred a spreadsheet available on the TI site after referring TI blogs on issues with FDC2x1x ICs and discrepancies in the datasheet. 

The calculations as per the spreadsheet are different from that mentioned in the datasheet.

Even the spreadsheet configurations didn’t help.

 

Can you please help with the complete register settings for below sensor configuration:

C = 22pf

L = 9.4uH

Parasitic capacitance = 20pf

Sensor capacitance range: 0pf-40pf

Single channel configuration (Ch0).

Sample rate: 1sps is OK for us.

Internal oscillator as source for Fref.

Thanks and Best Regards,

KJV

  • Hello,

    Have you tried probing the IN0A and IN0B pins with an oscilloscope? If there is no oscillation it could be one of the following:

    • Device is in shutdown mode: 
      • Double check the SD pin of the device to make sure that it  is tied low for normal operation
    • Device is in sleep mode:
      • In the CONFIG register, set SLEEP_MODE_EN = 0. (bit 13 = 0 from address 0x1A)
    • IDRIVE settings are not set properly:
      • Increase the IDRIVE setting until you see an oscillation. This could be a sign of a low RP value for your sensor.

    If the device is already oscillating but you do not see data from the device, then check to make sure that your reference clock is set properly. If you do not have an external oscillator but you have the device configured for external oscillator mode then you will not get data. Set bit 9 of address 0x1A to 0 for internal oscillator mode.

    Once you get the inputs oscillating and sending data we can help recommend the rest of the settings. However a good starting point will be to set RCOUNT = FFFF and SETTLE_COUNT = 1024. Set all the divider settings  (FIN_DIVIDER, FREF_DIVIDER) to 1.

    Regards,

    Luke

  • Hi Luke,

    Thanks for the suggestions.

    I tried modifying the configuration as per your suggestions but the response that I get is the same.

    • I am able to read the device ID.
    • I am able to probe oscillations at the sensor input. When there is a contact near the sensor, the amplitude decreases.Please refer the below pictures.

    • When I try reading the status register(0x18), I get a response of 0x0002! I am using FDC2112 and the sensor is connected to CH0, why do I read 0x0002?
    • I always get 0x0000 as response when I read the register 0x00!

     

    Below is the code snippet:

    // Get the device ID

    ReadFDC2112( FDC2112_CMD_DEVID, rBuff );

       __delay_ms( 10 );  

    // Software reset

    ////// ConfigFDC2112( FDC2112_CMD_RESET_DEVICE, 0x8000 );

    ////// __delay_ms( 10 );

    // Configure the device

       // 0x841b   for 25ms sampling time

    ConfigFDC2112( FDC2112_CMD_REF_COUNT_CH0, 0xffff );//////0x0842 );

    ConfigFDC2112( FDC2112_CMD_OFFSET_CH0, 0x0000 );

       // 0x000a     7 but giving higher margin 10

    ConfigFDC2112( FDC2112_CMD_SETTLE_COUNT_CH0, 1024 );//////0x0002 );

       // 0x2002     00, 10 - %2 single ended 0.01 to 10MHz, 00, 0000000010 - Fref = Fint%2

    ConfigFDC2112( FDC2112_CMD_CLOCK_DIVIDERS_CH0, 0x1001 );//////0x2002); // All dividers set to 1

    // I Drive - 0x7800  0.146mA

    ConfigFDC2112( FDC2112_CMD_DRIVE_CURRENT_CH0, 0x7800 );

       // 0x0000  No intrs

    ConfigFDC2112( FDC2112_CMD_ERROR_CONFIG, 0x0000 ); // report only DRDYs to INT

       // 0x020d   0 - conti conv single ch, 00 - auto scan seq ch0 ch1, 0001000001, 101 - 10MHz

    ConfigFDC2112( FDC2112_CMD_MUX_CONFIG, 0x020d );

    // Put the device back in sleep mode

    ConfigFDC2112( FDC2112_CMD_CONFIG, 0x1c81 );//1c81 00 -continuous conv ch0, 0 - active, 1, 1 - low power mode, 1, 0- int osc, 0, 0 - INTB disable, 0 - normal current, 000001

    __delay_ms( 10 );

    // Check if the device was not properly set

    // Get the device ID

    ReadFDC2112( FDC2112_CMD_DEVID, rBuff );

       __delay_ms( 10 );    

       while( 1 )

       {

           ReadFDC2112( FDC2112_CMD_STATUS, rBuff );

    //////        if( rBuff[ 1 ] & 0x40 )

           {

               ReadFDC2112( FDC2112_CMD_DATA_MSB_CH0, rBuff );

           }

           __delay_ms( 1000 );

       }

     

     

    Best Regards,

    KJV

  • Hello,

    Thanks for the waveform capture. It shows that the sensor is not oscillating, which is likely due to the current drive setting of 0x7800 which corresponds to b01111: 0.146mA. It's likely that the Rp value of this sensor is too low to properly oscillate. First try setting this to 0xF800 which corresponds to b11111: 1.571mA. If you probe IN0A and IN0B, it should look like the following waveform:

    Also note that depending on the sensor frequency value you may need to use the OFFSET and GAIN registers. Refer to section 9.3.2.1 Gain and Offset (FDC2112, FDC2114 only) in the FDC2114 datasheet for guidance.

    Regards,

    Luke

  • Hi Luke,

    Thanks for sharing the sensor waveforms.

    I tried increasing the current drive as per your suggestion but the sensor behaves the same (as the waveform that I shared earlier).

    What could be the problem?

    Please find the circuit connections below:

    Best Regards,

    KJV

  • Hello,
    The schematic looks ok, however can you take another oscilloscope capture and zoom out a bit? Currently the horizontal resolution is only 50ns. Can you go to something like 10ms so you can see if the waveform you are capturing is periodic or just a random noise capture. Also, can you confirm some more about the sensor. Specifically that the sensor is not short circuited or open circuited. Also if the sensor is connected remotely, ensure that the distance is kept short and/or the wires used to connect back to the board are twisted.
    Thanks!
    Luke
  • Hello,
    As one added point. Can you confirm that the register settings you write are accepted by the device? Is it possible to read them all back to ensure this is the case? There may be a possibility that your 100kΩ pull up resistors are too large to properly communicate over I2C. Typically we use 4.7kΩ which allows the SDA/SCL lines to charge much quicker. You could try probing the I2C lines to confirm proper communication as well.
    Regards,
    Luke
  • Hi Luke,

    The sensor is now oscillating with the below configuration but the waveform is distorted:

    // Get the device ID
    ReadFDC2112( FDC2112_CMD_DEVID, rBuff );
    __delay_ms( 10 );


    // Software reset
    ////// ConfigFDC2112( FDC2112_CMD_RESET_DEVICE, 0x8000 );
    ////// __delay_ms( 10 );


    // Configure the device

    // 0x841b for 25ms sampling time
    ConfigFDC2112( FDC2112_CMD_REF_COUNT_CH0, 0x0842 ); //////0xffff );//////


    ConfigFDC2112( FDC2112_CMD_OFFSET_CH0, 0x00ff );//////0x0000 );

    // 0x000a 7 but giving higher margin 10
    ConfigFDC2112( FDC2112_CMD_SETTLE_COUNT_CH0, 0x0002 ); //////1024 );//////

    // 0x2002 00, 10 - %2 single ended 0.01 to 10MHz, 00, 0000000010 - Fref = Fint%2
    ConfigFDC2112( FDC2112_CMD_CLOCK_DIVIDERS_CH0, 0x2002); // All dividers set to 1//////0x1001 );//////


    // I Drive - 0x7800 0.146mA
    ConfigFDC2112( FDC2112_CMD_DRIVE_CURRENT_CH0, 0x8800 );//////0x7800 );//////0xf800 );//////

    // 0x0000 No intrs
    ConfigFDC2112( FDC2112_CMD_ERROR_CONFIG, 0x0000 ); // report only DRDYs to INT


    // 0x020d 0 - conti conv single ch, 00 - auto scan seq ch0 ch1, 0001000001, 101 - 10MHz
    ConfigFDC2112( FDC2112_CMD_MUX_CONFIG, 0x020d );


    // Put the device back in sleep mode
    ConfigFDC2112( FDC2112_CMD_CONFIG, 0x1c81 );//1c81 00 -continuous conv ch0, 0 - active, 1, 1 - low power mode, 1, 0- int osc, 0, 0 - INTB disable, 0 - normal current, 000001
    __delay_ms( 10 );

    // Check if the device was not properly set

    // Get the device ID
    ReadFDC2112( FDC2112_CMD_DEVID, rBuff );
    __delay_ms( 10 );

    while( 1 )
    {
    ReadFDC2112( FDC2112_CMD_STATUS, rBuff );
    if( rBuff[ 1 ] & 0x08 )
    {
    ReadFDC2112( FDC2112_CMD_DATA_MSB_CH0, rBuff );
    }

    __delay_ms( 1000 );
    }

    Any idea what could be the problem?

    Thanks and Best Regards,

    KJV

  • Hello,
    The distorted waveform is ok because your probe is measuring single ended. If you want to see the full oscillation then use a differential probe across IN0A and IN0B.
    Now that your sensor is oscillating, are you able to read data correctly?
    Regards,
    Luke
  • Hi Luke,

    We are able to read the data but are unable to see good sensitivity.

    Can you please help with the complete register settings for below sensor configuration, so as to improve the resolution and sensitivity:

    C = 22pf

    L = 9.4uH

    Sensor capacitance range: 0pf-40pf

    Single channel configuration (Ch0).

    Sample rate: 1sps is OK for us.

    Internal oscillator as source for Fref.

    Thanks and Best Regards,

    KJV

  • Hello,

    You need to adjust the OFFSET and GAIN values to get the sensor frequency in range of the 12 bit DATA register. To get the maximum sensitivity you will need to use a 4bit shift gain setting so you are looking at the 12 LSBs, which corresponds to setting OUTPUT_GAIN[10:9] = 0x3. According the oscilloscope waveform your frequency is around 9MHz. So if your reference frequency is 40MHz, this would produce a 16 bit value of 9/40*2^16 = 14,894, which is outside the 12 bit range. So you will need to use an offset value of around 13,000 to give a reading of 1894 which is a midrange value for the 12 bit window. Now since you are using internal oscillator mode the reference frequency isn't exactly 40MHz and also since you were probing the the pins, the oscilloscope probe adds some capacitance which slows the frequency down. So you may need to fine tune the offset a bit, but that's where I would start. Also since slower sample rate is ok, you should consider using the maximum RCOUNT value = 0xFFFF to get the lowest noise. 

    Regards,

    Luke LaPointe