📄 if_esmc.html
字号:
<html><head><!-- /vobs/wpwr/docs/vxworks/ref/if_esmc.html - generated by refgen from if_esmc.c --> <title> if_esmc </title></head><body bgcolor="#FFFFFF"> <hr><a name="top"></a><p align=right><a href="libIndex.html"><i>VxWorks Reference Manual : Libraries</i></a></p></blockquote><h1>if_esmc</h1> <blockquote></a></blockquote><h4>NAME</h4><blockquote> <p><strong>if_esmc</strong> - Ampro Ethernet2 SMC-91c9x Ethernet network interface driver </p></blockquote><h4>ROUTINES</h4><blockquote><p><p><b><i><a href="./if_esmc.html#esmcattach">esmcattach</a></i>( )</b> - publish the <b>esmc</b> network interface and initialize the driver.<br><b><i><a href="./if_esmc.html#esmcPut">esmcPut</a></i>( )</b> - copy a packet to the interface.<br><b><i><a href="./if_esmc.html#esmcShow">esmcShow</a></i>( )</b> - display statistics for the <b>esmc</b> network interface<br><p></blockquote><h4>DESCRIPTION</h4><blockquote><p>This module implements the Ampro Ethernet2 SMC-91c9x Ethernet networkinterface driver.<p></blockquote><h4>CONFIGURATION</h4><blockquote><p>The W3 and W4 jumper should be set for IO address and IRQ.The defined I/O address and IRQ in <b>config.h</b> must match the one storedin EEROM and the jumper setting. <p></blockquote><h4>BOARD LAYOUT</h4><blockquote><p>The diagram below shows the relevant jumpers for VxWorks configuration.<p><font size=-1><pre> ___________________________________ | * * * * | | ______ | | | | | | | U1 | W1 W3 | | |PROM| X " | | | | . - | | | | - | | | | - | | |____| | | | | W4 | | " | | " | | - | | - | |_________________________________| W1: Boot PROM Size W3: IO-address, IRQ, Media W4: IRQ Group Selection</pre></font></blockquote><h4>EXTERNAL INTERFACE</h4><blockquote><p>The only user-callable routines are <b><i><a href="./if_esmc.html#esmcattach">esmcattach</a></i>( )</b>:<dl><dt><b><i><a href="./if_esmc.html#esmcattach">esmcattach</a></i>( )</b><dd>publishes the <b>esmc</b> interface and initializes the driver and device. </dl><p>The last parameter of <b><i><a href="./if_esmc.html#esmcattach">esmcattach</a></i>( )</b>, <i>mode</i>, is a receive mode.If it is 0, a packet is received in the interrupt level. If it is 1,a packet is received in the task level. Receiving packets in the interruptlevel requires about 10K bytes of memory, but minimize a risk of dropping packets. Receiving packets in the task level doesn't require extramemory, but might have a risk of dropping packets.<p></blockquote><h4>SEE ALSO</h4><blockquote><p><b><a href="./if_esmc.html#top">if_esmc</a></b><hr><a name="esmcattach"></a><p align=right><a href="rtnIndex.html"><i>Libraries : Routines</i></a></p></blockquote><h1><i>esmcattach</i>( )</h1> <blockquote></a></blockquote><h4>NAME</h4><blockquote> <p><strong><i>esmcattach</i>( )</strong> - publish the <b>esmc</b> network interface and initialize the driver.</p></blockquote><h4>SYNOPSIS</h4><blockquote><p><pre>STATUS esmcattach ( int unit, /* unit number */ int ioAddr, /* address of esmc's shared memory */ int intVec, /* interrupt vector to connect to */ int intLevel, /* interrupt level */ int config, /* 0: Autodetect 1: AUI 2: BNC 3: RJ45 */ int mode /* 0: rx in interrupt 1: rx in task(netTask) */ )</pre></blockquote><h4>DESCRIPTION</h4><blockquote><p>This routine attaches an <b>esmc</b> Ethernet interface to the network if thedevice exists. It makes the interface available by filling in the networkinterface record. The system will initialize the interface when it is readyto accept packets.<p></blockquote><h4>RETURNS</h4><blockquote><p>OK or ERROR.<p></blockquote><h4>SEE ALSO</h4><blockquote><p><b><a href="./if_esmc.html#top">if_esmc</a></b>, <b><a href="./ifLib.html#top">ifLib</a></b>, <b><a href="./netShow.html#top">netShow</a></b><hr><a name="esmcPut"></a><p align=right><a href="rtnIndex.html"><i>Libraries : Routines</i></a></p></blockquote><h1><i>esmcPut</i>( )</h1> <blockquote></a></blockquote><h4>NAME</h4><blockquote> <p><strong><i>esmcPut</i>( )</strong> - copy a packet to the interface.</p></blockquote><h4>SYNOPSIS</h4><blockquote><p><pre>#ifdef BSD43_DRIVER LOCAL void esmcPut ( int unit )</pre></blockquote><h4>DESCRIPTION</h4><blockquote><p>Copy from mbuf chain to transmitter buffer in shared memory.<p></blockquote><h4>RETURNS</h4><blockquote><p>N/A</blockquote><h4>SEE ALSO</h4><blockquote><p><b><a href="./if_esmc.html#top">if_esmc</a></b><hr><a name="esmcShow"></a><p align=right><a href="rtnIndex.html"><i>Libraries : Routines</i></a></p></blockquote><h1><i>esmcShow</i>( )</h1> <blockquote></a></blockquote><h4>NAME</h4><blockquote> <p><strong><i>esmcShow</i>( )</strong> - display statistics for the <b>esmc</b> network interface</p></blockquote><h4>SYNOPSIS</h4><blockquote><p><pre>void esmcShow ( int unit, /* interface unit */ BOOL zap /* zero totals */ )</pre></blockquote><h4>DESCRIPTION</h4><blockquote><p>This routine displays statistics about the <b>esmc</b> Ethernet network interface.It has two parameters:<dl><dt><i>unit</i><dd>interface unit; should be 0.<p><dt><i>zap</i><dd> if 1, all collected statistics are cleared to zero. </dl><p></blockquote><h4>RETURNS</h4><blockquote><p>N/A</blockquote><h4>SEE ALSO</h4><blockquote><p><b><a href="./if_esmc.html#top">if_esmc</a></b></body></html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -