summaryrefslogtreecommitdiff
path: root/nuttx/configs/sam3u-ek/src/sam3uek_internal.h
diff options
context:
space:
mode:
authorpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2011-10-08 00:37:18 +0000
committerpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2011-10-08 00:37:18 +0000
commitc87ac73912d8d1dc36944c52526f13d24301cd7a (patch)
tree3ac469cc8242aa9eabf5d99f8fafeee25e167f34 /nuttx/configs/sam3u-ek/src/sam3uek_internal.h
parent77fac8557262940319c3fa3bc473866d4bb90450 (diff)
downloadpx4-nuttx-c87ac73912d8d1dc36944c52526f13d24301cd7a.tar.gz
px4-nuttx-c87ac73912d8d1dc36944c52526f13d24301cd7a.tar.bz2
px4-nuttx-c87ac73912d8d1dc36944c52526f13d24301cd7a.zip
SAM3U: Add logic to bypass automated control of SPI chip selects
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@4032 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx/configs/sam3u-ek/src/sam3uek_internal.h')
-rw-r--r--nuttx/configs/sam3u-ek/src/sam3uek_internal.h12
1 files changed, 10 insertions, 2 deletions
diff --git a/nuttx/configs/sam3u-ek/src/sam3uek_internal.h b/nuttx/configs/sam3u-ek/src/sam3uek_internal.h
index 1aa66d517..5b5138960 100644
--- a/nuttx/configs/sam3u-ek/src/sam3uek_internal.h
+++ b/nuttx/configs/sam3u-ek/src/sam3uek_internal.h
@@ -164,9 +164,17 @@
/* SPI Chip Selects */
-/* Chip select pin connected to the touchscreen controller and to ZigBee module connector. */
+/* Chip select pin connected to the touchscreen controller and to the ZigBee module
+ * connector. Notice that the touchscreen chip select is implemented as a GPIO
+ * OUTPUT that must be controlled by board-specific. This is because the ADS7843E
+ * driver must be able to sample the device BUSY GPIO input between SPI transfers.
+ * However, the AD7843E will tri-state the BUSY input whenever the chip select is
+ * de-asserted. So the only option is to control the chip select manually and hold
+ * it low throughout the SPI transfer.
+ */
-#define GPIO_TSC_NPCS2 GPIO_SPI0_NPCS2_3
+#define GPIO_TSC_NPCS2 (GPIO_OUTPUT|GPIO_CFG_PULLUP|GPIO_OUTPUT_SET|\
+ GPIO_PORT_PIOC|GPIO_PIN14)
/************************************************************************************
* Public Types