Document information
- University
- Politecnico di Milano
- Degree programme
- Computer Engineering
- Subject
- Reti di Comunicazione e Internet
- Academic year
- 2008-2009
- Classification
- Other study material
- Original format
- Text
- Searchable text
Study material for Reti di Comunicazione e Internet, shared by the Studwiz community and reviewed by moderators.
Study material for Reti di Comunicazione e Internet, shared by the Studwiz community and reviewed by moderators.
Import quality: text was extracted directly from the original document.
Representative passages recognised in different parts of the material. The full extracted text remains available to search, while this compact preview makes the page easier to read.
Pag. 1/4 Fondamenti di Reti di Telecomunicazioni Prova di Laboratorio – 23 Luglio 2009 Cognome e nome: (stampatello) Matricola: (firma leggibile) Dato il seguente programma (script) NS in linguaggio TCL (svolgere su questo foglio): NOME FILE: 23luglio.tcl set ns [new Simulator] set namFile [open 23luglio.nam w] $ns namtrace-all $namFile $ns at 10.0 "finish" proc finish {} { global ns global namFile $ns flush-trace close $namFile #exec nam 23luglio.nam & exit 0 } set Node0 [$ns node] set Node1 [$ns node] set Node2 [$ns node] set Node3 [$ns node] set Node4 [$ns node] set Node5 [$ns node] $ns duplex-link $Node2 $Node0 5Mb 160ms DropTail $ns duplex-link $Node0 $Node1 1.5Mb 20ms DropTail $ns queue-limit $Node0 $Node1 50 $ns duplex-link $Node3 $Node0 5Mb 160ms DropTail $ns duplex-link $Node1 $Node4 5Mb 20ms DropTail $ns duplex-link $Node1 $Node5 5Mb 20ms DropTail set UDP0 [new Agent/UDP] $UDP0 set packetSize_ 500 set UDP1 [new Agent/UDP] $UDP1 set packetSize_ 500 set Null0 [new Agent/Null] set Null1 [new Agent/Null] $ns attach-agent $Node4 $Null0 $ns attach-agent $Node5 $Null1 $ns attach-agent $Node2 $UDP0 $ns attach-agent $Node3 $UDP1 $ns connect $UDP0 $Null0 $ns connect $UDP1 $Null1 set CBR0 [new Application/Traffic/CBR] $CBR0 set packetSize_ 500 $CBR0 set interval_ 16ms set CBR1 [new Application/Traffic/CBR] $CBR1 set packetSize_ 500 $CBR1 set interval_ 4ms $CBR0 attach-agent $UDP0 $CBR1 attach-agent $UDP1 $ns at 0.0s "$CBR0 start" $ns at 9.5s "$CBR0 stop" $ns at 0.0s "$CBR1 start" $ns at 9.5s "$CBR1 stop" $ns run Nota: i pacchetti da UDP0 a Null0 seguono il percorso Node2 – Node0 – Node1 – Node4 mentre i pacchetti da UDP1 a Null1 seguono il percorso Node3 – Node0 – Node1 – Node5 Pag. 2/4 1) Disegnare la topologia della rete descritta nello script TCL c on la…
First page of the document.