diff options
author | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2007-11-04 22:59:30 +0000 |
---|---|---|
committer | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2007-11-04 22:59:30 +0000 |
commit | 83705d736e7e957752226de8c2165aa9ff4deeaa (patch) | |
tree | 35763ac9f5bbba31583e967fb7e199f854b50928 /nuttx/examples/uip/main.c | |
parent | d71296f49b301d3ca8edcc6e9b79dd6b23a01c31 (diff) | |
download | px4-nuttx-83705d736e7e957752226de8c2165aa9ff4deeaa.tar.gz px4-nuttx-83705d736e7e957752226de8c2165aa9ff4deeaa.tar.bz2 px4-nuttx-83705d736e7e957752226de8c2165aa9ff4deeaa.zip |
Integrating with DM320
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@368 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx/examples/uip/main.c')
-rw-r--r-- | nuttx/examples/uip/main.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/nuttx/examples/uip/main.c b/nuttx/examples/uip/main.c index ded7bca20..eaac73a99 100644 --- a/nuttx/examples/uip/main.c +++ b/nuttx/examples/uip/main.c @@ -49,6 +49,7 @@ #include <string.h> #include <unistd.h> #include <time.h> +#include <debug.h> #include <net/uip/uip.h> #include <net/uip/uip-arp.h> @@ -140,17 +141,17 @@ int user_start(int argc, char *argv[]) #if !defined(CONFIG_EXAMPLE_UIP_DHCPC) /* Set up our host address */ - uip_ipaddr(addr.s_addr, 192, 168, 0, 128 ); + addr.s_addr = HTONL(CONFIG_EXAMPLE_UIP_IPADDR); uip_sethostaddr("eth0", &addr); /* Set up the default router address */ - uip_ipaddr(addr.s_addr, 192, 168, 0, 1); + addr.s_addr = HTONL(CONFIG_EXAMPLE_UIP_DRIPADDR); uip_setdraddr("eth0", &addr); /* Setup the subnet mask */ - uip_ipaddr(addr.s_addr, 255, 255, 255, 0); + addr.s_addr = HTONL(CONFIG_EXAMPLE_UIP_NETMASK); uip_setnetmask("eth0", &addr); #endif |