summaryrefslogtreecommitdiff
path: root/nuttx/configs/stm3210e-eval
diff options
context:
space:
mode:
authorpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2009-10-18 20:58:04 +0000
committerpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2009-10-18 20:58:04 +0000
commitdbaa783ef42ef49c436a116436a17e7b34553ccb (patch)
tree079f11132686f61353cc96d95ac991bf590e461e /nuttx/configs/stm3210e-eval
parent256fbb5e5d5dac428e58adeb0272567c69a5e7d9 (diff)
downloadpx4-nuttx-dbaa783ef42ef49c436a116436a17e7b34553ccb.tar.gz
px4-nuttx-dbaa783ef42ef49c436a116436a17e7b34553ccb.tar.bz2
px4-nuttx-dbaa783ef42ef49c436a116436a17e7b34553ccb.zip
Add bulk erase IOCTL; add byte read method
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@2158 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx/configs/stm3210e-eval')
-rwxr-xr-xnuttx/configs/stm3210e-eval/src/up_nsh.c21
-rwxr-xr-xnuttx/configs/stm3210e-eval/src/up_spi.c1
2 files changed, 20 insertions, 2 deletions
diff --git a/nuttx/configs/stm3210e-eval/src/up_nsh.c b/nuttx/configs/stm3210e-eval/src/up_nsh.c
index 177d93993..4eb0e8e86 100755
--- a/nuttx/configs/stm3210e-eval/src/up_nsh.c
+++ b/nuttx/configs/stm3210e-eval/src/up_nsh.c
@@ -62,6 +62,25 @@
# undef CONFIG_EXAMPLES_NSH_HAVEUSBDEV
#endif
+/* MMC/SD is on SPI1 */
+
+#ifndef CONFIG_STM32_SPI1
+# undef CONFIG_EXAMPLES_NSH_MMCSDSPIPORTNO
+# undef CONFIG_EXAMPLES_NSH_MMCSDSLOTNO
+#endif
+
+#if defined(CONFIG_EXAMPLES_NSH_MMCSDSPIPORTNO) && CONFIG_EXAMPLES_NSH_MMCSDSPIPORTNO != 0
+# error MMC/SD is on SPI1
+# undef CONFIG_EXAMPLES_NSH_MMCSDSPIPORTNO
+# undef CONFIG_EXAMPLES_NSH_MMCSDSLOTNO
+#endif
+
+#if defined(CONFIG_EXAMPLES_NSH_MMCSDSLOTNO) && CONFIG_EXAMPLES_NSH_MMCSDSLOTNO != 0
+# error "Only one MMC/SD slot"
+# undef CONFIG_EXAMPLES_NSH_MMCSDSPIPORTNO
+# undef CONFIG_EXAMPLES_NSH_MMCSDSLOTNO
+#endif
+
/* Can't support MMC/SD features if mountpoints are disabled */
#if defined(CONFIG_DISABLE_MOUNTPOINT)
@@ -102,7 +121,7 @@
int nsh_archinitialize(void)
{
-#if defined(CONFIG_STM32_SPI1) || defined(CONFIG_STM32_SPI2)
+#ifdef CONFIG_STM32_SPI1
FAR struct spi_dev_s *spi;
int ret;
diff --git a/nuttx/configs/stm3210e-eval/src/up_spi.c b/nuttx/configs/stm3210e-eval/src/up_spi.c
index bfad4c5ae..756f1a8ae 100755
--- a/nuttx/configs/stm3210e-eval/src/up_spi.c
+++ b/nuttx/configs/stm3210e-eval/src/up_spi.c
@@ -169,7 +169,6 @@ void weak_function stm32_spiinitialize(void)
void stm32_spi1select(FAR struct spi_dev_s *dev, enum spi_dev_e devid, boolean selected)
{
spidbg("devid: %d CS: %s\n", (int)devid, selected ? "assert" : "de-assert");
- uint32 pinset;
if (devid == SPIDEV_MMCSD)
{