⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 main.c

📁 Analog公司的ADSP_BF532上面实现以太网接口的源码
💻 C
字号:
//##############################################################
//#
//# MAIN.C
//#
//# ADSP-21535 Embedded Web Server Project
//#
//# (c) ANALOG DEVICES 2002
//#     eDSP Division
//#     Stefan Hacker
//#     23-DEC-2002
//#
//# History
//#     16-APR-2003 HS  release 1.0
//#

#include "defBF533.h"
#include "io_sprt.h"
#include "stdio.h"

#include "ez_lan_types.h"
#include "CF_IDE.h"
#include "lan91c111.h"
#include "tcp_ip.h"
#include "http_svr.h"
#include "globals.h"
#include "startup.h"

#define MC section("L1_code")

MC void main()
{
    int i;
        
    // initialize system    
    init_system();   
    init_IRQs();

    // init the ATA drive
    //ATA_init();

    // initialize TCP stack
    TCP_init();

    // init the SMSC LAN91C111
    smc_init_91c111();
    
    // start the server
    TCP_LocalPort = TCP_PORT_HTTP;
    HTTP_Status &= ~HTTP_SEND_PAGE;

    
    while(1)
    {
        if (!(TCP_SocketStatus & TCP_SOCK_ACTIVE)) 
        	TCP_PassiveOpen();
                            
        TCP_State_Machine();
        //HTTPServer();

        if (TCP_SocketStatus == CLOSED) 
            HTTP_Status = 0;
    }
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -