diff options
author | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2011-12-13 17:25:23 +0000 |
---|---|---|
committer | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2011-12-13 17:25:23 +0000 |
commit | f65c5cf1f7ca0ea9fb5a284da2b126aa6dcbae98 (patch) | |
tree | 3a0ef6dd84a82f722a6d042569629be6a9956d2d /apps/examples | |
parent | 8c2168cef52239100d8822d2d8eca412689c8ed3 (diff) | |
download | nuttx-f65c5cf1f7ca0ea9fb5a284da2b126aa6dcbae98.tar.gz nuttx-f65c5cf1f7ca0ea9fb5a284da2b126aa6dcbae98.tar.bz2 nuttx-f65c5cf1f7ca0ea9fb5a284da2b126aa6dcbae98.zip |
STM32 Ethernet bugfixes; STM3240G-EVAL DHCPD configuration; fixes for IP address order bugs in DHCPD
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@4168 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'apps/examples')
-rw-r--r-- | apps/examples/dhcpd/Makefile | 16 | ||||
-rw-r--r-- | apps/examples/dhcpd/host.c | 4 | ||||
-rw-r--r-- | apps/examples/dhcpd/target.c | 22 | ||||
-rw-r--r-- | apps/examples/nettest/nettest_client.c | 2 | ||||
-rw-r--r-- | apps/examples/usbstorage/Makefile | 2 | ||||
-rw-r--r-- | apps/examples/usbstorage/usbstrg_main.c | 2 |
6 files changed, 36 insertions, 12 deletions
diff --git a/apps/examples/dhcpd/Makefile b/apps/examples/dhcpd/Makefile index 219cfb865..3254a9806 100644 --- a/apps/examples/dhcpd/Makefile +++ b/apps/examples/dhcpd/Makefile @@ -2,7 +2,7 @@ # apps/examples/dhcpd/Makefile # # Copyright (C) 2009-2011 Gregory Nutt. All rights reserved. -# Author: Gregory Nutt <spudmonkey@racsa.co.cr> +# Author: Gregory Nutt <gnutt@nuttx.org> # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions @@ -56,6 +56,12 @@ endif ROOTDEPPATH = --dep-path . +# DHCPD built-in application info + +APPNAME = dhcpd +PRIORITY = SCHED_PRIORITY_DEFAULT +STACKSIZE = 2048 + # Common build VPATH = @@ -75,7 +81,13 @@ $(COBJS): %$(OBJEXT): %.c done ; ) @touch .built -context: +.context: +ifeq ($(CONFIG_NSH_BUILTIN_APPS),y) + $(call REGISTER,$(APPNAME),$(PRIORITY),$(STACKSIZE),$(APPNAME)_main) + @touch $@ +endif + +context: .context .depend: Makefile $(SRCS) @$(MKDEP) $(ROOTDEPPATH) $(CC) -- $(CFLAGS) -- $(SRCS) >Make.dep diff --git a/apps/examples/dhcpd/host.c b/apps/examples/dhcpd/host.c index 9e654819b..479a845c1 100644 --- a/apps/examples/dhcpd/host.c +++ b/apps/examples/dhcpd/host.c @@ -1,8 +1,8 @@ /**************************************************************************** * examples/dhcpd/host.c * - * Copyright (C) 2007, 2009 Gregory Nutt. All rights reserved. - * Author: Gregory Nutt <spudmonkey@racsa.co.cr> + * Copyright (C) 2007, 2009, 2011 Gregory Nutt. All rights reserved. + * Author: Gregory Nutt <gnutt@nuttx.org> * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions diff --git a/apps/examples/dhcpd/target.c b/apps/examples/dhcpd/target.c index d394da02e..350bfe15f 100644 --- a/apps/examples/dhcpd/target.c +++ b/apps/examples/dhcpd/target.c @@ -2,7 +2,7 @@ * examples/dhcpd/target.c * * Copyright (C) 2009, 2011 Gregory Nutt. All rights reserved. - * Author: Gregory Nutt <spudmonkey@racsa.co.cr> + * Author: Gregory Nutt <gnutt@nuttx.org> * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -53,7 +53,7 @@ /* Configuation Checkes *****************************************************/ /* BEWARE: - * There are other configuration settings needed in netutitls/dhcpd/dhcpdc.s, + * There are other configuration settings needed in netutils/dhcpd/dhcpdc.c, * but there are default values for those so we cannot check them here. */ @@ -62,7 +62,7 @@ #endif #ifndef CONFIG_EXAMPLE_DHCPD_DRIPADDR -# error "You must define " +# error "You must define CONFIG_EXAMPLE_DHCPD_DRIPADDR" #endif #ifndef CONFIG_EXAMPLE_DHCPD_NETMASK @@ -81,15 +81,27 @@ # error "You must define CONFIG_NET_BROADCAST" #endif +/* If CONFIG_NSH_BUILTIN_APPS is defined, then it is assumed that you want + * to execute the DHCPD daemon as an NSH built-in task. + */ + +#ifdef CONFIG_NSH_BUILTIN_APPS +# define MAIN_NAME dhcpd_main +# define MAIN_NAME_STRING "dhcpd_main" +#else +# define MAIN_NAME user_start +# define MAIN_NAME_STRING "user_start" +#endif + /**************************************************************************** * Private Data ****************************************************************************/ /**************************************************************************** - * user_start + * Name: user_start/dhcpd_main ****************************************************************************/ -int user_start(int argc, char *argv[]) +int MAIN_NAME(int argc, char *argv[]) { struct in_addr addr; #if defined(CONFIG_EXAMPLE_DHCPD_NOMAC) diff --git a/apps/examples/nettest/nettest_client.c b/apps/examples/nettest/nettest_client.c index b879f8438..516898cde 100644 --- a/apps/examples/nettest/nettest_client.c +++ b/apps/examples/nettest/nettest_client.c @@ -123,7 +123,7 @@ void send_client(void) } #ifdef CONFIG_EXAMPLE_NETTEST_PERFORMANCE - /* Then receive messages forever */ + /* Then send messages forever */ for (;;) { diff --git a/apps/examples/usbstorage/Makefile b/apps/examples/usbstorage/Makefile index e821468be..98181e0fd 100644 --- a/apps/examples/usbstorage/Makefile +++ b/apps/examples/usbstorage/Makefile @@ -56,7 +56,7 @@ endif ROOTDEPPATH = --dep-path . -# NXTEXT built-in application info +# USB storage built-in application info APPNAME1 = msconn PRIORITY1 = SCHED_PRIORITY_DEFAULT diff --git a/apps/examples/usbstorage/usbstrg_main.c b/apps/examples/usbstorage/usbstrg_main.c index c48bd3394..884a5929a 100644 --- a/apps/examples/usbstorage/usbstrg_main.c +++ b/apps/examples/usbstorage/usbstrg_main.c @@ -2,7 +2,7 @@ * examples/usbstorage/usbstrg_main.c * * Copyright (C) 2008-2011 Gregory Nutt. All rights reserved. - * Author: Gregory Nutt <spudmonkey@racsa.co.cr> + * Author: Gregory Nutt <gnutt@nuttx.org> * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions |