diff --git a/configs/lpcxpresso-lpc1768/include/board.h b/configs/lpcxpresso-lpc1768/include/board.h index a6b2f697c4..5229c1732e 100755 --- a/configs/lpcxpresso-lpc1768/include/board.h +++ b/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/configs/lpcxpresso-lpc1768/nsh/defconfig b/configs/lpcxpresso-lpc1768/nsh/defconfig index e0a7ada00a..6cc69bbd01 100755 --- a/configs/lpcxpresso-lpc1768/nsh/defconfig +++ b/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/configs/lpcxpresso-lpc1768/src/up_nsh.c b/configs/lpcxpresso-lpc1768/src/up_nsh.c index ad64ab9b9e..01b1df6db7 100755 --- a/configs/lpcxpresso-lpc1768/src/up_nsh.c +++ b/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; }