summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2011-04-12 19:37:33 +0000
committerpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2011-04-12 19:37:33 +0000
commitc1c9b913a2f0cf2b6bdfb5ee9143796abfbad4d4 (patch)
tree51905004bdcb2d906dc66cc30d198655dfaf11ae
parent42d1c7ccb2a4b580da835788a332cea62e8165dc (diff)
downloadnuttx-c1c9b913a2f0cf2b6bdfb5ee9143796abfbad4d4.tar.gz
nuttx-c1c9b913a2f0cf2b6bdfb5ee9143796abfbad4d4.tar.bz2
nuttx-c1c9b913a2f0cf2b6bdfb5ee9143796abfbad4d4.zip
Fixes for clean LPCXpresso NSH build
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@3495 42af7a65-404d-4744-a932-0658087f49c3
-rw-r--r--apps/examples/nettest/Makefile2
-rw-r--r--apps/examples/udp/Makefile2
-rwxr-xr-xnuttx/configs/lpcxpresso-lpc1768/include/board.h5
-rwxr-xr-xnuttx/configs/lpcxpresso-lpc1768/nsh/defconfig2
-rwxr-xr-xnuttx/configs/lpcxpresso-lpc1768/src/up_nsh.c25
5 files changed, 24 insertions, 12 deletions
diff --git a/apps/examples/nettest/Makefile b/apps/examples/nettest/Makefile
index e9489a6be..323cac952 100644
--- a/apps/examples/nettest/Makefile
+++ b/apps/examples/nettest/Makefile
@@ -91,7 +91,7 @@ $(TARG_AOBJS): %$(OBJEXT): %.S
$(TARG_COBJS): %$(OBJEXT): %.c
$(call COMPILE, $<, $@)
-$(TARG_BIN): $(TARG_OBJS) $(HOST_BIN)
+"$(TARG_BIN)": $(TARG_OBJS) $(HOST_BIN)
@( for obj in $(TARG_OBJS) ; do \
$(call ARCHIVE, $@, $${obj}); \
done ; )
diff --git a/apps/examples/udp/Makefile b/apps/examples/udp/Makefile
index 8a4458d87..a9361ba6e 100644
--- a/apps/examples/udp/Makefile
+++ b/apps/examples/udp/Makefile
@@ -91,7 +91,7 @@ $(TARG_AOBJS): %$(OBJEXT): %.S
$(TARG_COBJS): %$(OBJEXT): %.c
$(call COMPILE, $<, $@)
-$(TARG_BIN): $(TARG_OBJS) $(HOST_BIN)
+"$(TARG_BIN)": $(TARG_OBJS) $(HOST_BIN)
@( for obj in $(TARG_OBJS) ; do \
$(call ARCHIVE, $@, $${obj}); \
done ; )
diff --git a/nuttx/configs/lpcxpresso-lpc1768/include/board.h b/nuttx/configs/lpcxpresso-lpc1768/include/board.h
index a6b2f697c..5229c1732 100755
--- a/nuttx/configs/lpcxpresso-lpc1768/include/board.h
+++ b/nuttx/configs/lpcxpresso-lpc1768/include/board.h
@@ -123,6 +123,11 @@
#define CONFIG_LP17_FLASH 1
#define BOARD_FLASHCFG_VALUE 0x0000303a
+/* Ethernet configuration */
+
+//#define ETH_MCFG_CLKSEL_DIV ETH_MCFG_CLKSEL_DIV44
+#define ETH_MCFG_CLKSEL_DIV ETH_MCFG_CLKSEL_DIV20
+
/* LED definitions ******************************************************************/
/* The LPCXpresso LPC1768 board has a single red LED (there are additional LEDs on
* the base board not considered here).
diff --git a/nuttx/configs/lpcxpresso-lpc1768/nsh/defconfig b/nuttx/configs/lpcxpresso-lpc1768/nsh/defconfig
index e0a7ada00..6cc69bbd0 100755
--- a/nuttx/configs/lpcxpresso-lpc1768/nsh/defconfig
+++ b/nuttx/configs/lpcxpresso-lpc1768/nsh/defconfig
@@ -116,7 +116,7 @@ CONFIG_LPC17_CAN1=n
CONFIG_LPC17_CAN2=n
CONFIG_LPC17_SPI=n
CONFIG_LPC17_SSP0=n
-CONFIG_LPC17_SSP1=y
+CONFIG_LPC17_SSP1=n
CONFIG_LPC17_I2C0=n
CONFIG_LPC17_I2C1=n
CONFIG_LPC17_I2S=n
diff --git a/nuttx/configs/lpcxpresso-lpc1768/src/up_nsh.c b/nuttx/configs/lpcxpresso-lpc1768/src/up_nsh.c
index ad64ab9b9..01b1df6db 100755
--- a/nuttx/configs/lpcxpresso-lpc1768/src/up_nsh.c
+++ b/nuttx/configs/lpcxpresso-lpc1768/src/up_nsh.c
@@ -57,7 +57,20 @@
#ifdef CONFIG_ARCH_BOARD_LPCXPRESSO
# define CONFIG_NSH_HAVEUSBDEV 1
-# define CONFIG_NSH_HAVEMMCSD 1
+# ifdef CONFIG_LPC17_SSP0
+# define CONFIG_NSH_HAVEMMCSD 1
+# else
+# undef CONFIG_NSH_HAVEMMCSD
+# endif
+#else
+# error "Unrecognized board"
+# undef CONFIG_NSH_HAVEUSBDEV
+# undef CONFIG_NSH_HAVEMMCSD
+#endif
+
+/* Do we have SPI support for MMC/SD? */
+
+#ifdef CONFIG_NSH_HAVEMMCSD
# if !defined(CONFIG_NSH_MMCSDSPIPORTNO) || CONFIG_NSH_MMCSDSPIPORTNO != 0
# error "The LPCXpresso MMC/SD is on SSP0"
# undef CONFIG_NSH_MMCSDSPIPORTNO
@@ -68,13 +81,6 @@
# undef CONFIG_NSH_MMCSDSLOTNO
# define CONFIG_NSH_MMCSDSLOTNO 0
# endif
-# ifndef CONFIG_LPC17_SSP0
-# warning "CONFIG_LPC17_SSP0 is not enabled"
-# endif
-#else
-# error "Unrecognized board"
-# undef CONFIG_NSH_HAVEUSBDEV
-# undef CONFIG_NSH_HAVEMMCSD
#endif
/* Can't support USB device features if USB device is not enabled */
@@ -131,6 +137,7 @@
int nsh_archinitialize(void)
{
+#ifdef CONFIG_NSH_HAVEMMCSD
FAR struct spi_dev_s *ssp;
int ret;
@@ -159,6 +166,6 @@ int nsh_archinitialize(void)
message("Successfuly bound SSP port %d to MMC/SD slot %d\n",
CONFIG_NSH_MMCSDSPIPORTNO, CONFIG_NSH_MMCSDSLOTNO);
-
+#endif
return OK;
}