cancel
Showing results for 
Search instead for 
Did you mean: 

PSoC 4

Anonymous
Not applicable

Hello I'm new in this forum

   

I'm trying to use the get_sensorcp(); API but  I don't know how can I look for the result. I looked in the datasheet but I don't see

   

any example, please help.

0 Likes
1 Reply
Bob_Marlowe
Expert II

Welcome in the forum.

   

Excerpt from datasheet:

   

uint32 CapSense_GetSensorCp(uint32 sensor)
Description:
This API returns the Cp (parasitic capacitance) of sensor in pF (pico farads).
The supported range is 5-100 pF. The precision of API is +/-10%.
Note This API can be used to measure a capacitance of the external capacitors. In this case the parasitic capacitance should be subtracted from the total result.
Parameters:
uint32 sensor: Sensor number. The Capsense.h file contains defines for the sensor numbers. See the Sensor Constants section for details.
Return Value:
uint32: This API returns Sensor parasitic capacitance (Cp) of the sensor indicated as argument. The unit of sensor Cp value is pico-farads.
Side Effects:
Sensor scan should be complete before using this API.

   

What more do you need? An uint32 is returned.

   

 

   

Bob

0 Likes