mirror of
https://gitee.com/Vancouver2017/luban-lite-t3e-pro.git
synced 2025-12-15 19:08:54 +00:00
v1.0.3
This commit is contained in:
@@ -12,7 +12,7 @@
|
||||
#include "netif_startup.h"
|
||||
#include <aic_core.h>
|
||||
|
||||
#ifdef AIC_USING_RTL8733_WLAN0
|
||||
#ifdef AIC_USING_REALTEK_WLAN0
|
||||
#include "ethernetif_wlan.h"
|
||||
#endif
|
||||
|
||||
@@ -100,22 +100,27 @@ void netif_startup(void)
|
||||
#endif /* LWIP_IPV4 */
|
||||
#endif /* WLAN */
|
||||
|
||||
#ifdef AIC_USING_RTL8733_WLAN0
|
||||
#ifdef AIC_USING_REALTEK_WLAN0
|
||||
#if LWIP_IPV4
|
||||
#if !LWIP_DHCP
|
||||
ip4addr_aton(AIC_DEV_RTL8733_WLAN0_GW, &gw);
|
||||
ip4addr_aton(AIC_DEV_RTL8733_WLAN0_IPADDR, &ipaddr);
|
||||
ip4addr_aton(AIC_DEV_RTL8733_WLAN0_NETMASK, &netmask);
|
||||
ip4addr_aton(AIC_DEV_REALTEK_WLAN0_GW, &gw);
|
||||
ip4addr_aton(AIC_DEV_REALTEK_WLAN0_IPADDR, &ipaddr);
|
||||
ip4addr_aton(AIC_DEV_REALTEK_WLAN0_NETMASK, &netmask);
|
||||
#endif /* !LWIP_DHCP */
|
||||
/* wlan init */
|
||||
init_wlan_netif(&ipaddr, &netmask, &gw);
|
||||
#else
|
||||
init_wlan_netif();
|
||||
#endif /* LWIP_IPV4 */
|
||||
#endif /* AIC_USING_RTL8733_WLAN0 */
|
||||
#endif /* AIC_USING_REALTEK_WLAN0 */
|
||||
|
||||
if (netif_list == NULL) {
|
||||
printf("LwIP startup error!, Make sure you have enabled gmac or wlan\n");
|
||||
return;
|
||||
}
|
||||
|
||||
/* the first netif as the default netif */
|
||||
for (netif = netif_list; netif != NULL; netif = netif->next) {
|
||||
for (netif = netif_list; netif->next != NULL; netif = netif->next) {
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/*
|
||||
/*
|
||||
* Copyright (c) 2001,2002 Florian Schulze.
|
||||
* All rights reserved.
|
||||
*
|
||||
@@ -471,98 +471,6 @@ dns_dorequest(void *arg)
|
||||
}
|
||||
#endif /* LWIP_DNS_APP && LWIP_DNS */
|
||||
|
||||
/* This function initializes applications */
|
||||
static void
|
||||
apps_init(void)
|
||||
{
|
||||
#if LWIP_DNS_APP && LWIP_DNS
|
||||
/* wait until the netif is up (for dhcp, autoip or ppp) */
|
||||
sys_timeout(5000, dns_dorequest, NULL);
|
||||
#endif /* LWIP_DNS_APP && LWIP_DNS */
|
||||
|
||||
#if LWIP_CHARGEN_APP && LWIP_SOCKET
|
||||
chargen_init();
|
||||
#endif /* LWIP_CHARGEN_APP && LWIP_SOCKET */
|
||||
|
||||
#if LWIP_PING_APP && LWIP_RAW && LWIP_ICMP
|
||||
ping_init(&netif_default->gw);
|
||||
#endif /* LWIP_PING_APP && LWIP_RAW && LWIP_ICMP */
|
||||
|
||||
#if LWIP_NETBIOS_APP && LWIP_UDP
|
||||
netbiosns_init();
|
||||
#ifndef NETBIOS_LWIP_NAME
|
||||
#if LWIP_NETIF_HOSTNAME
|
||||
netbiosns_set_name(netif_default->hostname);
|
||||
#else
|
||||
netbiosns_set_name("NETBIOSLWIPDEV");
|
||||
#endif
|
||||
#endif
|
||||
#endif /* LWIP_NETBIOS_APP && LWIP_UDP */
|
||||
|
||||
#if LWIP_HTTPD_APP && LWIP_TCP
|
||||
#ifdef LWIP_HTTPD_APP_NETCONN
|
||||
http_server_netconn_init();
|
||||
#else /* LWIP_HTTPD_APP_NETCONN */
|
||||
#if defined(LWIP_HTTPD_EXAMPLE_CUSTOMFILES) && LWIP_HTTPD_EXAMPLE_CUSTOMFILES && defined(LWIP_HTTPD_EXAMPLE_CUSTOMFILES_ROOTDIR)
|
||||
fs_ex_init(LWIP_HTTPD_EXAMPLE_CUSTOMFILES_ROOTDIR);
|
||||
#endif
|
||||
httpd_init();
|
||||
#if defined(LWIP_HTTPD_EXAMPLE_SSI_SIMPLE) && LWIP_HTTPD_EXAMPLE_SSI_SIMPLE
|
||||
ssi_ex_init();
|
||||
#endif
|
||||
#if defined(LWIP_HTTPD_EXAMPLE_CGI_SIMPLE) && LWIP_HTTPD_EXAMPLE_CGI_SIMPLE
|
||||
cgi_ex_init();
|
||||
#endif
|
||||
#endif /* LWIP_HTTPD_APP_NETCONN */
|
||||
#endif /* LWIP_HTTPD_APP && LWIP_TCP */
|
||||
|
||||
#if LWIP_NETIO_APP && LWIP_TCP
|
||||
netio_init();
|
||||
#endif /* LWIP_NETIO_APP && LWIP_TCP */
|
||||
|
||||
#if LWIP_RTP_APP && LWIP_SOCKET && LWIP_IGMP
|
||||
rtp_init();
|
||||
#endif /* LWIP_RTP_APP && LWIP_SOCKET && LWIP_IGMP */
|
||||
|
||||
#if LWIP_SHELL_APP && LWIP_NETCONN
|
||||
shell_init();
|
||||
#endif /* LWIP_SHELL_APP && LWIP_NETCONN */
|
||||
#if LWIP_TCPECHO_APP
|
||||
#if LWIP_NETCONN && defined(LWIP_TCPECHO_APP_NETCONN)
|
||||
tcpecho_init();
|
||||
#else /* LWIP_NETCONN && defined(LWIP_TCPECHO_APP_NETCONN) */
|
||||
tcpecho_raw_init();
|
||||
#endif
|
||||
#endif /* LWIP_TCPECHO_APP && LWIP_NETCONN */
|
||||
#if LWIP_UDPECHO_APP && LWIP_NETCONN
|
||||
udpecho_init();
|
||||
#endif /* LWIP_UDPECHO_APP && LWIP_NETCONN */
|
||||
#if LWIP_SOCKET_EXAMPLES_APP && LWIP_SOCKET
|
||||
socket_examples_init();
|
||||
#endif /* LWIP_SOCKET_EXAMPLES_APP && LWIP_SOCKET */
|
||||
#if LWIP_MDNS_APP
|
||||
mdns_example_init();
|
||||
#endif
|
||||
#if LWIP_SNMP_APP
|
||||
snmp_example_init();
|
||||
#endif
|
||||
#if LWIP_SNTP_APP
|
||||
sntp_example_init();
|
||||
#endif
|
||||
#if LWIP_TFTP_APP
|
||||
tftp_example_init();
|
||||
#endif
|
||||
#if LWIP_LWIPERF_APP
|
||||
lwiperf_example_init();
|
||||
#endif
|
||||
#if LWIP_MQTT_APP
|
||||
mqtt_example_init();
|
||||
#endif
|
||||
|
||||
#ifdef LWIP_APP_INIT
|
||||
LWIP_APP_INIT();
|
||||
#endif
|
||||
}
|
||||
|
||||
/* This function initializes this lwIP test. When NO_SYS=1, this is done in
|
||||
* the main_loop context (there is no other one), when NO_SYS=0, this is done
|
||||
@@ -584,9 +492,6 @@ test_init(void * arg)
|
||||
/* init network interfaces */
|
||||
test_netif_init();
|
||||
|
||||
/* init apps */
|
||||
apps_init();
|
||||
|
||||
#if !NO_SYS
|
||||
sys_sem_signal(init_sem);
|
||||
#endif /* !NO_SYS */
|
||||
|
||||
Reference in New Issue
Block a user