cancel
Showing results for 
Search instead for 
Did you mean: 

Knowledge Base Articles

Measuring the parasitic capacitance with the effect of shield electrodes in PSoC(TM) Creator - KBA233929

Chelladurai
Community Manager
Community Manager

Measuring the parasitic capacitance with the effect of shield electrodes in PSoC(TM) Creator - KBA233929

Version: **

When the CAPSENSE™ shield is enabled, the shield hatch is driven to the same potential as the sensors during the charging and discharging cycle. This reduces the parasitic capacitance of the sensors. However, while using the built-in-self-test (BIST) feature of CAPSENSE™ in PSoC™ Creator IDE to determine the sensor parasitic capacitance (Cp), the shield electrodes are inactive.

The parasitic capacitance is measured with the following options:

  • Call the CapSense_SsCSDEnableShieldElectrodes()API before measuring the sensor’s Cp to measure the Cp of the sensor with the effect of shield

    Following is the API call sequence:
    CapSense_TST_MEASUREMENT_STATUS_ENUM msrptr; //Variable to check the status returned.
    CapSense_SsCSDEnableShieldElectrodes();
    uint32 val = CapSense_GetSensorCapacitance(CapSense_BUTTON0_WDGT_ID, CapSense_BUTTON0_SNS0_ID,&msrptr);

  • Call the  CapSense_SetInactiveElectrodeState(CapSense_BIST_CSD_SNS_CAP_E, CapSense_SNS_CONNECTION_SHIELD); API to set the inactive sensors as shield.

    Following is the API call sequence:
    CapSense_TST_MEASUREMENT_STATUS_ENUM msrptr; //Variable to check the status returned.
    CapSense_SsCSDEnableShieldElectrodes();
    CapSense_SetInactiveElectrodeState(CapSense_BIST_CSD_SNS_CAP_E, CapSense_SNS_CONNECTION_SHIELD);
    uint32 val = CapSense_GetSensorCapacitance(CapSense_BUTTON0_WDGT_ID, CapSense_BUTTON0_SNS0_ID,&msrptr);

    Note: Setting the inactive sensors to shield also has an impact on the sensor’s Cp if the sensors are placed close together.

  • Call the CapSense_SetInactiveElectrodeState(CapSense_BIST_CSD_SH_CAP_E, CapSense_SNS_CONNECTION_SHIELD); API, if the capacitance of the shield electrode needs to be measured while the inactive sensor connection is a shield.

    Following is the API call sequence:
    CapSense_TST_MEASUREMENT_STATUS_ENUM msrptr; //Variable to check the status returned.
    CapSense_SetInactiveElectrodeState(CapSense_BIST_CSD_SH_CAP_E, CapSense_SNS_CONNECTION_SHIELD);
    val = CapSense_GetShieldCapacitance(&msrptr);

    Note: The first parameter in the CapSense_SetInactiveElectrodeState API is changed to CapSense_BIST_CSD_SH_CAP_E in this case.

 

0 Likes
Version history
Revision #:
1 of 1
Last update:
‎Sep 27, 2021 11:54 PM
Updated by:
 
Contributors