From 5c3cbc2c327f3177d15f3bce463ea75601707816 Mon Sep 17 00:00:00 2001 From: patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> Date: Tue, 19 May 2009 20:14:44 +0000 Subject: [PATCH] lm3s6918 passes OS test git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@1801 42af7a65-404d-4744-a932-0658087f49c3 --- ChangeLog | 7 +- Documentation/NuttX.html | 7 +- TODO | 12 ++++ arch/arm/src/common/up_exit.c | 3 +- configs/eagle100/ostest/defconfig | 112 +++++++++++++++++++++++------- 5 files changed, 111 insertions(+), 30 deletions(-) diff --git a/ChangeLog b/ChangeLog index a97d79c1c7..ef2584a48b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -712,8 +712,11 @@ -R .note.gnu.build-id -R .comment" This has bin fixed in arch/arm/src/Makefile, but other architectures may have the same problem. Thanks to Dave Marples for verifying this. - * Began adding support for the MicroMint Eagle100 board. This board has a - Luminary LM3S6918 Cortex-M3. + * Added support for the MicroMint Eagle100 board. This board has a + Luminary LM3S6918 Cortex-M3. Added a configuration to build examples/ostest. * Add configuration option to enable fast GPIO (vs. legacy, "slow" GPIO) for LPC214x. + * Restructured the arch/arm directory structure to better suppor ARM and + Cortex-M3. + * pthread_create() must return a (non-negated) errno value on failure. diff --git a/Documentation/NuttX.html b/Documentation/NuttX.html index 268184ee6b..f936a8df0a 100644 --- a/Documentation/NuttX.html +++ b/Documentation/NuttX.html @@ -1421,10 +1421,13 @@ nuttx-0.4.6 2009-xx-xx Gregory Nutt <spudmonkey@racsa.co.cr> -R .note.gnu.build-id -R .comment" This has bin fixed in arch/arm/src/Makefile, but other architectures may have the same problem. Thanks to Dave Marples for verifying this. - * Began adding support for the MicroMint Eagle100 board. This board has a - Luminary LM3S6918 Cortex-M3. + * Added support for the MicroMint Eagle100 board. This board has a + Luminary LM3S6918 Cortex-M3. Added a configuration to build examples/ostest. * Add configuration option to enable fast GPIO (vs. legacy, "slow" GPIO) for LPC214x. + * Restructured the arch/arm directory structure to better suppor ARM and + Cortex-M3. + * pthread_create() must return a (non-negated) errno value on failure. pascal-0.1.3 2009-xx-xx Gregory Nutt <spudmonkey@racsa.co.cr> diff --git a/TODO b/TODO index af3018b61c..14fe0e8341 100644 --- a/TODO +++ b/TODO @@ -24,6 +24,7 @@ NuttX TODO List (Last updated April 12, 2009) (2) ARM/i.MX (arch/arm/src/imx/) (3) ARM/LPC214x (arch/arm/src/lpc214x/) (4) ARM/STR71x (arch/arm/src/str71x/) + (2) ARM/LM3S6918 (arch/arm/src/lm3s/) (4) pjrc-8052 / MCS51 (arch/pjrc-8051/) (2) Hitachi/Renesas SH-1 (arch/sh/src/sh1) (4) Renesas M16C/26 (arch/sh/src/m16c) @@ -543,6 +544,17 @@ o ARM/STR71x (arch/arm/src/str71x/) Status: Open Priority: Medium -- Will be very high if you do SPI access from multiple threads. +o ARM/LM3S6918 (arch/arm/src/lm3s/) + ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + + Description: Eagle-100 LEDs do not work. This has to be a simple problem to fix. + Status: Open + Priority: Low + + Description: Still need to implement I2C, SSI, MMC/SD, and Ethernet + Status: Open + Priority: High + o pjrc-8052 / MCS51 (arch/pjrc-8051/) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ diff --git a/arch/arm/src/common/up_exit.c b/arch/arm/src/common/up_exit.c index 63e086c390..dea5421811 100644 --- a/arch/arm/src/common/up_exit.c +++ b/arch/arm/src/common/up_exit.c @@ -1,7 +1,7 @@ /**************************************************************************** * common/up_exit.c * - * Copyright (C) 2007, 2008 Gregory Nutt. All rights reserved. + * Copyright (C) 2007-2009 Gregory Nutt. All rights reserved. * Author: Gregory Nutt <spudmonkey@racsa.co.cr> * * Redistribution and use in source and binary forms, with or without @@ -42,6 +42,7 @@ #include <sched.h> #include <debug.h> #include <nuttx/arch.h> + #include "os_internal.h" #include "up_internal.h" diff --git a/configs/eagle100/ostest/defconfig b/configs/eagle100/ostest/defconfig index 8f651378b9..f95cd1ad96 100644 --- a/configs/eagle100/ostest/defconfig +++ b/configs/eagle100/ostest/defconfig @@ -64,9 +64,10 @@ # CONFIG_ARCH_CALIBRATION - Enables some build in instrumentation that # cause a 100 second delay during boot-up. This 100 second delay # serves no purpose other than it allows you to calibratre -# CONFIG_ARCH_LOOPSPERMSEC. You simply use a stop watch to measure +# CONFIG_ARCH_LOOPSPERMSEC. You simply use a stop watch to measure # the 100 second delay then adjust CONFIG_ARCH_LOOPSPERMSEC until # the delay actually is 100 seconds. +# CONFIG_ARCH=arm CONFIG_ARCH_ARM=y CONFIG_ARCH_CORTEXM3=y @@ -296,19 +297,38 @@ CONFIG_ARCH_KFREE=n # timer structures to minimize dynamic allocations. Set to # zero for all dynamic allocations. # -CONFIG_MAX_TASKS=64 +CONFIG_MAX_TASKS=16 CONFIG_MAX_TASK_ARGS=4 CONFIG_NPTHREAD_KEYS=4 -CONFIG_NFILE_DESCRIPTORS=32 -CONFIG_NFILE_STREAMS=16 +CONFIG_NFILE_DESCRIPTORS=8 +CONFIG_NFILE_STREAMS=8 CONFIG_NAME_MAX=32 -CONFIG_STDIO_BUFFER_SIZE=1024 +CONFIG_STDIO_BUFFER_SIZE=256 CONFIG_NUNGET_CHARS=2 -CONFIG_PREALLOC_MQ_MSGS=32 +CONFIG_PREALLOC_MQ_MSGS=4 CONFIG_MQ_MAXMSGSIZE=32 -CONFIG_MAX_WDOGPARMS=4 -CONFIG_PREALLOC_WDOGS=32 -CONFIG_PREALLOC_TIMERS=8 +CONFIG_MAX_WDOGPARMS=2 +CONFIG_PREALLOC_WDOGS=4 +CONFIG_PREALLOC_TIMERS=4 + +# +# Filesystem configuration +# +# CONFIG_FS_FAT - Enable FAT filesystem support +# CONFIG_FAT_SECTORSIZE - Max supported sector size +# CONFIG_FS_ROMFS - Enable ROMFS filesystem support +CONFIG_FS_FAT=n +CONFIG_FS_ROMFS=n + +# +# SPI-based MMC/SD driver +# +# CONFIG_MMCSD_NSLOTS +# Number of MMC/SD slots supported by the driver +# CONFIG_MMCSD_READONLY +# Provide read-only access (default is read/write) +CONFIG_MMCSD_NSLOTS=1 +CONFIG_MMCSD_READONLY=n # # TCP/IP and UDP support via uIP @@ -336,6 +356,7 @@ CONFIG_PREALLOC_TIMERS=8 # CONFIG_NET_BROADCAST - Broadcast support # CONFIG_NET_LLH_LEN - The link level header length # CONFIG_NET_FWCACHE_SIZE - number of packets to remember when looking for duplicates +# CONFIG_NET=n CONFIG_NET_IPv6=n CONFIG_NSOCKET_DESCRIPTORS=0 @@ -361,11 +382,13 @@ CONFIG_NET_BROADCAST=n # UIP Network Utilities # CONFIG_NET_DHCP_LIGHT - Reduces size of DHCP # CONFIG_NET_RESOLV_ENTRIES - Number of resolver entries +# CONFIG_NET_DHCP_LIGHT=n CONFIG_NET_RESOLV_ENTRIES=4 # # Settings for examples/uip +# CONFIG_EXAMPLE_UIP_IPADDR=(10<<24|0<<16|0<<8|2) CONFIG_EXAMPLE_UIP_DRIPADDR=(10<<24|0<<16|0<<8|1) CONFIG_EXAMPLE_UIP_NETMASK=(255<<24|255<<16|255<<8|0) @@ -381,37 +404,76 @@ CONFIG_EXAMPLE_NETTEST_DRIPADDR=(10<<24|0<<16|0<<8|1) CONFIG_EXAMPLE_NETTEST_NETMASK=(255<<24|255<<16|255<<8|0) CONFIG_EXAMPLE_NETTEST_CLIENTIP=(10<<24|0<<16|0<<8|1) +# +# Settings for examples/ostest +# +CONFIG_EXAMPLES_OSTEST_LOOPS=1 +CONFIG_EXAMPLES_OSTEST_STACKSIZE=2048 +CONFIG_EXAMPLES_OSTEST_NBARRIER_THREADS=3 + # # Settings for examples/nsh +# +# CONFIG_EXAMPLES_NSH_FILEIOSIZE - Size of a static I/O buffer +# CONFIG_EXAMPLES_NSH_STRERROR - Use strerror(errno) +# CONFIG_EXAMPLES_NSH_LINELEN - Maximum length of one command line +# CONFIG_EXAMPLES_NSH_STACKSIZE - Stack size to use for new threads. +# CONFIG_EXAMPLES_NSH_NESTDEPTH - Max number of nested if-then[-else]-fi +# CONFIG_EXAMPLES_NSH_DISABLESCRIPT - Disable scripting support +# CONFIG_EXAMPLES_NSH_DISABLEBG - Disable background commands +# CONFIG_EXAMPLES_NSH_ROMFSETC - Use startup script in /etc +# CONFIG_EXAMPLES_NSH_CONSOLE - Use serial console front end +# CONFIG_EXAMPLES_NSH_TELNET - Use telnetd console front end +# +# If CONFIG_EXAMPLES_NSH_TELNET is selected: +# CONFIG_EXAMPLES_NSH_IOBUFFER_SIZE -- Telnetd I/O buffer size +# CONFIG_EXAMPLES_NSH_DHCPC - Obtain address using DHCP +# CONFIG_EXAMPLES_NSH_IPADDR - Provides static IP address +# CONFIG_EXAMPLES_NSH_DRIPADDR - Provides static router IP address +# CONFIG_EXAMPLES_NSH_NETMASK - Provides static network mask +# CONFIG_EXAMPLES_NSH_NOMAC - Use a bogus MAC address +# +# If CONFIG_EXAMPLES_NSH_ROMFSETC is selected: +# CONFIG_EXAMPLES_NSH_ROMFSMOUNTPT - ROMFS mountpoint +# CONFIG_EXAMPLES_NSH_INITSCRIPT - Relative path to init script +# CONFIG_EXAMPLES_NSH_ROMFSDEVNO - ROMFS RAM device minor +# CONFIG_EXAMPLES_NSH_ROMFSSECTSIZE - ROMF sector size +# CONFIG_EXAMPLES_NSH_FATDEVNO - FAT FS RAM device minor +# CONFIG_EXAMPLES_NSH_FATSECTSIZE - FAT FS sector size +# CONFIG_EXAMPLES_NSH_FATNSECTORS - FAT FS number of sectors +# CONFIG_EXAMPLES_NSH_FATMOUNTPT - FAT FS mountpoint +# +CONFIG_EXAMPLES_NSH_FILEIOSIZE=512 +CONFIG_EXAMPLES_NSH_STRERROR=n +CONFIG_EXAMPLES_NSH_LINELEN=64 +CONFIG_EXAMPLES_NSH_STACKSIZE=2048 +CONFIG_EXAMPLES_NSH_NESTDEPTH=3 +CONFIG_EXAMPLES_NSH_DISABLESCRIPT=n +CONFIG_EXAMPLES_NSH_DISABLEBG=n +CONFIG_EXAMPLES_NSH_ROMFSETC=n CONFIG_EXAMPLES_NSH_CONSOLE=y CONFIG_EXAMPLES_NSH_TELNET=n CONFIG_EXAMPLES_NSH_IOBUFFER_SIZE=512 -CONFIG_EXAMPLES_NSH_CMD_SIZE=40 -CONFIG_EXAMPLES_NSH_STACKSIZE=4096 CONFIG_EXAMPLES_NSH_DHCPC=n CONFIG_EXAMPLES_NSH_NOMAC=n CONFIG_EXAMPLES_NSH_IPADDR=(10<<24|0<<16|0<<8|2) CONFIG_EXAMPLES_NSH_DRIPADDR=(10<<24|0<<16|0<<8|1) CONFIG_EXAMPLES_NSH_NETMASK=(255<<24|255<<16|255<<8|0) - -# -# DM90x0 Driver Settings -CONFIG_NET_DM90x0=n -CONFIG_DM9X_NINTERFACES=1 -CONFIG_DM9X_STATS=n -CONFIG_DM9X_BASE=0xd0000300 -CONFIG_DM9X_IRQ=27 -CONFIG_DM9X_BUSWIDTH8=n -CONFIG_DM9X_BUSWIDTH16=y -CONFIG_DM9X_BUSWIDTH32=n -CONFIG_DM9X_CHECKSUM=n -CONFIG_DM9X_ETRANS=n +CONFIG_EXAMPLES_NSH_ROMFSMOUNTPT="/etc" +CONFIG_EXAMPLES_NSH_INITSCRIPT="init.d/rcS" +CONFIG_EXAMPLES_NSH_ROMFSDEVNO=0 +CONFIG_EXAMPLES_NSH_ROMFSSECTSIZE=64 +CONFIG_EXAMPLES_NSH_FATDEVNO=1 +CONFIG_EXAMPLES_NSH_FATSECTSIZE=512 +CONFIG_EXAMPLES_NSH_FATNSECTORS=1024 +CONFIG_EXAMPLES_NSH_FATMOUNTPT=/tmp # # Stack and heap information # # CONFIG_BOOT_RUNFROMFLASH - Some configurations support XIP # operation from FLASH but must copy initialized .data sections to RAM. +# (should also be =n for the Eagle100 which always runs from flash) # CONFIG_BOOT_COPYTORAM - Some configurations boot in FLASH # but copy themselves entirely into RAM for better performance. # CONFIG_CUSTOM_STACK - The up_ implementation will handle @@ -434,7 +496,7 @@ CONFIG_BOOT_COPYTORAM=n CONFIG_CUSTOM_STACK=n CONFIG_STACK_POINTER= CONFIG_IDLETHREAD_STACKSIZE=1024 -CONFIG_USERMAIN_STACKSIZE=4096 +CONFIG_USERMAIN_STACKSIZE=2048 CONFIG_PTHREAD_STACK_MIN=256 CONFIG_PTHREAD_STACK_DEFAULT=2048 CONFIG_HEAP_BASE= -- GitLab