資源簡(jiǎn)介
ENC28j60模塊網(wǎng)絡(luò)通信 實(shí)現(xiàn)了局域網(wǎng)間的通信,通過(guò)瀏覽器可直接與板子通信實(shí)現(xiàn)了遠(yuǎn)程控制。

代碼片段和文件信息
/**
?*?@file
?*?Sequential?API?External?module
?*
?*/
?
/*
?*?Copyright?(c)?2001-2004?Swedish?Institute?of?Computer?Science.
?*?All?rights?reserved.?
?*?
?*?Redistribution?and?use?in?source?and?binary?forms?with?or?without?modification?
?*?are?permitted?provided?that?the?following?conditions?are?met:
?*
?*?1.?Redistributions?of?source?code?must?retain?the?above?copyright?notice
?*????this?list?of?conditions?and?the?following?disclaimer.
?*?2.?Redistributions?in?binary?form?must?reproduce?the?above?copyright?notice
?*????this?list?of?conditions?and?the?following?disclaimer?in?the?documentation
?*????and/or?other?materials?provided?with?the?distribution.
?*?3.?The?name?of?the?author?may?not?be?used?to?endorse?or?promote?products
?*????derived?from?this?software?without?specific?prior?written?permission.?
?*
?*?THIS?SOFTWARE?IS?PROVIDED?BY?THE?AUTHOR?‘‘AS?IS‘‘?AND?ANY?EXPRESS?OR?IMPLIED?
?*?WARRANTIES?INCLUDING?BUT?NOT?LIMITED?TO?THE?IMPLIED?WARRANTIES?OF?
?*?MERCHANTABILITY?AND?FITNESS?FOR?A?PARTICULAR?PURPOSE?ARE?DISCLAIMED.?IN?NO?EVENT?
?*?SHALL?THE?AUTHOR?BE?LIABLE?FOR?ANY?DIRECT?INDIRECT?INCIDENTAL?SPECIAL?
?*?EXEMPLARY?OR?CONSEQUENTIAL?DAMAGES?(INCLUDING?BUT?NOT?LIMITED?TO?PROCUREMENT?
?*?OF?SUBSTITUTE?GOODS?OR?SERVICES;?LOSS?OF?USE?DATA?OR?PROFITS;?OR?BUSINESS?
?*?INTERRUPTION)?HOWEVER?CAUSED?AND?ON?ANY?THEORY?OF?LIABILITY?WHETHER?IN?
?*?CONTRACT?STRICT?LIABILITY?OR?TORT?(INCLUDING?NEGLIGENCE?OR?OTHERWISE)?ARISING?
?*?IN?ANY?WAY?OUT?OF?THE?USE?OF?THIS?SOFTWARE?EVEN?IF?ADVISED?OF?THE?POSSIBILITY?
?*?OF?SUCH?DAMAGE.
?*
?*?This?file?is?part?of?the?lwIP?TCP/IP?stack.
?*?
?*?Author:?Adam?Dunkels?
?*
?*/
/*?This?is?the?part?of?the?API?that?is?linked?with
???the?application?*/
#include?“l(fā)wip/opt.h“
#if?LWIP_NETCONN?/*?don‘t?build?if?not?configured?for?use?in?lwipopts.h?*/
#include?“l(fā)wip/api.h“
#include?“l(fā)wip/tcpip.h“
#include?“l(fā)wip/memp.h“
#include?“l(fā)wip/ip.h“
#include?“l(fā)wip/raw.h“
#include?“l(fā)wip/udp.h“
#include?“l(fā)wip/tcp.h“
#include?
/**
?*?Create?a?new?netconn?(of?a?specific?type)?that?has?a?callback?function.
?*?The?corresponding?pcb?is?also?created.
?*
?*?@param?t?the?type?of?‘connection‘?to?create?(@see?enum?netconn_type)
?*?@param?proto?the?IP?protocol?for?RAW?IP?pcbs
?*?@param?callback?a?function?to?call?on?status?changes?(RX?available?TX‘ed)
?*?@return?a?newly?allocated?struct?netconn?or
?*?????????NULL?on?memory?error
?*/
struct?netconn*
netconn_new_with_proto_and_callback(enum?netconn_type?t?u8_t?proto?netconn_callback?callback)
{
??struct?netconn?*conn;
??struct?api_msg?msg;
??conn?=?netconn_alloc(t?callback);
??if?(conn?!=?NULL?)?{
????msg.function?=?do_newconn;
????msg.msg.msg.n.proto?=?proto;
????msg.msg.conn?=?conn;
????TCPIP_APIMSG(&msg);
????if?(conn->err?!=?ERR_OK)?{
??????LWIP_ASSERT(“freeing?conn?without?freeing?pcb“?conn->pcb.tcp?==?NULL);
??????LWIP_ASSERT(“conn?has?no?op_completed“?conn->op_completed?!=?SYS_SEM_NULL);
??????LWIP_ASSERT(“conn?has?no?recvmbox“?conn->rec
?屬性????????????大小?????日期????時(shí)間???名稱
-----------?---------??----------?-----??----
?????文件????1845839??2012-07-20?23:33??enc28j60+lwip\datasheet\ENC28J60?Stand-Alone?Ethernet?Controller?with?SPI?Interface?(Chinese).pdf
?????文件????1669587??2009-07-02?07:30??enc28j60+lwip\datasheet\ENC28J60.pdf
?????文件?????313073??2011-07-13?05:02??enc28j60+lwip\datasheet\HR911105.pdf
?????文件????1640252??2012-07-31?19:32??enc28j60+lwip\LWIP協(xié)議棧原文件\contrib-1.3.0_.zip
????.......????101766??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\CHANGELOG
????.......??????1611??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\COPYING
????.......??????3372??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\doc\contrib.txt
????.......???????407??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\doc\FILES
????.......?????19025??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\doc\rawapi.txt
????.......??????4701??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\doc\savannah.txt
????.......??????6360??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\doc\snmp_agent.txt
????.......??????9624??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\doc\sys_arch.txt
????.......???????142??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\FILES
????.......??????3312??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\README
????.......?????16435??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\src\api\api_lib.c
????.......?????34330??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\src\api\api_msg.c
????.......??????2914??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\src\api\err.c
????.......??????6724??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\src\api\netbuf.c
????.......?????11038??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\src\api\netdb.c
????.......??????4973??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\src\api\netifapi.c
????.......?????56895??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\src\api\sockets.c
????.......?????15705??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\src\api\tcpip.c
????.......?????62408??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\src\core\dhcp.c
????.......?????30506??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\src\core\dns.c
????.......?????11328??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\src\core\init.c
????.......?????16301??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\src\core\ipv4\autoip.c
????.......?????11079??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\src\core\ipv4\icmp.c
????.......?????25450??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\src\core\ipv4\igmp.c
????.......??????7187??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\src\core\ipv4\inet.c
????.......?????12850??2009-12-24?23:38??enc28j60+lwip\LWIP協(xié)議棧原文件\lwip-1.3.2\src\core\ipv4\inet_chksum.c
............此處省略658個(gè)文件信息
評(píng)論
共有 條評(píng)論