In the function of CAPT_GetTouchDat,
data->count = (uint8_t)((CAPT_TOUCH_COUNT_MASK & tmp32) >> CAPT_TOUCH_COUNT_SHIFT)
should be
data->count = (uint16_t)((CAPT_TOUCH_COUNT_MASK & tmp32) >> CAPT_TOUCH_COUNT_SHIFT)
Hello PXU
Thank you for letting us know about this bug. I confirmed that the cast needs to be uint16_t since the variable count is 16bits wide.
I will inform this to the corresponding team in order to fix it in further releases.
Best regards,
Omar