CAPSENSE™ Middleware Library 5.0
cy_stc_capsense_widget_config_t Struct Reference

Description

Widget configuration structure.

Data Fields

cy_stc_capsense_widget_context_tptrWdContext
 Pointer to context structure of this widget.
 
cy_stc_capsense_sensor_context_tptrSnsContext
 Pointer to the first object of sensor context structure that belongs to this widget.
 
const cy_stc_capsense_electrode_config_tptrEltdConfig
 Pointer to the first object of electrode configuration structure that belongs to this widget.
 
uint32_t * ptrEltdCapacitance
 Pointer to the first object in the electrode capacitance array that belongs to this widget.
 
uint32_t * ptrSnsCapacitance
 Pointer to the first object in the sensor capacitance array that belongs to this widget. More...
 
uint16_t * ptrBslnInv
 Pointer to the first object in the sensor baseline inversion array that belongs to this widget.
 
cy_stc_capsense_smartsense_csd_noise_envelope_tptrNoiseEnvelope
 Pointer to the noise envelope filter used by smart sensing algorithm.
 
uint16_t * ptrRawFilterHistory
 Pointer to the raw count filter history of the widget.
 
uint8_t * ptrRawFilterHistoryLow
 Pointer to the raw count filter history extended of the widget.
 
uint32_t iirCoeff
 Raw count IIR filter coefficient. More...
 
uint8_t * ptrDebounceArr
 Pointer to the debounce array of the widget.
 
const uint8_t * ptrDiplexTable
 Pointer to the diplex table used for Linear slider when Diplex option is enabled.
 
uint32_t centroidConfig
 Configuration of centroids.
 
uint16_t xResolution
 Keeps maximum position value. More...
 
uint16_t yResolution
 For Touchpads Y-Axis maximum position.
 
uint16_t numSns
 The total number of sensors: For CSD widgets: WD_NUM_ROWS + WD_NUM_COLS. More...
 
uint8_t numCols
 For CSD Button and Proximity Widgets, the number of sensors. More...
 
uint8_t numRows
 For CSD Touchpad and Matrix Buttons, the number of the row sensors. More...
 
cy_stc_capsense_touch_tptrPosFilterHistory
 Pointer to the position filter history.
 
cy_stc_capsense_csx_touch_history_tptrCsxTouchHistory
 Pointer to the CSX touchpad history.
 
cy_stc_capsense_csx_touch_buffer_tptrCsxTouchBuffer
 Pointer to the single CSX buffer needed for CSX touchpad processing.
 
uint16_t * ptrCsdTouchBuffer
 Pointer to the CSD buffer needed for advanced CSD touchpad processing.
 
cy_stc_capsense_gesture_config_tptrGestureConfig
 Pointer to Gesture configuration structure.
 
cy_stc_capsense_gesture_context_tptrGestureContext
 Pointer to Gesture context structure.
 
cy_stc_capsense_ballistic_config_t ballisticConfig
 The configuration data for position ballistic filter. More...
 
cy_stc_capsense_ballistic_context_tptrBallisticContext
 Pointer to Ballistic filter context structure.
 
cy_stc_capsense_adaptive_filter_config_t aiirConfig
 The configuration of position adaptive filter. More...
 
cy_stc_capsense_advanced_touchpad_config_t advConfig
 The configuration of CSD advanced touchpad.
 
uint32_t posFilterConfig
 Position filters configuration.
 
uint16_t rawFilterConfig
 Raw count filters configuration.
 
uint16_t alpOnThreshold
 ALP Filter ON threshold.
 
uint16_t alpOffThreshold
 ALP Filter OFF threshold.
 
uint8_t senseMethod
 Specifies the widget sensing method: More...
 
uint8_t wdType
 Specifies the widget type.
 
cy_stc_capsense_mp_table_tptrMpTable
 Pointer to the multi-phase vector and de-convolution coefficients. More...
 
uint16_t firstSlotId
 The slot ID in the widget to start scan from. More...
 
uint16_t numSlots
 The number of slots in the widget. More...
 
uint8_t numChopCycles
 Defines number of chopping cycles. More...
 
uint8_t mpOrder
 Multi-phase order. More...
 
uint8_t mpOrderRows
 Multi-phase order for rows in CSD widgets. More...
 
uint8_t lfsrDitherLimit
 Max dither in percentage. More...
 
uint8_t snsClkSourceAutoSelMode
 Defines set of rules that are used by clock source auto-selection algorithm. More...
 
uint8_t mfsConfig
 Multi-frequency Scan (MFS) widget configuration Contains masks: More...
 
uint8_t cdacDitherScaleMode
 CDAC dither scale mode. More...
 
uint8_t cicRateMode
 CIC2 filter decimation rate mode. More...
 
uint8_t iirCoeffHw
 Raw count HW IIR filter coefficient. More...
 
uint16_t cdacConfig
 Bit-mask for widget CDAC configuration: More...
 

