diff options
author | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2011-08-15 14:55:36 +0000 |
---|---|---|
committer | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2011-08-15 14:55:36 +0000 |
commit | 5435b6d5327bc257c9ee1df956e66c74df82bcc8 (patch) | |
tree | ef86b01a2febb2a041c1c29f9da420979c91b604 /nuttx/arch/arm/src/kinetis/kinetis_tsi.h | |
parent | 981c97bce640f4f0ef7484c4d3acafad25a79614 (diff) | |
download | px4-nuttx-5435b6d5327bc257c9ee1df956e66c74df82bcc8.tar.gz px4-nuttx-5435b6d5327bc257c9ee1df956e66c74df82bcc8.tar.bz2 px4-nuttx-5435b6d5327bc257c9ee1df956e66c74df82bcc8.zip |
Finishes very basic Kinetis port
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@3882 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx/arch/arm/src/kinetis/kinetis_tsi.h')
-rw-r--r-- | nuttx/arch/arm/src/kinetis/kinetis_tsi.h | 21 |
1 files changed, 6 insertions, 15 deletions
diff --git a/nuttx/arch/arm/src/kinetis/kinetis_tsi.h b/nuttx/arch/arm/src/kinetis/kinetis_tsi.h index a60ab1e0f..df96a0d8c 100644 --- a/nuttx/arch/arm/src/kinetis/kinetis_tsi.h +++ b/nuttx/arch/arm/src/kinetis/kinetis_tsi.h @@ -280,23 +280,14 @@ #define TSI_STATUS_ERROF15 (1 << 31) /* Bit 31: TouchSensing Error Flag 15 */ /* Counter Register n. Note: These values are reversed in the K40 and K60 - * documentation. I bet one is right and the other is wrong (I'd bet on the K40 - * document). + * documentation. In the K40/K60 header files, however, CNTN1 is always the + * the field in the most significant bits. Let's go with that. */ -#ifdef KINETIS_K40 -# define TSI_CNTR_CNTN1_SHIFT (0) /* Bits 0-15: TouchSensing channel n-1 16-bit counter value */ -# define TSI_CNTR_CNTN1_MASK (0xffff << TSI_CNTR_CNTN1_SHIFT) -# define TSI_CNTR_CNTN_SHIFT (16) /* Bits 16-31: TouchSensing channel n 16-bit counter value */ -# define TSI_CNTR_CNTN_MASK (0xffff << TSI_CNTR_CNTN_SHIFT) -#endif -#ifdef KINETIS_K60 -# warning "Revisit" -# define TSI_CNTR_CNTN_SHIFT (0) /* Bits 0-15: TouchSensing channel n 16-bit counter value */ -# define TSI_CNTR_CNTN_MASK (0xffff << TSI_CNTR_CNTN_SHIFT) -# define TSI_CNTR_CNTN1_SHIFT (16) /* Bits 16-31: TouchSensing channel n-1 16-bit counter value */ -# define TSI_CNTR_CNTN1_MASK (0xffff << TSI_CNTR_CNTN1_SHIFT) -#endif +#define TSI_CNTR_CNTN_SHIFT (0) /* Bits 0-15: TouchSensing channel n 16-bit counter value */ +#define TSI_CNTR_CNTN_MASK (0xffff << TSI_CNTR_CNTN_SHIFT) +#define TSI_CNTR_CNTN1_SHIFT (16) /* Bits 16-31: TouchSensing channel n-1 16-bit counter value */ +#define TSI_CNTR_CNTN1_MASK (0xffff << TSI_CNTR_CNTN1_SHIFT) /* Channel n threshold register */ |