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/nettest/nettest.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/nettest/nettest.c')
-rw-r--r-- | nuttx/examples/nettest/nettest.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/nuttx/examples/nettest/nettest.c b/nuttx/examples/nettest/nettest.c index 1afa21182..9bcee01ff 100644 --- a/nuttx/examples/nettest/nettest.c +++ b/nuttx/examples/nettest/nettest.c @@ -39,6 +39,7 @@ #include <nuttx/config.h> #include <stdio.h> +#include <debug.h> #include <net/uip/uip.h> #include <net/uip/uip-lib.h> @@ -80,17 +81,17 @@ int user_start(int argc, char *argv[]) /* Set up our host address */ - uip_ipaddr(addr.s_addr, 192, 168, 0, 128 ); + addr.s_addr = HTONL(CONFIG_EXAMPLE_NETTEST_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_NETTEST_DRIPADDR); uip_setdraddr("eth0", &addr); /* Setup the subnet mask */ - uip_ipaddr(addr.s_addr, 255, 255, 255, 0); + addr.s_addr = HTONL(CONFIG_EXAMPLE_NETTEST_NETMASK); uip_setnetmask("eth0", &addr); #ifdef CONFIG_NETTEST_SERVER |