38 #if defined(LESENSE_COUNT) && (LESENSE_COUNT > 0)
58 #define LESENSE_NUM_DECODER_STATES (_LESENSE_DECSTATE_DECSTATE_MASK + 1)
61 #define LESENSE_NUM_CHANNELS 16
107 #if defined( LESENSE_CTRL_PRSSEL_PRSCH4 )
110 #if defined( LESENSE_CTRL_PRSSEL_PRSCH5 )
113 #if defined( LESENSE_CTRL_PRSSEL_PRSCH6 )
116 #if defined( LESENSE_CTRL_PRSSEL_PRSCH7 )
119 #if defined( LESENSE_CTRL_PRSSEL_PRSCH8 )
122 #if defined( LESENSE_CTRL_PRSSEL_PRSCH9 )
125 #if defined( LESENSE_CTRL_PRSSEL_PRSCH10 )
128 #if defined( LESENSE_CTRL_PRSSEL_PRSCH11 )
140 #if defined(_LESENSE_CTRL_ALTEXMAP_ACMP)
142 lesenseAltExMapACMP = _LESENSE_CTRL_ALTEXMAP_ACMP,
145 #if defined(_LESENSE_CTRL_ALTEXMAP_CH)
222 #if defined(_LESENSE_PERCTRL_DACCH0DATA_ACMPTHRES)
225 lesenseACMPThres = _LESENSE_PERCTRL_DACCH0DATA_ACMPTHRES,
228 #if defined(_LESENSE_PERCTRL_DACCH0DATA_THRES)
235 #if defined(_LESENSE_PERCTRL_DACCH0CONV_MASK)
241 lesenseDACConvModeDisable = _LESENSE_PERCTRL_DACCH0CONV_DISABLE,
245 lesenseDACConvModeContinuous = _LESENSE_PERCTRL_DACCH0CONV_CONTINUOUS,
249 lesenseDACConvModeSampleHold = _LESENSE_PERCTRL_DACCH0CONV_SAMPLEHOLD,
253 lesenseDACConvModeSampleOff = _LESENSE_PERCTRL_DACCH0CONV_SAMPLEOFF
254 } LESENSE_ControlDACConv_TypeDef;
257 #if defined(_LESENSE_PERCTRL_DACCH0OUT_MASK)
263 lesenseDACOutModeDisable = _LESENSE_PERCTRL_DACCH0OUT_DISABLE,
267 lesenseDACOutModePin = _LESENSE_PERCTRL_DACCH0OUT_PIN,
271 lesenseDACOutModeADCACMP = _LESENSE_PERCTRL_DACCH0OUT_ADCACMP,
275 lesenseDACOutModePinADCACMP = _LESENSE_PERCTRL_DACCH0OUT_PINADCACMP
276 } LESENSE_ControlDACOut_TypeDef;
280 #if defined(_LESENSE_PERCTRL_DACREF_MASK)
285 lesenseDACRefVdd = LESENSE_PERCTRL_DACREF_VDD,
288 lesenseDACRefBandGap = LESENSE_PERCTRL_DACREF_BANDGAP
289 } LESENSE_DACRef_TypeDef;
347 #if defined(LESENSE_CH_INTERACT_SAMPLE_ADC)
406 #if defined(_LESENSE_IDLECONF_CH0_DAC)
413 lesenseChPinIdleDACCh0 = _LESENSE_IDLECONF_CH0_DACCH0,
417 lesenseChPinIdleDACCh1 = _LESENSE_IDLECONF_CH12_DACCH1,
446 #if defined(_LESENSE_CH_EVAL_MODE_MASK)
579 #define LESENSE_CORECTRL_DESC_DEFAULT \
581 lesenseScanStartPeriodic, \
583 lesenseScanConfDirMap, \
589 lesenseBufTrigHalf, \
590 lesenseDMAWakeUpDisable, \
591 lesenseBiasModeDontTouch, \
610 #define LESENSE_TIMECTRL_DESC_DEFAULT \
623 #if defined(_LESENSE_PERCTRL_DACCH0CONV_MASK)
625 LESENSE_ControlDACConv_TypeDef dacCh0ConvMode;
628 LESENSE_ControlDACOut_TypeDef dacCh0OutMode;
634 #if defined(_LESENSE_PERCTRL_DACCH1CONV_MASK)
636 LESENSE_ControlDACConv_TypeDef dacCh1ConvMode;
639 LESENSE_ControlDACOut_TypeDef dacCh1OutMode;
642 #if defined(_LESENSE_PERCTRL_DACPRESC_MASK)
648 #if defined(_LESENSE_PERCTRL_DACREF_MASK)
651 LESENSE_DACRef_TypeDef dacRef;
663 #if defined(_LESENSE_PERCTRL_DACCONVTRIG_MASK)
671 #if defined(_SILICON_LABS_32B_SERIES_0)
672 #define LESENSE_PERCTRL_DESC_DEFAULT \
675 lesenseDACConvModeDisable, \
676 lesenseDACOutModeDisable, \
678 lesenseDACConvModeDisable, \
679 lesenseDACOutModeDisable, \
682 lesenseACMPModeMuxThres, \
683 lesenseACMPModeMuxThres, \
684 lesenseWarmupModeKeepWarm, \
687 #define LESENSE_PERCTRL_DESC_DEFAULT \
691 lesenseACMPModeMuxThres, \
692 lesenseACMPModeMuxThres, \
693 lesenseWarmupModeKeepWarm, \
749 #define LESENSE_DECCTRL_DESC_DEFAULT \
751 lesenseDecInputSensorSt, \
784 #define LESENSE_INIT_DEFAULT \
786 .coreCtrl = LESENSE_CORECTRL_DESC_DEFAULT, \
787 .timeCtrl = LESENSE_TIMECTRL_DESC_DEFAULT, \
788 .perCtrl = LESENSE_PERCTRL_DESC_DEFAULT, \
789 .decCtrl = LESENSE_DECCTRL_DESC_DEFAULT \
872 #if defined(_LESENSE_CH_EVAL_MODE_MASK)
888 #if defined(_LESENSE_CH_EVAL_MODE_MASK)
889 #define LESENSE_CH_CONF_DEFAULT \
894 lesenseChPinExHigh, \
895 lesenseChPinIdleLow, \
906 lesenseSampleModeACMP, \
909 lesenseCompModeLess, \
910 lesenseEvalModeThreshold \
913 #define LESENSE_CH_CONF_DEFAULT \
918 lesenseChPinExHigh, \
919 lesenseChPinIdleLow, \
930 lesenseSampleModeACMP, \
933 lesenseCompModeLess \
939 #define LESENSE_SCAN_CONF_DEFAULT \
942 LESENSE_CH_CONF_DEFAULT, \
943 LESENSE_CH_CONF_DEFAULT, \
944 LESENSE_CH_CONF_DEFAULT, \
945 LESENSE_CH_CONF_DEFAULT, \
946 LESENSE_CH_CONF_DEFAULT, \
947 LESENSE_CH_CONF_DEFAULT, \
948 LESENSE_CH_CONF_DEFAULT, \
949 LESENSE_CH_CONF_DEFAULT, \
950 LESENSE_CH_CONF_DEFAULT, \
951 LESENSE_CH_CONF_DEFAULT, \
952 LESENSE_CH_CONF_DEFAULT, \
953 LESENSE_CH_CONF_DEFAULT, \
954 LESENSE_CH_CONF_DEFAULT, \
955 LESENSE_CH_CONF_DEFAULT, \
956 LESENSE_CH_CONF_DEFAULT, \
957 LESENSE_CH_CONF_DEFAULT, \
1008 #define LESENSE_ALTEX_CH_CONF_DEFAULT \
1011 lesenseAltExPinIdleDis, \
1016 #if defined(_LESENSE_CTRL_ALTEXMAP_ACMP)
1017 #define LESENSE_ALTEX_CONF_DEFAULT \
1019 lesenseAltExMapACMP, \
1021 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1022 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1023 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1024 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1025 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1026 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1027 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1028 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1029 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1030 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1031 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1032 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1033 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1034 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1035 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1036 LESENSE_ALTEX_CH_CONF_DEFAULT \
1040 #define LESENSE_ALTEX_CONF_DEFAULT \
1042 lesenseAltExMapCH, \
1044 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1045 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1046 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1047 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1048 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1049 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1050 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1051 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1052 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1053 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1054 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1055 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1056 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1057 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1058 LESENSE_ALTEX_CH_CONF_DEFAULT, \
1059 LESENSE_ALTEX_CH_CONF_DEFAULT \
1089 #define LESENSE_ST_CONF_DEFAULT \
1094 lesenseTransActNone, \
1124 #if defined(_SILICON_LABS_32B_SERIES_0)
1125 #define LESENSE_DECODER_CONF_DEFAULT \
1128 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1129 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1130 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1131 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1132 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1133 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1134 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1135 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1136 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1137 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1138 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1139 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1140 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1141 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1142 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1143 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT } \
1147 #define LESENSE_DECODER_CONF_DEFAULT \
1150 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1151 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1152 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1153 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1154 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1155 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1156 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1157 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1158 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1159 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1160 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1161 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1162 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1163 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1164 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1165 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1166 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1167 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1168 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1169 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1170 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1171 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1172 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1173 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1174 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1175 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1176 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1177 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1178 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1179 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1180 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT }, \
1181 { false, LESENSE_ST_CONF_DEFAULT, LESENSE_ST_CONF_DEFAULT } \
1207 uint8_t sampleDelay,
1208 uint16_t measDelay);
1212 #if defined(_LESENSE_CH_EVAL_MODE_MASK)
1214 uint32_t windowSize,
1215 uint32_t initValue);
1218 uint32_t initValue);
1230 #if defined(_LESENSE_PRSCTRL_MASK)
1297 while (!(
LESENSE->STATUS & flag))
1370 return LESENSE->BUF[idx & 0x0FU].DATA;
1387 #if defined(LESENSE_POWERDOWN_RAM)
1400 __STATIC_INLINE
void LESENSE_RAMPowerDown(
void)
1403 LESENSE->POWERDOWN = LESENSE_POWERDOWN_RAM;
__STATIC_INLINE uint32_t LESENSE_IntGetEnabled(void)
Get enabled and pending LESENSE interrupt flags.
__STATIC_INLINE void LESENSE_StatusWait(uint32_t flag)
Wait until the status of LESENSE is equal to what requested.
LESENSE_PRSSel_TypeDef prsChSel3
__STATIC_INLINE void LESENSE_IntClear(uint32_t flags)
Clear one or more pending LESENSE interrupts.
LESENSE_TimeCtrlDesc_TypeDef timeCtrl
void LESENSE_AltExConfig(const LESENSE_ConfAltEx_TypeDef *confAltEx)
Configure the LESENSE alternate excitation modes.
#define LESENSE_ST_TCONFA_PRSACT_UPANDPRS2
LESENSE_ControlACMP_TypeDef acmp1Mode
#define LESENSE_NUM_CHANNELS
#define LESENSE_ST_TCONFA_PRSACT_DOWNANDPRS2
LESENSE_ControlACMP_TypeDef
void LESENSE_DecoderStart(void)
Start LESENSE decoder.
#define _LESENSE_PERCTRL_ACMP0MODE_DISABLE
#define LESENSE_CH_INTERACT_SAMPLE_ADCDIFF
LESENSE_ChSampleMode_TypeDef
#define LESENSE_CTRL_SCANMODE_PERIODIC
LESENSE_ControlDACData_TypeDef dacCh0Data
LESENSE_DecStCond_TypeDef confA
LESENSE_BufTrigLevel_TypeDef
LESENSE_DecCtrlDesc_TypeDef decCtrl
#define _LESENSE_SCANRES_SCANRES_MASK
LESENSE_ControlDACData_TypeDef dacCh1Data
LESENSE_ChPinIdleMode_TypeDef chPinIdleMode
void LESENSE_Init(const LESENSE_Init_TypeDef *init, bool reqReset)
Initialize the LESENSE module.
void LESENSE_DecoderPrsOut(bool enable, uint32_t decMask, uint32_t decCmp)
Enable or disable PRS output from the LESENSE decoder.
LESENSE_ScanConfSel_TypeDef
__STATIC_INLINE uint32_t LESENSE_SensorStateGet(void)
Get the current state of the LESENSE sensor.
#define LESENSE_CH_INTERACT_SETIF_POSEDGE
void LESENSE_Reset(void)
Reset the LESENSE module.
LESENSE_DMAWakeUp_TypeDef
void LESENSE_ResultBufferClear(void)
Clear result buffer.
CMSIS Cortex-M Peripheral Access Layer for Silicon Laboratories microcontroller devices.
void LESENSE_ChannelThresSet(uint8_t chIdx, uint16_t acmpThres, uint16_t cntThres)
Set LESENSE channel threshold parameters.
#define LESENSE_CH_INTERACT_EXMODE_HIGH
#define _LESENSE_CH_INTERACT_SAMPLE_SHIFT
void LESENSE_ScanModeSet(LESENSE_ScanMode_TypeDef scanMode, bool start)
Set scan mode of the LESENSE channels.
void LESENSE_ChannelSlidingWindow(uint8_t chIdx, uint32_t windowSize, uint32_t initValue)
Configure Sliding Window evaluation mode for a specific channel.
LESENSE_PRSSel_TypeDef prsChSel0
#define LESENSE_CTRL_DMAWU_BUFLEVEL
#define LESENSE_ST_TCONFA_PRSACT_UP
#define _LESENSE_CH_EVAL_MODE_SLIDINGWIN
#define LESENSE_CH_EVAL_COMP_GE
#define LESENSE_CTRL_SCANCONF_DIRMAP
#define LESENSE_CTRL_BUFIDL_FULL
void LESENSE_DecoderStateSet(uint32_t decSt)
Set LESENSE decoder state.
void LESENSE_WindowSizeSet(uint32_t windowSize)
Set the window size for all LESENSE channels.
#define LESENSE_DECCTRL_DISABLE
#define LESENSE_CH_INTERACT_SETIF_LEVEL
LESENSE_PRSSel_TypeDef prsSel
#define LESENSE_CH_INTERACT_SETIF_NONE
LESENSE_AltExPinIdle_TypeDef
#define _LESENSE_CH_INTERACT_EXCLK_LFACLK
LESENSE_ChEvalMode_TypeDef
LESENSE_ChClk_TypeDef exClk
#define _LESENSE_IDLECONF_CH0_HIGH
LESENSE_ChEvalMode_TypeDef evalMode
#define LESENSE_CTRL_SCANMODE_PRS
#define LESENSE_DECCTRL_INPUT_PRS
void LESENSE_ChannelTimingSet(uint8_t chIdx, uint8_t exTime, uint8_t sampleDelay, uint16_t measDelay)
Set LESENSE channel timing parameters.
uint32_t LESENSE_ScanFreqSet(uint32_t refFreq, uint32_t scanFreq)
Set scan frequency for periodic scanning.
#define _LESENSE_PERCTRL_ACMP0MODE_MUXTHRES
__STATIC_INLINE void LESENSE_IntDisable(uint32_t flags)
Disable one or more LESENSE interrupts.
LESENSE_DMAWakeUp_TypeDef wakeupOnDMA
#define _LESENSE_ALTEXCONF_IDLECONF0_DISABLE
#define _LESENSE_IDLECONF_CH0_DISABLE
__STATIC_INLINE uint32_t LESENSE_ScanResultDataBufferGet(uint32_t idx)
Get data from the result data buffer.
#define LESENSE_BIASCTRL_BIASMODE_DONTTOUCH
#define _LESENSE_CH_INTERACT_EXCLK_AUXHFRCO
LESENSE_StTransAct_TypeDef
LESENSE_ChCompMode_TypeDef compMode
__STATIC_INLINE uint32_t LESENSE_StatusGet(void)
Get the current status of LESENSE.
#define _LESENSE_PERCTRL_ACMP0MODE_MUX
#define LESENSE_ST_TCONFA_PRSACT_PRS012
void LESENSE_ClkDivSet(LESENSE_ChClk_TypeDef clk, LESENSE_ClkPresc_TypeDef clkDiv)
Set clock division for LESENSE timers.
#define _LESENSE_IDLECONF_CH0_LOW
#define _LESENSE_ALTEXCONF_IDLECONF0_HIGH
LESENSE_PRSSel_TypeDef prsChSel2
#define LESENSE_CH_INTERACT_EXMODE_LOW
#define LESENSE_ST_TCONFA_PRSACT_DOWN
#define LESENSE_NUM_DECODER_STATES
void LESENSE_ChannelAllConfig(const LESENSE_ChAll_TypeDef *confChAll)
Configure all (16) LESENSE sensor channels.
LESENSE_WarmupMode_TypeDef
#define LESENSE_CH_INTERACT_SAMPLE_ACMP
__STATIC_INLINE uint32_t LESENSE_ScanResultGet(void)
Get the latest scan comparison result (1 bit / channel).
#define LESENSE_ST_TCONFA_PRSACT_PRS01
LESENSE_PerCtrlDesc_TypeDef perCtrl
void LESENSE_ChannelConfig(const LESENSE_ChDesc_TypeDef *confCh, uint32_t chIdx)
Configure a single LESENSE sensor channel.
LESENSE_ScanConfSel_TypeDef scanConfSel
#define LESENSE_CTRL_SCANCONF_DECDEF
uint32_t LESENSE_DecoderStateGet(void)
Get the current state of the LESENSE decoder.
#define LESENSE_ST_TCONFA_PRSACT_PRS0
#define LESENSE_ST_TCONFA_PRSACT_NONE
LESENSE_ControlACMP_TypeDef acmp0Mode
#define LESENSE_DECCTRL_INPUT_SENSORSTATE
#define LESENSE_PERCTRL_WARMUPMODE_KEEPACMPWARM
LESENSE_ChCompMode_TypeDef
void LESENSE_ChannelEnable(uint8_t chIdx, bool enaScanCh, bool enaPin)
Enable/disable LESENSE scan channel and the pin assigned to it.
void LESENSE_StepSizeSet(uint32_t stepSize)
Set the step size for all LESENSE channels.
__STATIC_INLINE uint32_t LESENSE_IntGet(void)
Get pending LESENSE interrupt flags.
#define LESENSE_PERCTRL_WARMUPMODE_KEEPACMPDACWARM
LESENSE_ChPinExMode_TypeDef
#define _LESENSE_CH_EVAL_MODE_THRES
#define _LESENSE_IDLECONF_CH0_DAC
#define LESENSE_CTRL_SCANCONF_INVMAP
#define LESENSE_CH_INTERACT_EXMODE_DACOUT
#define LESENSE_CTRL_SCANCONF_TOGGLE
LESENSE_DecStCond_TypeDef confB
#define LESENSE_CH_INTERACT_SAMPLE_ADC
LESENSE_ChClk_TypeDef sampleClk
#define LESENSE_PERCTRL_WARMUPMODE_KEEPDACWARM
LESENSE_CoreCtrlDesc_TypeDef coreCtrl
LESENSE_ScanMode_TypeDef scanStart
__STATIC_INLINE uint32_t LESENSE_ScanResultDataGet(void)
Get the oldest unread data from the result buffer.
#define LESENSE_CTRL_SCANMODE_ONESHOT
LESENSE_AltExMap_TypeDef altExMap
#define LESENSE_ST_TCONFA_PRSACT_PRS02
#define _LESENSE_CTRL_ALTEXMAP_CH
#define LESENSE_BIASCTRL_BIASMODE_HIGHACC
#define LESENSE_CH_EVAL_COMP_LESS
#define LESENSE_BIASCTRL_BIASMODE_DUTYCYCLE
void LESENSE_DecoderStateConfig(const LESENSE_DecStDesc_TypeDef *confDecSt, uint32_t decSt)
Configure a single LESENSE decoder state.
LESENSE_ControlDACData_TypeDef
#define LESENSE_CH_INTERACT_EXMODE_DISABLE
#define LESENSE_ST_TCONFA_PRSACT_PRS1
LESENSE_DecInput_TypeDef decInput
LESENSE_ChIntMode_TypeDef
#define LESENSE_CTRL_BUFIDL_HALFFULL
#define _LESENSE_PERCTRL_DACCH0DATA_DACDATA
LESENSE_WarmupMode_TypeDef warmupMode
LESENSE_StTransAct_TypeDef prsAct
#define _LESENSE_CTRL_ALTEXMAP_ALTEX
#define LESENSE_ST_TCONFA_PRSACT_PRS2
LESENSE_BiasMode_TypeDef biasMode
LESENSE_AltExPinIdle_TypeDef idleConf
void LESENSE_ChannelEnableMask(uint16_t chMask, uint16_t pinMask)
Enable/disable LESENSE scan channel and the pin assigned to it.
void LESENSE_StartDelaySet(uint8_t startDelay)
Set start delay of sensor interaction on each channel.
void LESENSE_ScanStart(void)
Start scanning of sensors.
#define _LESENSE_ALTEXCONF_IDLECONF0_LOW
__STATIC_INLINE void LESENSE_DecoderStop(void)
Stop LESENSE decoder.
#define LESENSE_CH_INTERACT_SETIF_NEGEDGE
void LESENSE_ScanStop(void)
Stop scanning of sensors.
#define LESENSE_ST_TCONFA_PRSACT_PRS12
__STATIC_INLINE uint32_t LESENSE_ChannelActiveGet(void)
Get the currently active channel index.
#define _LESENSE_PERCTRL_DACCH0DATA_THRES
#define LESENSE_PERCTRL_WARMUPMODE_NORMAL
__STATIC_INLINE void LESENSE_IntEnable(uint32_t flags)
Enable one or more LESENSE interrupts.
LESENSE_ChPinIdleMode_TypeDef
#define LESENSE_CTRL_DMAWU_DISABLE
#define LESENSE_CTRL_DMAWU_BUFDATAV
void LESENSE_ChannelStepDetection(uint8_t chIdx, uint32_t stepSize, uint32_t initValue)
Configure step detection evaluation mode for a specific channel.
LESENSE_ChIntMode_TypeDef intMode
LESENSE_ChPinExMode_TypeDef chPinExMode
LESENSE_BufTrigLevel_TypeDef bufTrigLevel
LESENSE_PRSSel_TypeDef prsChSel1
#define _LESENSE_CH_EVAL_MODE_STEPDET
LESENSE_ChSampleMode_TypeDef sampleMode
__STATIC_INLINE void LESENSE_IntSet(uint32_t flags)
Set one or more pending LESENSE interrupts from SW.
void LESENSE_DecoderStateAllConfig(const LESENSE_DecStAll_TypeDef *confDecStAll)
Configure all LESENSE decoder states.