[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Questions on LAN trace output.



Whatever trace objects you need, you'll have to add them yourself.
Here is an example of adding a hop and a receive traces:

LanIface instproc trace {ns f {op ""}} {
        $self instvar hopT_ rcvT_ iface_
        $self instvar entry_ node_ lan_
        set hopT_ [$ns create-trace Hop $f $node_ $lan_ $op]
        set rcvT_ [$ns create-trace Recv $f $lan_ $node_ $op]
        $hopT_ target $entry_
        set entry_ $hopT_
        $rcvT_ target [$iface_ target]
        $iface_ target $rcvT_
}

'h' trace is "Hop".  You can replace it with Send because it records
the time the packet's given to LanIface for sending.  Hop trace is
needed, however, for nam animations, so it would probably be better to
leave it and add a send trace just before hopT.

BTW, just a couple of lines of your trace would be enough, there is
no need to send the whole huge thing.

Cheers,


  -Yuri