- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
i design a pcb of touch button, how do i know the button was touched, and if i want long touch key and short touch key , what should i do ?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi David,
If you are using CapSense_CSD v2.x, you can use CapSense_sensorOnMask[], This is a uint8 array that holds the sensor 'on' or 'off' state (for buttons, matrix buttons or sliders). CapSense_sensorOnMask[0] contains the masked bits for sensor 0 through 7 (sensor 0 is bit 0, sensor1 is bit 1). CapSense_sensorOnMask[1] contains the masked bits for sensor 8 through 15 (if they are needed), and so on. This uint8 array contains as many elements as are necessary to contain all placed sensor. The value of a bit is 1 if the sensor is on and 0 if the sensor is off.
If you are using CapSense_CSD v3.x/4.x/5.x, you can use the struct instance: CapSense_dsRam.snsStatus[wdgtId]. Its prototype is defined in CapSense_RAM_STRUCT in CapSense_Structure.h.
Either long touch or short touch, requires customized code to identify it.
Thanks,
Ryan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi David,
If you are using CapSense_CSD v2.x, you can use CapSense_sensorOnMask[], This is a uint8 array that holds the sensor 'on' or 'off' state (for buttons, matrix buttons or sliders). CapSense_sensorOnMask[0] contains the masked bits for sensor 0 through 7 (sensor 0 is bit 0, sensor1 is bit 1). CapSense_sensorOnMask[1] contains the masked bits for sensor 8 through 15 (if they are needed), and so on. This uint8 array contains as many elements as are necessary to contain all placed sensor. The value of a bit is 1 if the sensor is on and 0 if the sensor is off.
If you are using CapSense_CSD v3.x/4.x/5.x, you can use the struct instance: CapSense_dsRam.snsStatus[wdgtId]. Its prototype is defined in CapSense_RAM_STRUCT in CapSense_Structure.h.
Either long touch or short touch, requires customized code to identify it.
Thanks,
Ryan