Links are created between nodes to form a network topology. nam links are internally simplex, but it is invisible to the users. The trace event ''l'' creates two simplex links and other necessary setups, hence it looks to users identical to a duplex link. Link may have many colors and it can change its color during animation. Queues are constructed in nam between two nodes. Unlike link, nam queue is associated to a simplex link. The trace event ``q'' only creates a queue for a simplex link. In nam, queues are visualized as stacked packets. Packets are stacked along a line, and the angle between the line and the horizontal line can be specified in the trace event ``q''. Commands to setup different animation attributes of a link are as follows:
$ns duplex-link-op attribute value
The <attribute> may be one of the following: orient, color, queuePos, label. Orient or the link orientation defines the angle between the link and horizontal. The optional orientation values may be difined in degrees or by text like right (0), right-up (45), right-down (-45), left (180), left-up (135), left-down (-135), up (90), down (-90). The queuePos or position of queue is defined as the angle of the queue line with horizontal. Examples for each attribute are given as following :
$ns duplex-link-op orient right ;# orientation is set as right. The order ;# in which links are created in nam ;# depends on calling order of this function. $ns duplex-link-op color "green" $ns duplex-link-op queuePos 0.5 $ns duplex-link-op label "A"
Tom Henderson 2011-11-05