📄 node143.html
字号:
<html><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"><!--Converted with jLaTeX2HTML 2002 (1.62) JA patch-1.4patched version by: Kenshi Muto, Debian Project.LaTeX2HTML 2002 (1.62),original version by: Nikos Drakos, CBLU, University of Leeds* revised and updated by: Marcus Hennecke, Ross Moore, Herb Swan* with significant contributions from: Jens Lippmann, Marek Rouchal, Martin Wilck and others --><HTML><HEAD><TITLE>14.1 Tcl configuration</TITLE><META NAME="description" CONTENT="14.1 Tcl configuration"><META NAME="keywords" CONTENT="everything"><META NAME="resource-type" CONTENT="document"><META NAME="distribution" CONTENT="global"><META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1"><META NAME="Generator" CONTENT="jLaTeX2HTML v2002 JA patch-1.4"><META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css"><LINK REL="STYLESHEET" HREF="everything.css" tppabs="http://www.isi.edu/nsnam/ns/doc/everything.css"><LINK REL="next" HREF="node144.html" tppabs="http://www.isi.edu/nsnam/ns/doc/node144.html"><LINK REL="previous" HREF="node142.html" tppabs="http://www.isi.edu/nsnam/ns/doc/node142.html"><LINK REL="up" HREF="node142.html" tppabs="http://www.isi.edu/nsnam/ns/doc/node142.html"><LINK REL="next" HREF="node144.html" tppabs="http://www.isi.edu/nsnam/ns/doc/node144.html"></HEAD><BODY ><!--Navigation Panel--><A NAME="tex2html3491" HREF="node144.html" tppabs="http://www.isi.edu/nsnam/ns/doc/node144.html"><IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next" SRC="file:/usr/share/latex2html/icons/next.png"></A> <A NAME="tex2html3485" HREF="node142.html" tppabs="http://www.isi.edu/nsnam/ns/doc/node142.html"><IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up" SRC="file:/usr/share/latex2html/icons/up.png"></A> <A NAME="tex2html3479" HREF="node142.html" tppabs="http://www.isi.edu/nsnam/ns/doc/node142.html"><IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous" SRC="file:/usr/share/latex2html/icons/prev.png"></A> <A NAME="tex2html3487" HREF="node1.html" tppabs="http://www.isi.edu/nsnam/ns/doc/node1.html"><IMG WIDTH="65" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="contents" SRC="file:/usr/share/latex2html/icons/contents.png"></A> <A NAME="tex2html3489" HREF="node590.html" tppabs="http://www.isi.edu/nsnam/ns/doc/node590.html"><IMG WIDTH="43" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="index" SRC="file:/usr/share/latex2html/icons/index.png"></A> <BR><B> Next:</B> <A NAME="tex2html3492" HREF="node144.html" tppabs="http://www.isi.edu/nsnam/ns/doc/node144.html">14.2 Components of a</A><B> Up:</B> <A NAME="tex2html3486" HREF="node142.html" tppabs="http://www.isi.edu/nsnam/ns/doc/node142.html">14. Local Area Networks</A><B> Previous:</B> <A NAME="tex2html3480" HREF="node142.html" tppabs="http://www.isi.edu/nsnam/ns/doc/node142.html">14. Local Area Networks</A>   <B> <A NAME="tex2html3488" HREF="node1.html" tppabs="http://www.isi.edu/nsnam/ns/doc/node1.html">Contents</A></B>   <B> <A NAME="tex2html3490" HREF="node590.html" tppabs="http://www.isi.edu/nsnam/ns/doc/node590.html">Index</A></B> <BR><BR><!--End of Navigation Panel--><H1><A NAME="SECTION031110000000000000000"></A><A NAME="sec:lan_tcl"></A><BR>14.1 Tcl configuration</H1><P>The interface for creating and configuring a LAN slightly differs fromthose of point-to-point link. At the top level, the OTcl class<TT>Simulator</TT> exports a new method called <TT>make-lan</TT>. Theparameters to this method are similar to the method <TT>duplex-link</TT>,except that <TT>make-lan</TT> only accepts a list of nodes as a singleparameter instead of 2 parameters as in <TT>duplex-link</TT>:<P><PRE>Simulator instproc make-lan {nodes bw delay lltype ifqtype mactype chantype}</PRE><P>The optional parameters to <TT>make-lan</TT> specify the type of objectsto be created for the link layer (<TT>LL</TT>), the interface queue, theMAC layer (<TT>Mac</TT>), and the physical layer (<TT>Channel</TT>). Belowis an example of how a new CSMA/CD (Ethernet) LAN is created.<P>Example:<PRE> $ns make-lan "$n1 $n2" $bw $delay LL Queue/DropTail Mac/Csma/Cd</PRE>creates a LAN with basic link-layer, drop-tail queue, and CSMA/CD MAC.<P><BR><HR><ADDRESS>2003-09-23</ADDRESS></BODY></HTML>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -