Add DM90x0 driver

git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@362 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
patacongo 2007-11-02 20:20:34 +00:00
parent 919be0394d
commit 7bb8831cf6
4 changed files with 12 additions and 11 deletions

View file

@ -100,5 +100,9 @@ void up_initialize(void)
/* Initialize the serial device driver */
up_serialinit();
/* Initialize the netwok */
up_netinitialize();
up_ledon(LED_IRQSENABLED);
}

View file

@ -157,6 +157,13 @@ extern void up_ledoff(int led);
# define up_ledoff(led)
#endif
/* Defined in board/up_network.c */
#ifdef CONFIG_NET
extern up_netinitialize(void);
#else
# define up_netinitialize()
#endif
#endif /* __ASSEMBLY__ */
#endif /* __UP_INTERNAL_H */

View file

@ -266,7 +266,7 @@ void tapdev_init(void)
/* Assign an IPv4 address to the tap device */
snprintf(buf, sizeof(buf), "ifconfig tap0 inet %d.%d.%d.%d\n",
snprintf(buf, sizeof(buf), "/sbin/ifconfig tap0 inet %d.%d.%d.%d\n",
UIP_IPADDR0, UIP_IPADDR1, UIP_IPADDR2, UIP_IPADDR3);
system(buf);
}

View file

@ -81,7 +81,6 @@ struct timer
****************************************************************************/
static struct timer g_periodic_timer;
static struct timer g_arp_timer;
static struct uip_driver_s g_sim_dev;
/****************************************************************************
@ -216,14 +215,6 @@ void uipdriver_loop(void)
}
}
#endif /* CONFIG_NET_UDP */
/* Call the ARP timer function every 10 seconds. */
if (timer_expired(&g_arp_timer))
{
timer_reset(&g_arp_timer);
uip_arp_timer();
}
}
sched_unlock();
}
@ -233,7 +224,6 @@ int uipdriver_init(void)
/* Internal initalization */
timer_set(&g_periodic_timer, 500);
timer_set(&g_arp_timer, 10000 );
tapdev_init();
(void)tapdev_getmacaddr(g_sim_dev.d_mac.addr);