9
0
Fork 0

Make NX and NXTEXT built-ins; extend stm3210e-eval/nsh2 config to run the NX example from the NX command line

git-svn-id: https://nuttx.svn.sourceforge.net/svnroot/nuttx/trunk@3791 7fd9a85b-ad96-42d3-883c-3090e2eb8679
This commit is contained in:
patacongo 2011-07-16 15:52:15 +00:00
parent e19c2575d4
commit 042acf7cfb
24 changed files with 312 additions and 33 deletions

View File

@ -72,3 +72,6 @@
6.7 2011-xx-xx Gregory Nutt <spudmonkey@racsa.co.cr>
* apps/examples/nx and nxtext: These examples can now be built as NSH
"built-in" commands.

View File

@ -2,8 +2,8 @@
# apps/Makefile
#
# Copyright (C) 2011 Uros Platise. All rights reserved.
# Author: Uros Platise <uros.platise@isotel.eu>
# Gregory Nutt <spudmonkey@racsa.co.cr>
# Authors: Uros Platise <uros.platise@isotel.eu>
# Gregory Nutt <spudmonkey@racsa.co.cr>
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions

View File

@ -41,12 +41,19 @@ SUBDIRS = buttons dhcpd ftpc hello helloxx hidkbd igmp mm mount nettest \
nsh null nx nxffs nxflat nxtext ostest pashello pipe poll rgmp romfs \
sendmail serloop thttpd udp uip usbserial usbstorage wget wlan
# Sub-directories that might need context setup
CNTXTDIRS = nx nxtext
all: nothing
.PHONY: nothing context depend clean distclean
nothing:
context:
@for dir in $(CNTXTDIRS) ; do \
$(MAKE) -C $$dir context TOPDIR="$(TOPDIR)" APPDIR="$(APPDIR)"; \
done
depend:
@for dir in $(SUBDIRS) ; do \

View File

@ -237,6 +237,8 @@ examples/nx
defined in include/nuttx/nx.h. The following configuration options
can be selected:
CONFIG_EXAMPLES_NX_BUILTIN -- Build the NX example as a "built-in"
that can be executed from the NSH command line
CONFIG_EXAMPLES_NX_VPLANE -- The plane to select from the frame-
buffer driver for use in the test. Default: 0
CONFIG_EXAMPLES_NX_DEVNO - The LCD device to select from the LCD
@ -322,6 +324,8 @@ examples/nxtest
The following configuration options can be selected:
CONFIG_EXAMPLES_NXTEXT_BUILTIN -- Build the NXTEXT example as a "built-in"
that can be executed from the NSH command line
CONFIG_EXAMPLES_NXTEXT_VPLANE -- The plane to select from the frame-
buffer driver for use in the test. Default: 0
CONFIG_EXAMPLES_NXTEXT_DEVNO - The LCD device to select from the LCD

View File

@ -59,12 +59,18 @@ endif
ROOTDEPPATH = --dep-path .
# NX built-in application info
APPNAME = nx
PRIORITY = SCHED_PRIORITY_DEFAULT
STACKSIZE = 2048
# Common build
VPATH =
all: .built
.PHONY: clean depend distclean
.PHONY: context clean depend distclean
$(AOBJS): %$(OBJEXT): %.S
$(call ASSEMBLE, $<, $@)
@ -78,7 +84,13 @@ $(COBJS): %$(OBJEXT): %.c
done ; )
@touch .built
context:
.context:
ifeq ($(CONFIG_EXAMPLES_NX_BUILTIN),y)
$(call REGISTER,$(APPNAME),$(PRIORITY),$(STACKSIZE),$(APPNAME)_main)
@touch $@
endif
context: .context
.depend: Makefile $(SRCS)
@$(MKDEP) $(ROOTDEPPATH) $(CC) -- $(CFLAGS) -- $(SRCS) >Make.dep

View File