Field Documentation

◆ ptrSnsCapacitance

uint32_t* cy_stc_capsense_widget_config_t::ptrSnsCapacitance

Pointer to the first object in the sensor capacitance array that belongs to this widget.

Note
This field is available only for the fifth-generation CAPSENSE™ and fifth-generation low power CAPSENSE™.

◆ iirCoeff

uint32_t cy_stc_capsense_widget_config_t::iirCoeff

Raw count IIR filter coefficient.

Smaller value leads to higher filtering

◆ xResolution

uint16_t cy_stc_capsense_widget_config_t::xResolution

Keeps maximum position value.

For Touchpads X-axis maximum position

◆ numSns

uint16_t cy_stc_capsense_widget_config_t::numSns

The total number of sensors: For CSD widgets: WD_NUM_ROWS + WD_NUM_COLS.

For CSX widgets: WD_NUM_ROWS * WD_NUM_COLS. For ISX widgets: (WD_NUM_ROWS + WD_NUM_COLS) / 2

◆ numCols

uint8_t cy_stc_capsense_widget_config_t::numCols

For CSD Button and Proximity Widgets, the number of sensors.

For CSD Slider Widget, the number of segments. For CSD Touchpad and Matrix Button, the number of the column sensors. For CSX Button, Slider, Touchpad, and Matrix Button, the number of the Rx electrodes. For ISX Button and Linear Slider, the number of the Rx electrodes.

◆ numRows

uint8_t cy_stc_capsense_widget_config_t::numRows

For CSD Touchpad and Matrix Buttons, the number of the row sensors.

For the CSX Button and Slider, the number of the Tx electrodes (constant 1u). For CSX Touchpad and Matrix Button, the number of the Tx electrodes. For ISX Button and Linear Slider, the number of the Lx electrodes.

◆ ballisticConfig

cy_stc_capsense_ballistic_config_t cy_stc_capsense_widget_config_t::ballisticConfig

The configuration data for position ballistic filter.

◆ aiirConfig

cy_stc_capsense_adaptive_filter_config_t cy_stc_capsense_widget_config_t::aiirConfig

The configuration of position adaptive filter.

◆ senseMethod

uint8_t cy_stc_capsense_widget_config_t::senseMethod

Specifies the widget sensing method:

  • 0 - UNDEFINED (CY_CAPSENSE_UNDEFINED_GROUP)
  • 1 - CSD (CY_CAPSENSE_CSD_GROUP)
  • 2 - CSX (CY_CAPSENSE_CSX_GROUP)
  • 3 - ISX (CY_CAPSENSE_ISX_GROUP)

◆ ptrMpTable

cy_stc_capsense_mp_table_t* cy_stc_capsense_widget_config_t::ptrMpTable

Pointer to the multi-phase vector and de-convolution coefficients.

Note
This field is available for the fifth-generation CAPSENSE™ and fifth-generation low power CAPSENSE™.

◆ firstSlotId

uint16_t cy_stc_capsense_widget_config_t::firstSlotId

The slot ID in the widget to start scan from.

Note
This field is available for the fifth-generation CAPSENSE™ and fifth-generation low power CAPSENSE™.

◆ numSlots

uint16_t cy_stc_capsense_widget_config_t::numSlots

The number of slots in the widget.

Note
This field is available for the fifth-generation CAPSENSE™ and fifth-generation low power CAPSENSE™.

◆ numChopCycles

uint8_t cy_stc_capsense_widget_config_t::numChopCycles

Defines number of chopping cycles.

One cycle means the feature is disabled

Note
This field is available for the fifth-generation CAPSENSE™ and fifth-generation low power CAPSENSE™.

◆ mpOrder

uint8_t cy_stc_capsense_widget_config_t::mpOrder

Multi-phase order.

Note
This field is available for the fifth-generation CAPSENSE™ and fifth-generation low power CAPSENSE™.

◆ mpOrderRows

uint8_t cy_stc_capsense_widget_config_t::mpOrderRows

Multi-phase order for rows in CSD widgets.

Note
This field is available for the fifth-generation low power CAPSENSE™.

◆ lfsrDitherLimit

uint8_t cy_stc_capsense_widget_config_t::lfsrDitherLimit

Max dither in percentage.

The input parameter for the LFSR range auto-selection algorithm

Note
This field is available for the fifth-generation CAPSENSE™and fifth-generation low power CAPSENSE™.

◆ snsClkSourceAutoSelMode

uint8_t cy_stc_capsense_widget_config_t::snsClkSourceAutoSelMode

Defines set of rules that are used by clock source auto-selection algorithm.

Note
This field is available for the fifth-generation CAPSENSE™ and fifth-generation low power CAPSENSE™.

◆ mfsConfig

uint8_t cy_stc_capsense_widget_config_t::mfsConfig

