This is a expected behavior. I believe you are using self-cap based sensing. In self-cap based sensing, when you increase sensor capacitance, raw count increases. When you reduce sensor capacitance, raw count decreases.
In your case, when the sensor was connected, the CapSense component automatically calculates the IDAC based on the sensor's parasitic capacitance. When you remove the sensor, the IDAC is still the same, but there is no parasitic capacitance. Therefore, you get lower raw count (or 0 if the capacitance decrease is very high).
Why do you connected and disconnect the sensor?
Our project needs to disconnect and connect the sensor,because we need to allow users to change broken sensor.
We use two sensors,one is big and the other is small.
Under normal circumstances,when we remove two sensors together.The big one's raw count is very small like 10,20,the small one's raw count is larger like 2000,3000.And when we connect the sensor,raw count will return to normal.
But sometime I disconnect the sensor,two sensors' raw counts turn into 0 together or the big one's raw count is normal(10,20) but the small one's raw count is 0.And when we connect the sensor,raw count will not return to normal and still is 0.
How should I solve this problem?
Many thanks in advance,
Are you using the board to detect a faulty sensor module? Just want to understand your application so that i can suggest the right method.
For these kind of applications, you should disable auto calibration and set the IDAC value manually.
Could you please post the zip file of your project?