@ -610,10 +610,14 @@ static int nxeg_initialize(void)
****************************************************************************/
/****************************************************************************
* Name: user_start
* Name: user_start/nx_main
****************************************************************************/
#ifdef CONFIG_EXAMPLES_NX_BUILTIN
int nx_main(int argc, char **argv)
#else
int user_start(int argc, char *argv[])
#endif
{
NXEGWINDOW hwnd1;
NXEGWINDOW hwnd2;

View File

@ -60,12 +60,18 @@ endif
ROOTDEPPATH = --dep-path .
# NXTEXT built-in application info
APPNAME = nxtext
PRIORITY = SCHED_PRIORITY_DEFAULT
STACKSIZE = 2048
# Common build
VPATH =
all: .built
.PHONY: clean depend distclean
.PHONY: context clean depend distclean
$(AOBJS): %$(OBJEXT): %.S
$(call ASSEMBLE, $<, $@)
@ -79,7 +85,13 @@ $(COBJS): %$(OBJEXT): %.c
done ; )
@touch .built
context:
.context:
ifeq ($(CONFIG_EXAMPLES_NXTEXT_BUILTIN),y)
$(call REGISTER,$(APPNAME),$(PRIORITY),$(STACKSIZE),$(APPNAME)_main)
@touch $@
endif
context: .context
.depend: Makefile $(SRCS)
@$(MKDEP) $(ROOTDEPPATH) $(CC) -- $(CFLAGS) -- $(SRCS) >Make.dep

View File