Multi-frequency Scan (MFS) widget configuration Contains masks:

  • bit[0:3] - Number of MFS Channels (CY_CAPSENSE_MFS_FREQ_CHANNELS_NUM_MASK).
  • bit[4] - MFS Configuration (CY_CAPSENSE_MFS_EN_MASK):
    • 0 - MFS Disabled.
    • 1 - MFS Enabled (Base or Frequency channel widget).
  • bit[5:6] - Widget attribute (CY_CAPSENSE_MFS_WIDGET_FREQ_ALL_CH_MASK):
    • 0 - Base widget
    • 1 - Frequency channel 1 widget (CY_CAPSENSE_MFS_WIDGET_FREQ_CH_1_MASK)
    • 2 - Frequency channel 2 widget (CY_CAPSENSE_MFS_WIDGET_FREQ_CH_2_MASK)
      Note
      This field is available for the fifth-generation CAPSENSE™ and fifth-generation low power CAPSENSE™.

◆ cdacDitherScaleMode

uint8_t cy_stc_capsense_widget_config_t::cdacDitherScaleMode

CDAC dither scale mode.

  • 0 (CY_CAPSENSE_CDAC_DITHERING_MODE_DISABLE) - CDAC dithering is disabled
  • 1 (CY_CAPSENSE_CDAC_DITHERING_MODE_MANUAL) - CDAC dither value set manually
  • 2 (CY_CAPSENSE_CDAC_DITHERING_MODE_AUTO) - CDAC dither value set automatically
    Note
    This field is available for the fifth-generation CAPSENSE™ and fifth-generation low power CAPSENSE™.

◆ cicRateMode

uint8_t cy_stc_capsense_widget_config_t::cicRateMode

CIC2 filter decimation rate mode.

  • 0 (CY_CAPSENSE_CIC_RATE_MODE_MANUAL) - The cicRate value set by users
  • 1 (CY_CAPSENSE_CIC_RATE_MODE_AUTO) - The cicRate value configured by middleware
  • 2 (CY_CAPSENSE_CIC_RATE_MODE_SMARTSENSE) - The cicRate value configured by SMARTSENSE™ algorithm
    Note
    This field is available for the fifth-generation CAPSENSE™ and fifth-generation low power CAPSENSE™.

◆ iirCoeffHw

uint8_t cy_stc_capsense_widget_config_t::iirCoeffHw

Raw count HW IIR filter coefficient.

Smaller value leads to lower filtering.

Note
This field is available only for the fifth-generation low power CAPSENSE™.

◆ cdacConfig

uint16_t cy_stc_capsense_widget_config_t::cdacConfig

Bit-mask for widget CDAC configuration:

  • bit[0..1] - Reference CDAC mode (CY_CAPSENSE_CDAC_REF_MODE_MASK)
    • 0 (CY_CAPSENSE_CDAC_MODE_DISABLED) - The reference CDAC is disabled
    • 1 (CY_CAPSENSE_CDAC_MODE_MANUAL) - The value of reference CDAC set manually
    • 2 (CY_CAPSENSE_CDAC_MODE_AUTO) - The value of reference CDAC set automatically
  • bit[2..3] - Fine CDAC mode (CY_CAPSENSE_CDAC_FINE_MODE_MASK)
    • 0 (CY_CAPSENSE_CDAC_MODE_DISABLED) - The fine CDAC is disabled
    • 1 (CY_CAPSENSE_CDAC_MODE_MANUAL) - The value of fine CDAC set manually
    • 2 (CY_CAPSENSE_CDAC_MODE_AUTO) - The value of fine CDAC set automatically
  • bit[4..5] - Compensation CDAC mode (CY_CAPSENSE_CDAC_COMP_MODE_MASK)
    • 0 (CY_CAPSENSE_CDAC_MODE_DISABLED) - The compensation CDAC is disabled
    • 1 (CY_CAPSENSE_CDAC_MODE_MANUAL) - The value of compensation CDAC set manually
    • 2 (CY_CAPSENSE_CDAC_MODE_AUTO) - The value of compensation CDAC set automatically
  • bit[6..7] - Compensation CDAC divider mode (CY_CAPSENSE_CDAC_COMP_DIV_MODE_MASK)
    • 0 (CY_CAPSENSE_CDAC_MODE_MANUAL) - The value of compensation CDAC divider set manually
    • 2 (CY_CAPSENSE_CDAC_MODE_AUTO) - The value of compensation CDAC divider set automatically
  • bit[8..9] - Sensitivity boost (CY_CAPSENSE_CDAC_BOOST_VAL_MASK)
    • 1 (CY_CAPSENSE_CDAC_BOOST_DISABLED) - Boost disabled
    • 2 (CY_CAPSENSE_CDAC_BOOST_2X) - 2X Boost
    • 3 (CY_CAPSENSE_CDAC_BOOST_3X) - 3X Boost
    • 4 (CY_CAPSENSE_CDAC_BOOST_4X) - 4X Boost
      Note
      This field is available for the fifth-generation low power CAPSENSE™.