diff --git a/nuttx/configs/ekk-lm3s9b96/nsh/defconfig b/nuttx/configs/ekk-lm3s9b96/nsh/defconfig index 8803bec0bb..e7eacb2f91 100644 --- a/nuttx/configs/ekk-lm3s9b96/nsh/defconfig +++ b/nuttx/configs/ekk-lm3s9b96/nsh/defconfig @@ -73,9 +73,9 @@ CONFIG_ARCH_CORTEXM3=y CONFIG_ARCH_CHIP=lm3s CONFIG_ARCH_CHIP_LM3S9B96=y CONFIG_ARCH_BOARD=ekk-lm3s9b96 -CONFIG_ARCH_BOARD_EKK_LM3S9B96=y +CONFIG_ARCH_BOARD_EKKLM3S9B96=y CONFIG_BOARD_LOOPSPERMSEC=4531 -CONFIG_DRAM_SIZE=0x00010000 +CONFIG_DRAM_SIZE=0x00018000 CONFIG_DRAM_START=0x20000000 CONFIG_DRAM_END=(CONFIG_DRAM_START+CONFIG_DRAM_SIZE) CONFIG_ARCH_IRQPRIO=y @@ -161,8 +161,8 @@ CONFIG_UART2_2STOP=0 # value is large, then larger values of this setting may cause # Rx FIFO overrun errors. Default: half of the Tx FIFO size (4). # -CONFIG_SSI0_DISABLE=n -CONFIG_SSI1_DISABLE=n +CONFIG_SSI0_DISABLE=y +CONFIG_SSI1_DISABLE=y CONFIG_SSI_POLLWAIT=y #CONFIG_SSI_TXLIMIT=4 @@ -424,6 +424,14 @@ CONFIG_FS_FAT=y CONFIG_FS_ROMFS=n CONFIG_NFS=y +# +# SPI-based MMC/SD driver +# +# CONFIG_MMCSD_NSLOTS +# Number of MMC/SD slots supported by the driver +# +CONFIG_MMCSD_NSLOTS=0 + # # TCP/IP and UDP support via uIP # CONFIG_NET - Enable or disable all network features @@ -452,7 +460,7 @@ CONFIG_NFS=y # CONFIG_NET=y CONFIG_NET_IPv6=n -CONFIG_NSOCKET_DESCRIPTORS=8 +CONFIG_NSOCKET_DESCRIPTORS=40 CONFIG_NET_SOCKOPTS=y CONFIG_NET_BUFSIZE=562 CONFIG_NET_TCP=y diff --git a/nuttx/configs/ekk-lm3s9b96/ostest/defconfig b/nuttx/configs/ekk-lm3s9b96/ostest/defconfig index f3db6bb24c..bb7d02647e 100644 --- a/nuttx/configs/ekk-lm3s9b96/ostest/defconfig +++ b/nuttx/configs/ekk-lm3s9b96/ostest/defconfig @@ -73,9 +73,9 @@ CONFIG_ARCH_CORTEXM3=y CONFIG_ARCH_CHIP=lm3s CONFIG_ARCH_CHIP_LM3S9B96=y CONFIG_ARCH_BOARD=ekk-lm3s9b96 -CONFIG_ARCH_BOARD_EKK_LM3S9B96=y +CONFIG_ARCH_BOARD_EKKLM3S9B96=y CONFIG_BOARD_LOOPSPERMSEC=4531 -CONFIG_DRAM_SIZE=0x00010000 +CONFIG_DRAM_SIZE=0x00018000 CONFIG_DRAM_START=0x20000000 CONFIG_DRAM_END=(CONFIG_DRAM_START+CONFIG_DRAM_SIZE) CONFIG_ARCH_IRQPRIO=y @@ -161,8 +161,8 @@ CONFIG_UART2_2STOP=0 # value is large, then larger values of this setting may cause # Rx FIFO overrun errors. Default: half of the Tx FIFO size (4). # -CONFIG_SSI0_DISABLE=n -CONFIG_SSI1_DISABLE=n +CONFIG_SSI0_DISABLE=y +CONFIG_SSI1_DISABLE=y CONFIG_SSI_POLLWAIT=y #CONFIG_SSI_TXLIMIT=4 @@ -423,6 +423,14 @@ CONFIG_FS_FAT=n CONFIG_FS_ROMFS=n CONFIG_NFS=n +# +# SPI-based MMC/SD driver +# +# CONFIG_MMCSD_NSLOTS +# Number of MMC/SD slots supported by the driver +# +CONFIG_MMCSD_NSLOTS=0 + # # TCP/IP and UDP support via uIP # CONFIG_NET - Enable or disable all network features diff --git a/nuttx/configs/lm3s6965-ek/README.txt b/nuttx/configs/lm3s6965-ek/README.txt index 122ef816ae..5f122d03a6 100755 --- a/nuttx/configs/lm3s6965-ek/README.txt +++ b/nuttx/configs/lm3s6965-ek/README.txt @@ -436,6 +436,10 @@ Where is one of the following: driver is waiting for the network to come up. That is probably a bug in the Ethernet driver behavior! + Network File System (NFS) support can be added by setting the + following in your configuration file: + + CONFIG_NFS=y nx: And example using the NuttX graphics system (NX). This example uses the P14201 OLED driver. diff --git a/nuttx/configs/lm3s6965-ek/nsh/defconfig b/nuttx/configs/lm3s6965-ek/nsh/defconfig index 264ad28609..2621c81473 100755 --- a/nuttx/configs/lm3s6965-ek/nsh/defconfig +++ b/nuttx/configs/lm3s6965-ek/nsh/defconfig @@ -418,8 +418,10 @@ CONFIG_PREALLOC_TIMERS=4 # CONFIG_FS_FAT - Enable FAT filesystem support # CONFIG_FAT_SECTORSIZE - Max supported sector size # CONFIG_FS_ROMFS - Enable ROMFS filesystem support +# CONFIG_NFS - Enable NFS filesystem support CONFIG_FS_FAT=y CONFIG_FS_ROMFS=n +CONFIG_NFS=n # # SPI-based MMC/SD driver diff --git a/nuttx/configs/stm3210e-eval/src/stm3210e-internal.h b/nuttx/configs/stm3210e-eval/src/stm3210e-internal.h index 12021eee00..e6bf825a90 100644 --- a/nuttx/configs/stm3210e-eval/src/stm3210e-internal.h +++ b/nuttx/configs/stm3210e-eval/src/stm3210e-internal.h @@ -304,6 +304,18 @@ void stm32_deselectlcd(void); #endif /* CONFIG_STM32_FSMC */ +/************************************************************************************ + * Name: up_unregisterbuttons + * + * Description: + * Un-register button handlers + * + ************************************************************************************/ + +#if defined(CONFIG_PM) && defined(CONFIG_IDLE_CUSTOM) +void up_unregisterbuttons(void); +#endif + #endif /* __ASSEMBLY__ */ #endif /* __CONFIGS_STM3210E_EVAL_SRC_STM3210E_INTERNAL_H */ diff --git a/nuttx/configs/stm3210e-eval/src/up_idle.c b/nuttx/configs/stm3210e-eval/src/up_idle.c index 9b6432da81..27784056bf 100644 --- a/nuttx/configs/stm3210e-eval/src/up_idle.c +++ b/nuttx/configs/stm3210e-eval/src/up_idle.c @@ -123,23 +123,43 @@ static void up_idlepm(void) switch (newstate) { case PM_NORMAL: + break; case PM_IDLE: + { + /* Check if the buttons have already been registered */ + + up_unregisterbuttons(); + + /* Initialize the buttoms to wake up the system from the idle + * mode + */ + + up_pmbuttons(); + } break; case PM_STANDBY: - /* Configure all the buttons as wakeup EXTI */ + { + /* Check if the buttons have already been registered */ - up_pmbuttons(); + up_unregisterbuttons(); - /* Call the STM32 stop mode */ + /* Configure all the buttons as wakeup EXTI */ - stm32_pmstop(true); + up_pmbuttons(); + + /* Call the STM32 stop mode */ + + stm32_pmstop(true); + } break; case PM_SLEEP: - (void)stm32_pmstandby(); + { + (void)stm32_pmstandby(); + } break; default: @@ -182,12 +202,8 @@ void up_idle(void) /* Perform IDLE mode power management */ - up_idlepm(); - - /* Sleep until an interrupt occurs to save power */ - BEGIN_IDLE(); - __asm("wfi"); + up_idlepm(); END_IDLE(); #endif } diff --git a/nuttx/configs/stm3210e-eval/src/up_lcd.c b/nuttx/configs/stm3210e-eval/src/up_lcd.c index e44699db6a..784adaa061 100644 --- a/nuttx/configs/stm3210e-eval/src/up_lcd.c +++ b/nuttx/configs/stm3210e-eval/src/up_lcd.c @@ -1740,7 +1740,7 @@ int up_lcdinitialize(void) #ifdef CONFIG_PM ret = pm_register(&g_lcdcb); - if (ret =! OK) + if (ret != OK) { lcddbg("ERROR: pm_register failed: %d\n", ret); } diff --git a/nuttx/configs/stm3210e-eval/src/up_pmbuttons.c b/nuttx/configs/stm3210e-eval/src/up_pmbuttons.c index c90cf1c531..527f461639 100644 --- a/nuttx/configs/stm3210e-eval/src/up_pmbuttons.c +++ b/nuttx/configs/stm3210e-eval/src/up_pmbuttons.c @@ -186,7 +186,7 @@ static int button7_handler(int irq, FAR void *context); * Private Data ****************************************************************************/ - /* Button Names */ +/* Button Names */ static const struct button_info_s g_buttoninfo[NUM_PMBUTTONS] = { @@ -260,11 +260,17 @@ static const struct button_info_s g_buttoninfo[NUM_PMBUTTONS] = * Private Functions ****************************************************************************/ +/**************************************************************************** + * Name: button_handler + * + * Description: + * Handle a button wake-up interrupt + * + ****************************************************************************/ + #ifdef CONFIG_ARCH_IRQBUTTONS static void button_handler(int id, int irq) { - int i; - /* At this point the MCU should have already awakened. Just report some * activity in order to drive the rest of the system to the PM_NORMAL state */ @@ -273,10 +279,7 @@ static void button_handler(int id, int irq) /* Un-register button handlers */ - for (i = CONFIG_PM_IRQBUTTONS_MIN; i <= CONFIG_PM_IRQBUTTONS_MAX; i++) - { - (void)up_irqbutton(i, NULL); - } + up_unregisterbuttons(); } #if MIN_BUTTON < 1 @@ -379,4 +382,23 @@ void up_pmbuttons(void) #endif } +/**************************************************************************** + * Name: up_unregisterbuttons + * + * Description: + * Un-register button handlers + * + ****************************************************************************/ + +void up_unregisterbuttons(void) +{ +#ifdef CONFIG_ARCH_IRQBUTTONS +int i; + for (i = CONFIG_PM_IRQBUTTONS_MIN; i <= CONFIG_PM_IRQBUTTONS_MAX; i++) + { + (void)up_irqbutton(i, NULL); + } +#endif +} + #endif /* defined(CONFIG_PM) && defined(CONFIG_IDLE_CUSTOM) */