@ -339,10 +339,14 @@ static int nxtext_initialize(void)
****************************************************************************/
/****************************************************************************
* Name: user_start
* Name: user_start/nxtext_main
****************************************************************************/
#ifdef CONFIG_EXAMPLES_NXTEXT_BUILTIN
int nxtext_main(int argc, char **argv)
#else
int user_start(int argc, char *argv[])
#endif
{
FAR struct nxtext_state_s *bgstate;
NXWINDOW hwnd = NULL;

View File

@ -841,6 +841,11 @@ NSH-Specific Configuration Settings
The behavior of NSH can be modified with the following settings in
the configs/<board-name>/defconfig file:
* CONFIG_NSH_BUILTIN_APPS
Support external registered, "named" applications that can be
executed from the NSH command line (see apps/README.txt for
more information).
* CONFIG_NSH_FILEIOSIZE
Size of a static I/O buffer used for file access (ignored if
there is no filesystem). Default is 1024.

View File

@ -1917,3 +1917,9 @@
may be all upper or all lower case (but not mixed). If
CONFIG_FAT_LCNAMES is not selected, all filenames are strictly upper
case.
* configs/stm3210e-eval/nsh2: Console is back on UART1; Added
examplex/nx as an NSH "built-in" command as a demonstration.
* fs/fat/fs_fat32dirent.c: Fix an important bug in the directory
allocation (fat_allocatedirentry()). I looks like it could be
initializing the wrong sectors! NOTE: This function was in
fs_fat32utils.c in earlier releases.

View File

@ -2065,6 +2065,14 @@ nsh>
<th align="left" width="25%">Configuration</th>
<th align="left">Description</th>
</tr>
<tr>
<td valign="top"><b><code>CONFIG_NSH_BUILTIN_APPS</code></b></td>
<td>
Support external registered, &quot;named&quot; applications that can be
executed from the NSH command line (see apps/README.txt for
more information).
</td>
</tr>
<tr>
<td valign="top"><b><code>CONFIG_NSH_FILEIOSIZE</code></b></td>
<td>

View File

@ -106,7 +106,7 @@
<option name="useadddirectives" type="boolean" change-action="build">false</option>
<option name="linkconfig" type="string" change-action="build">Standard</option>
<option name="flashinfo" type="string" change-action="build">000000-0001FF</option>
<option name="ram" type="string" change-action="build">B8000-BfFFFF</option>
<option name="ram" type="string" change-action="build">B80000-BfFFFF</option>
<option name="rom" type="string" change-action="build">000000-03FFFF</option>
<option name="extio" type="string" change-action="build">000000-00FFFF</option>
<option name="intio" type="string" change-action="build">000000-0000FF</option>
@ -244,4 +244,4 @@
<breakpoints>
</breakpoints>
</project>
</project>

View File

@ -106,7 +106,7 @@
<option name="useadddirectives" type="boolean" change-action="build">false</option>
<option name="linkconfig" type="string" change-action="build">Standard</option>
<option name="flashinfo" type="string" change-action="build">000000-0001FF</option>
<option name="ram" type="string" change-action="build">B8000-BfFFFF</option>
<option name="ram" type="string" change-action="build">B80000-BfFFFF</option>
<option name="rom" type="string" change-action="build">000000-03FFFF</option>
<option name="extio" type="string" change-action="build">000000-00FFFF</option>
<option name="intio" type="string" change-action="build">000000-0000FF</option>
@ -244,4 +244,4 @@
<breakpoints>
</breakpoints>
</project>
</project>

View File

@ -106,7 +106,7 @@
<option name="useadddirectives" type="boolean" change-action="build">false</option>
<option name="linkconfig" type="string" change-action="build">Standard</option>
<option name="flashinfo" type="string" change-action="build">000000-0001FF</option>
<option name="ram" type="string" change-action="build">B8000-BfFFFF</option>
<option name="ram" type="string" change-action="build">B80000-BfFFFF</option>
<option name="rom" type="string" change-action="build">000000-03FFFF</option>
<option name="extio" type="string" change-action="build">000000-00FFFF</option>
<option name="intio" type="string" change-action="build">000000-0000FF</option>
@ -244,4 +244,4 @@
<breakpoints>
</breakpoints>
</project>
</project>

View File

@ -106,7 +106,7 @@
<option name="useadddirectives" type="boolean" change-action="build">false</option>
<option name="linkconfig" type="string" change-action="build">Standard</option>
<option name="flashinfo" type="string" change-action="build">000000-0001FF</option>
<option name="ram" type="string" change-action="build">B8000-BfFFFF</option>
<option name="ram" type="string" change-action="build">B80000-BfFFFF</option>
<option name="rom" type="string" change-action="build">000000-03FFFF</option>
<option name="extio" type="string" change-action="build">000000-00FFFF</option>
<option name="intio" type="string" change-action="build">000000-0000FF</option>
@ -244,4 +244,4 @@
<breakpoints>
</breakpoints>
</project>
</project>

View File

@ -106,7 +106,7 @@
<option name="useadddirectives" type="boolean" change-action="build">false</option>
<option name="linkconfig" type="string" change-action="build">Standard</option>
<option name="flashinfo" type="string" change-action="build">000000-0001FF</option>
<option name="ram" type="string" change-action="build">B8000-BfFFFF</option>
<option name="ram" type="string" change-action="build">B80000-BfFFFF</option>
<option name="rom" type="string" change-action="build">000000-03FFFF</option>
<option name="extio" type="string" change-action="build">000000-00FFFF</option>
<option name="intio" type="string" change-action="build">000000-0000FF</option>
@ -244,4 +244,4 @@
<breakpoints>
</breakpoints>
</project>
</project>

View File

@ -106,7 +106,7 @@
<option name="useadddirectives" type="boolean" change-action="build">false</option>
<option name="linkconfig" type="string" change-action="build">Standard</option>
<option name="flashinfo" type="string" change-action="build">000000-0001FF</option>
<option name="ram" type="string" change-action="build">B8000-BfFFFF</option>
<option name="ram" type="string" change-action="build">B80000-BfFFFF</option>
<option name="rom" type="string" change-action="build">000000-03FFFF</option>
<option name="extio" type="string" change-action="build">000000-00FFFF</option>
<option name="intio" type="string" change-action="build">000000-0000FF</option>
@ -244,4 +244,4 @@
<breakpoints>
</breakpoints>
</project>
</project>

View File

@ -461,9 +461,16 @@ Where <subdir> is one of the following:
Loader: DfuSe DfuSe
----------- ----------------------- --------------------------------
Serial Debug output: USART1 Debug output: USART1
Console: NSH output: USART1 NSH output: USART2 ***
Console: NSH output: USART1 NSH output: USART1 ***
----------- ----------------------- --------------------------------
I2C1 Disabled Enabled
----------- ----------------------- --------------------------------
Support for No Yes
Built-in
Apps
----------- ----------------------- --------------------------------
Built-in None apps/examples/nx
AppS
=========== ======================= ================================
* You will probably need to modify nsh/setenv.sh or nsh2/setenv.sh

View File

@ -529,16 +529,24 @@ CONFIG_FS_READAHEAD=n
CONFIG_FS_WRITEBUFFER=n
#
# SDIO-based MMC/SD driver
# STM32 SDIO-based MMC/SD driver
#
# CONFIG_SDIO_DMA
# SDIO driver supports DMA
# CONFIG_SDIO_DMA - Support DMA data transfers. Requires CONFIG_STM32_SDIO
# and CONFIG_STM32_DMA2.
# CONFIG_SDIO_PRI - Select SDIO interrupt prority. Default: 128
# CONFIG_SDIO_DMAPRIO - Select SDIO DMA interrupt priority.
# Default: Medium
# CONFIG_SDIO_WIDTH_D1_ONLY - Select 1-bit transfer mode. Default:
# 4-bit transfer mode.
# CONFIG_MMCSD_MMCSUPPORT
# Enable support for MMC cards
# CONFIG_MMCSD_HAVECARDDETECT
# SDIO driver card detection is 100% accurate
#
CONFIG_SDIO_DMA=y
#CONFIG_SDIO_PRI=128
#CONFIG_SDIO_DMAPRIO
#CONFIG_SDIO_WIDTH_D1_ONLY
CONFIG_MMCSD_MMCSUPPORT=n
CONFIG_MMCSD_HAVECARDDETECT=n
@ -726,6 +734,9 @@ CONFIG_EXAMPLES_OSTEST_NBARRIER_THREADS=3
#
# Settings for apps/nshlib
#
# CONFIG_NSH_BUILTIN_APPS - Support external registered,
# "named" applications that can be executed from the NSH
# command line (see apps/README.txt for more information).
# CONFIG_NSH_FILEIOSIZE - Size of a static I/O buffer
# CONFIG_NSH_STRERROR - Use strerror(errno)
# CONFIG_NSH_LINELEN - Maximum length of one command line
@ -757,6 +768,7 @@ CONFIG_EXAMPLES_OSTEST_NBARRIER_THREADS=3
# CONFIG_NSH_FATNSECTORS - FAT FS number of sectors
# CONFIG_NSH_FATMOUNTPT - FAT FS mountpoint
#
CONFIG_NSH_BUILTIN_APPS=n
CONFIG_NSH_FILEIOSIZE=512
CONFIG_NSH_STRERROR=n
CONFIG_NSH_LINELEN=64

View File

@ -37,5 +37,12 @@
CONFIGURED_APPS += examples/nsh
# The NSH applicatin library
CONFIGURED_APPS += nshlib
# The NX example configured as an NX built-in command
CONFIGURED_APPS += examples/nx

View File

@ -325,6 +325,8 @@ CONFIG_HAVE_LIBM=n
#CONFIG_APPS_DIR=
CONFIG_DEBUG=n
CONFIG_DEBUG_VERBOSE=n
CONFIG_DEBUG_GRAPHICS=n
CONFIG_DEBUG_LCD=n
CONFIG_DEBUG_SYMBOLS=n
CONFIG_MM_REGIONS=1
CONFIG_ARCH_LOWPUTC=y
@ -466,6 +468,15 @@ CONFIG_MAX_WDOGPARMS=2
CONFIG_PREALLOC_WDOGS=4
CONFIG_PREALLOC_TIMERS=4
#
# Framebuffer driver options
#
CONFIG_FB_CMAP=n
CONFIG_FB_HWCURSOR=n
CONFIG_FB_HWCURSORIMAGE=n
#CONFIG_FB_HWCURSORSIZE
#CONFIG_FB_TRANSPARENCY
#
# Filesystem configuration
#
@ -542,16 +553,24 @@ CONFIG_FS_READAHEAD=n
CONFIG_FS_WRITEBUFFER=n
#
# SDIO-based MMC/SD driver
# STM32 SDIO-based MMC/SD driver
#
# CONFIG_SDIO_DMA
# SDIO driver supports DMA
# CONFIG_SDIO_DMA - Support DMA data transfers. Requires CONFIG_STM32_SDIO
# and CONFIG_STM32_DMA2.
# CONFIG_SDIO_PRI - Select SDIO interrupt prority. Default: 128
# CONFIG_SDIO_DMAPRIO - Select SDIO DMA interrupt priority.
# Default: Medium
# CONFIG_SDIO_WIDTH_D1_ONLY - Select 1-bit transfer mode. Default:
# 4-bit transfer mode.
# CONFIG_MMCSD_MMCSUPPORT
# Enable support for MMC cards
# CONFIG_MMCSD_HAVECARDDETECT
# SDIO driver card detection is 100% accurate
#
CONFIG_SDIO_DMA=y
#CONFIG_SDIO_PRI=128
#CONFIG_SDIO_DMAPRIO
#CONFIG_SDIO_WIDTH_D1_ONLY
CONFIG_MMCSD_MMCSUPPORT=n
CONFIG_MMCSD_HAVECARDDETECT=n
@ -711,6 +730,116 @@ CONFIG_USBSTRG_PRODUCTSTR="USBdev Storage"
CONFIG_USBSTRG_VERSIONNO=0x0399
CONFIG_USBSTRG_REMOVABLE=y
#
# Graphics related configuration settings
#
# CONFIG_NX
# Enables overall support for graphics library and NX
# CONFIG_NX_MULTIUSER
# Configures NX in multi-user mode
# CONFIG_NX_NPLANES
# Some YUV color formats requires support for multiple planes,
# one for each color component. Unless you have such special
# hardware, this value should be undefined or set to 1
# CONFIG_NX_DISABLE_1BPP, CONFIG_NX_DISABLE_2BPP,
# CONFIG_NX_DISABLE_4BPP, CONFIG_NX_DISABLE_8BPP,
# CONFIG_NX_DISABLE_16BPP, CONFIG_NX_DISABLE_24BPP, and
# CONFIG_NX_DISABLE_32BPP
# NX supports a variety of pixel depths. You can save some
# memory by disabling support for unused color depths.
# CONFIG_NX_PACKEDMSFIRST
# If a pixel depth of less than 8-bits is used, then NX needs
# to know if the pixels pack from the MS to LS or from LS to MS
# CONFIG_NX_LCDDRIVER
# By default, NX builds to use a framebuffer driver (see
# include/nuttx/fb.h). If this option is defined, NX will
# build to use an LCD driver (see include/nuttx/lcd/lcd.h).
# CONFIG_LCD_MAXPOWER - The full-on power setting for an LCD device.
# CONFIG_LCD_MAXCONTRAST - The maximum contrast value for an LCD device.
# CONFIG_NX_MOUSE
# Build in support for mouse input
# CONFIG_NX_KBD
# Build in support of keypad/keyboard input
# CONFIG_NXTK_BORDERWIDTH
# Specifies with with of the border (in pixels) used with
# framed windows. The default is 4.
# CONFIG_NXTK_BORDERCOLOR1 and CONFIG_NXTK_BORDERCOLOR2
# Specify the colors of the border used with framed windows.
# CONFIG_NXTK_BORDERCOLOR2 is the shadow side color and so
# is normally darker. The default is medium and dark grey,
# respectively
# CONFIG_NXTK_AUTORAISE
# If set, a window will be raised to the top if the mouse position
# is over a visible portion of the window. Default: A mouse
# button must be clicked over a visible portion of the window.
# CONFIG_NXFONTS_CHARBITS
# The number of bits in the character set. Current options are
# only 7 and 8. The default is 7.
# CONFIG_NXFONT_SANS
# At present, there is only one font. But if there were were more,
# then this option would select the sans serif font.
#
# NX Multi-user only options:
#
# CONFIG_NX_BLOCKING
# Open the client message queues in blocking mode. In this case,
# nx_eventhandler() will not return until a message is received and processed.
# CONFIG_NX_MXSERVERMSGS and CONFIG_NX_MXCLIENTMSGS
# Specifies the maximum number of messages that can fit in
# the message queues. No additional resources are allocated, but
# this can be set to prevent flooding of the client or server with
# too many messages (CONFIG_PREALLOC_MQ_MSGS controls how many
# messages are pre-allocated).
#
CONFIG_NX=y
CONFIG_NX_MULTIUSER=n
CONFIG_NX_NPLANES=1
CONFIG_NX_DISABLE_1BPP=y
CONFIG_NX_DISABLE_2BPP=y
CONFIG_NX_DISABLE_4BPP=y
CONFIG_NX_DISABLE_8BPP=y
CONFIG_NX_DISABLE_16BPP=n
CONFIG_NX_DISABLE_24BPP=y
CONFIG_NX_DISABLE_32BPP=y
CONFIG_NX_PACKEDMSFIRST=n
CONFIG_NX_LCDDRIVER=y
CONFIG_LCD_MAXPOWER=1
CONFIG_LCD_MAXCONTRAST=1
CONFIG_NX_MOUSE=y
CONFIG_NX_KBD=y
#CONFIG_NXTK_BORDERWIDTH=4
CONFIG_NXTK_BORDERCOLOR1=0xd69a
CONFIG_NXTK_BORDERCOLOR2=0xad55
CONFIG_NXTK_AUTORAISE=n
CONFIG_NXFONT_SANS=y
CONFIG_NXFONTS_CHARBITS=7
CONFIG_NX_BLOCKING=y
CONFIG_NX_MXSERVERMSGS=32
CONFIG_NX_MXCLIENTMSGS=16
#
# STM3210E-EVAL LCD Hardware Configuration
#
# CONFIG_LCD_LANDSCAPE - Define for 320x240 display "landscape"
# support. Default is this 320x240 "landscape" orientation
# (this setting is informative only... not used).
# CONFIG_LCD_PORTRAIT - Define for 240x320 display "portrait"
# orientation support. In this orientation, the STM3210E-EVAL's
# LCD ribbon cable is at the bottom of the display. Default is
# 320x240 "landscape" orientation.
# CONFIG_LCD_RPORTRAIT - Define for 240x320 display "reverse
# portrait" orientation support. In this orientation, the
# STM3210E-EVAL's LCD ribbon cable is at the top of the display.
# Default is 320x240 "landscape" orientation.
# CONFIG_LCD_BACKLIGHT - Define to support an adjustable backlight
# using timer 1. The granularity of the settings is determined
# by CONFIG_LCD_MAXPOWER. Requires CONFIG_STM32_TIM1.
#
CONFIG_LCD_LANDSCAPE=n
CONFIG_LCD_PORTRAIT=n
CONFIG_LCD_RPORTRAIT=y
CONFIG_LCD_BACKLIGHT=n
#
# Settings for examples/uip
#
@ -739,6 +868,9 @@ CONFIG_EXAMPLES_OSTEST_NBARRIER_THREADS=3
#
# Settings for apps/nshlib
#
# CONFIG_NSH_BUILTIN_APPS - Support external registered,
# "named" applications that can be executed from the NSH
# command line (see apps/README.txt for more information).
# CONFIG_NSH_FILEIOSIZE - Size of a static I/O buffer
# CONFIG_NSH_STRERROR - Use strerror(errno)
# CONFIG_NSH_LINELEN - Maximum length of one command line
@ -772,6 +904,7 @@ CONFIG_EXAMPLES_OSTEST_NBARRIER_THREADS=3
# CONFIG_NSH_FATNSECTORS - FAT FS number of sectors
# CONFIG_NSH_FATMOUNTPT - FAT FS mountpoint
#
CONFIG_NSH_BUILTIN_APPS=y
CONFIG_NSH_FILEIOSIZE=512
CONFIG_NSH_STRERROR=n
CONFIG_NSH_LINELEN=64
@ -781,7 +914,7 @@ CONFIG_NSH_DISABLESCRIPT=n
CONFIG_NSH_DISABLEBG=n
CONFIG_NSH_ROMFSETC=n
CONFIG_NSH_CONSOLE=y
CONFIG_NSH_CONDEV="/dev/ttyS1"
#CONFIG_NSH_CONDEV="/dev/ttyS1"
CONFIG_NSH_TELNET=n
CONFIG_NSH_ARCHINIT=y
CONFIG_NSH_IOBUFFER_SIZE=512
@ -829,6 +962,52 @@ CONFIG_EXAMPLES_USBSERIAL_TRACETRANSFERS=n
CONFIG_EXAMPLES_USBSERIAL_TRACECONTROLLER=n
CONFIG_EXAMPLES_USBSERIAL_TRACEINTERRUPTS=n
#
# Settings for examples/nx
#
# CONFIG_EXAMPLES_NX_BUILTIN -- Build the NX example as a "built-in"
# that can be executed from the NSH command line
# CONFIG_EXAMPLES_NX_VPLANE -- The plane to select from the frame-
# buffer driver for use in the test. Default: 0
# CONFIG_EXAMPLES_NX_DEVNO - The LCD device to select from the LCD
# driver for use in the test: Default: 0
# CONFIG_EXAMPLES_NX_BGCOLOR -- The color of the background. Default depends on
# CONFIG_EXAMPLES_NX_BPP.
# CONFIG_EXAMPLES_NX_COLOR1 -- The color of window 1. Default depends on
# CONFIG_EXAMPLES_NX_BPP.
# CONFIG_EXAMPLES_NX_COLOR2 -- The color of window 2. Default depends on
# CONFIG_EXAMPLES_NX_BPP.
# CONFIG_EXAMPLES_NX_TBCOLOR -- The color of the toolbar. Default depends on
# CONFIG_EXAMPLES_NX_BPP.
# CONFIG_EXAMPLES_NX_FONTCOLOR -- The color of the toolbar. Default depends on
# CONFIG_EXAMPLES_NX_BPP.
# CONFIG_EXAMPLES_NX_BPP -- Pixels per pixel to use. Valid options
# include 2, 4, 8, 16, 24, and 32. Default is 32.
# CONFIG_EXAMPLES_NX_RAWWINDOWS -- Use raw windows; Default is to
# use pretty, framed NXTK windows with toolbars.
# CONFIG_EXAMPLES_NX_STACKSIZE -- The stacksize to use when creating
# the NX server. Default 2048
# CONFIG_EXAMPLES_NX_CLIENTPRIO -- The client priority. Default: 80
# CONFIG_EXAMPLES_NX_SERVERPRIO -- The server priority. Default: 120
# CONFIG_EXAMPLES_NX_NOTIFYSIGNO -- The signal number to use with
# nx_eventnotify(). Default: 4
#
CONFIG_EXAMPLES_NX_BUILTIN=y
CONFIG_EXAMPLES_NX_VPLANE=0
CONFIG_EXAMPLES_NX_DEVNO=0
CONFIG_EXAMPLES_NX_BGCOLOR=0x0011
CONFIG_EXAMPLES_NX_COLOR1=0xaedc
CONFIG_EXAMPLES_NX_COLOR2=0xe7ff
CONFIG_EXAMPLES_NX_TBCOLOR=0xd69a
CONFIG_EXAMPLES_NX_FONTCOLOR=0x0000
CONFIG_EXAMPLES_NX_BPP=16
CONFIG_EXAMPLES_NX_RAWWINDOWS=n
CONFIG_EXAMPLES_NX_STACKSIZE=2048
CONFIG_EXAMPLES_NX_CLIENTPRIO=80
CONFIG_EXAMPLES_NX_SERVERPRIO=120
CONFIG_EXAMPLES_NX_NOTIFYSIGNO=4
CONFIG_EXAMPLES_NX_EXTERNINIT=n
#
# Stack and heap information
#

View File

@ -457,8 +457,8 @@ CONFIG_ARCH_BZERO=n
CONFIG_MAX_TASKS=16
CONFIG_MAX_TASK_ARGS=4
CONFIG_NPTHREAD_KEYS=4
CONFIG_NFILE_DESCRIPTORS=12
CONFIG_NFILE_STREAMS=12
CONFIG_NFILE_DESCRIPTORS=8
CONFIG_NFILE_STREAMS=8
CONFIG_NAME_MAX=32
CONFIG_STDIO_BUFFER_SIZE=256
CONFIG_NUNGET_CHARS=2
@ -902,7 +902,7 @@ CONFIG_NSH_DISABLESCRIPT=n
CONFIG_NSH_DISABLEBG=n
CONFIG_NSH_ROMFSETC=n
CONFIG_NSH_CONSOLE=y
CONFIG_NSH_CONDEV="/dev/ttyS1"
#CONFIG_NSH_CONDEV="/dev/ttyS1"
CONFIG_NSH_TELNET=n
CONFIG_NSH_ARCHINIT=y
CONFIG_NSH_IOBUFFER_SIZE=512
@ -953,6 +953,8 @@ CONFIG_EXAMPLES_USBSERIAL_TRACEINTERRUPTS=n
#
# Settings for examples/nx
#
# CONFIG_EXAMPLES_NX_BUILTIN -- Build the NX example as a "built-in"
# that can be executed from the NSH command line
# CONFIG_EXAMPLES_NX_VPLANE -- The plane to select from the frame-
# buffer driver for use in the test. Default: 0
# CONFIG_EXAMPLES_NX_DEVNO - The LCD device to select from the LCD
@ -978,6 +980,7 @@ CONFIG_EXAMPLES_USBSERIAL_TRACEINTERRUPTS=n
# CONFIG_EXAMPLES_NX_NOTIFYSIGNO -- The signal number to use with
# nx_eventnotify(). Default: 4
#
CONFIG_EXAMPLES_NX_BUILTIN=n
CONFIG_EXAMPLES_NX_VPLANE=0
CONFIG_EXAMPLES_NX_DEVNO=0
CONFIG_EXAMPLES_NX_BGCOLOR=0x0011

View File

@ -953,6 +953,8 @@ CONFIG_EXAMPLES_USBSERIAL_TRACEINTERRUPTS=n
#
# Settings for examples/nx
#
# CONFIG_EXAMPLES_NX_BUILTIN -- Build the NX example as a "built-in"
# that can be executed from the NSH command line
# CONFIG_EXAMPLES_NX_VPLANE -- The plane to select from the frame-
# buffer driver for use in the test. Default: 0
# CONFIG_EXAMPLES_NX_DEVNO - The LCD device to select from the LCD
@ -978,6 +980,7 @@ CONFIG_EXAMPLES_USBSERIAL_TRACEINTERRUPTS=n
# CONFIG_EXAMPLES_NX_NOTIFYSIGNO -- The signal number to use with
# nx_eventnotify(). Default: 4
#
CONFIG_EXAMPLES_NX_BUILTIN=n
CONFIG_EXAMPLES_NX_VPLANE=0
CONFIG_EXAMPLES_NX_DEVNO=0
CONFIG_EXAMPLES_NX_BGCOLOR=0x0011
@ -996,6 +999,8 @@ CONFIG_EXAMPLES_NX_EXTERNINIT=n
#
# Settings for examples/nxtext
#
# CONFIG_EXAMPLES_NXTEXT_BUILTIN -- Build the NXTEXT example as a "built-in"
# that can be executed from the NSH command line
# CONFIG_EXAMPLES_NXTEXT_VPLANE -- The plane to select from the frame-
# buffer driver for use in the test. Default: 0
# CONFIG_EXAMPLES_NXTEXT_DEVNO - The LCD device to select from the LCD
@ -1028,7 +1033,8 @@ CONFIG_EXAMPLES_NX_EXTERNINIT=n
# thread. Default 80.
# CONFIG_EXAMPLES_NXTEXT_NOTIFYSIGNO -- The signal number to use with
# nx_eventnotify(). Default: 4
#
CONFIG_EXAMPLES_NXTEXT_BUILTIN=n
CONFIG_EXAMPLES_NXTEXT_VPLANE=0
CONFIG_EXAMPLES_NXTEXT_DEVNO=0
CONFIG_EXAMPLES_NXTEXT_BGCOLOR=0x0011

View File

@ -2258,7 +2258,7 @@ int fat_allocatedirentry(struct fat_mountpt_s *fs, struct fat_dirinfo_s *dirinfo
fs->fs_currentsector = fat_cluster2sector(fs, cluster);
memset(fs->fs_buffer, 0, fs->fs_hwsectorsize);
sector = sector;
sector = fs->fs_currentsector;
for (i = fs->fs_fatsecperclus; i; i--)
{
ret = fat_hwwrite(fs, fs->fs_buffer, sector, 1);