Soe we're finally bak at reducing the memory footprint be avoiding to pull in large C-library enitities.
This commit is contained in:
parent
805f3f87d3
commit
c7a24bf6cf
1 changed files with 3 additions and 9 deletions
|
@ -30,12 +30,11 @@
|
||||||
*
|
*
|
||||||
* Author: Oliver Schmidt <ol.sc@web.de>
|
* Author: Oliver Schmidt <ol.sc@web.de>
|
||||||
*
|
*
|
||||||
* $Id: contiki-main.c,v 1.11 2007/11/27 21:50:46 oliverschmidt Exp $
|
* $Id: contiki-main.c,v 1.12 2007/12/16 13:07:35 oliverschmidt Exp $
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
|
||||||
|
|
||||||
#include "contiki-net.h"
|
#include "contiki-net.h"
|
||||||
|
#include "sys/log.h"
|
||||||
#include "lib/config.h"
|
#include "lib/config.h"
|
||||||
#include "net/ethernet-drv.h"
|
#include "net/ethernet-drv.h"
|
||||||
|
|
||||||
|
@ -87,29 +86,24 @@ main(void)
|
||||||
uip_ipaddr_t addr;
|
uip_ipaddr_t addr;
|
||||||
|
|
||||||
uip_ipaddr(&addr, 192,168,0,128);
|
uip_ipaddr(&addr, 192,168,0,128);
|
||||||
fprintf(stderr, "IP Address: %d.%d.%d.%d\n", uip_ipaddr_to_quad(&addr));
|
|
||||||
uip_sethostaddr(&addr);
|
uip_sethostaddr(&addr);
|
||||||
|
|
||||||
uip_ipaddr(&addr, 255,255,255,0);
|
uip_ipaddr(&addr, 255,255,255,0);
|
||||||
fprintf(stderr, "Subnet Mask: %d.%d.%d.%d\n", uip_ipaddr_to_quad(&addr));
|
|
||||||
uip_setnetmask(&addr);
|
uip_setnetmask(&addr);
|
||||||
|
|
||||||
uip_ipaddr(&addr, 192,168,0,1);
|
uip_ipaddr(&addr, 192,168,0,1);
|
||||||
fprintf(stderr, "Def. Router: %d.%d.%d.%d\n", uip_ipaddr_to_quad(&addr));
|
|
||||||
uip_setdraddr(&addr);
|
uip_setdraddr(&addr);
|
||||||
|
|
||||||
uip_ipaddr(&addr, 192,168,0,1);
|
uip_ipaddr(&addr, 192,168,0,1);
|
||||||
fprintf(stderr, "DNS Server: %d.%d.%d.%d\n", uip_ipaddr_to_quad(&addr));
|
|
||||||
resolv_conf(&addr);
|
resolv_conf(&addr);
|
||||||
|
|
||||||
fprintf(stderr, "Eth. Driver: %s at $%X\n", config.name, config.addr);
|
|
||||||
ethernet_config = &config;
|
ethernet_config = &config;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
process_start((struct process *)ðernet_process, (char *)ethernet_config);
|
process_start((struct process *)ðernet_process, (char *)ethernet_config);
|
||||||
|
|
||||||
fprintf(stderr, "Contiki up and running ...\n");
|
log_message("Contiki up and running ...", "");
|
||||||
|
|
||||||
while(1) {
|
while(1) {
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue