2017-09-21 09:54 AM
how are capsense pins defined, e.g. TSC_GROUP4_IO1 does not correlate.
also any links to capsense info beyond AN4310 would be appreciated
2017-09-21 10:20 AM
I am tasked with modifying something that has two 'finger caps' attached to PB 13 & 14, in the software they are described as group6_io3 and group 6_io4 which correlates bitwise to PB 10&11. something does not make sense
2017-09-21 10:22 AM
hello!
Try
document.Regards
vf
2017-09-21 12:05 PM
thanks, with that link and the reference manual page 810 I have gotten where the 'finger cap' is defined, not very intuitive, but oh well. What I still can't find is the pin definition for the sampling cap. since I have to totally revise the capsense, I need to figure this out.
2017-09-21 03:30 PM
Hi Erik,
I don't use the TSC module and you did not tell us which chip are you using, but according to 'L4x5/4x6 RM you select the pins used for sampling capacitor in the TSC_IOSCR register.
The signals numbers (Gx_IOy) are converted to physical pin number through the Alternate Function table from the respective datasheet, but you've probably figured that out already.
Jan
2017-09-22 05:35 AM
Hi, Jan it's been a while
sorry I tell everybody to mention the chip and forget myself it is STM32F091
The signals numbers (Gx_IOy) are converted to physical pin number through the Alternate Function table from the respective datasheet
true for button pins, false for capacitor pins
2017-09-22 06:06 AM
Hello !
true for button pins, false for capacitor pins
As
Waclawek.Jan
mentioned above, TSC_IOSCR reg assigns the sampl. capacitor bit to external pins through AF.
Rgrds
vf
2017-09-22 08:45 AM
Erik,
This is the mapping of physical pins to Gx_IOy, from the DS, for Group 6 (into which fall both your ''fingers''):
My understanding of TSC based on reading of RM0091 is, that
- during one ''normal'' conversion, only one ''channel'' or ''electrode'' (which is one of your ''fingers'') input is used per group, selected by setting one bit in TSC_IOCCR, respective to this input
- there is one ''capacitor'' or ''sampling'' input per group, selected by setting one bit in TSC_IOSCR (note that ST is kind enough to provide several names for the same functionality, keeping us alert while reading ;) )
- in your case, as you have two ''fingers'', you have to perform two separate conversions, swapping the ''channel'' between them (i.e. rewriting TSC_IOCCR)
So, you have to connect your sampling capacitor to PB11 or PB12 and set the according bit in TSC_IOSCR.
I repeat that I have never used TSC just reread the RM chapter a couple of times.
JW