packetGroup

packetGroup - configure the Packet Group parameters.

SYNOPSIS

packetGroup sub-command options

DESCRIPTION

The packetGroup command is used to configure the parameters for Packet Groups. Packet groups are given unique IDs within which metrics such as minimum, maximum and average latency for every incoming frame is calculated by the hardware in real-time.

An additional feature available on some port types is the ability to collect latency measurements per packet group. The availability of this feature for a given port can be tested using the port isValidFeature... portFeatureRxLatencyBin. The port must be configured for wide packet groups (the port's receiveMode includes the portRxModeWidePacketGroup bit); the availability of this mode may be tested with port isValidFeature... portFeatureRxWidePacketGroups. No configuration is necessary on the transmit port; only the receive port must be configured to receive latency bin operation. This feature is enabled on the receive port with the enableLatencyBins option.

The latency measurements for each packet group may be collected in a set up to 16 continuous latency buckets. The first bucket always starts at 0 and the last bucket always ends at the maximum latency. The packetGroup interface allows for the specification of up to 15 time dividers between latency bins. For example, to specify five latency buckets for:

one programs four dividing times:

This is done through the latencyBins option. No other setup is required for the receive side port. The latency statistics per latency bin are obtained through the use of the packetGroupStats command.

An additional feature available on some port types is the ability to measure latency as it varies over time. The availability of this feature for a given port can be tested using the port isValidFeature... portFeatureRxTimeBin. The port must be configured for wide packet groups (the port's receiveMode includes the portRxModeWidePacketGroup bit); the availability of this mode may be tested with port isValidFeature... portFeatureRxWidePacketGroups. No configuration is necessary on the transmit port; only the receive port must be configured to receive time bin operation. This feature is enabled on the receive port with the enableTimeBins option.

The latency over time for each packet group may be collected for a number of evenly spaced time periods, as indicated by the numTimeBins and timeBinDuration options. The number of packet groups used per time bin must also be specified in the numPgidPerTimeBin option.

The product of numPgidPerTimeBin (which must be a power of 2) and the next higher power of 2 of the numTimeBins must be less than the total number of packet group IDs available for the port when not in time bin mode.

The latency statistics per time bin are obtained through the use of the packetGroupStats command.

Time bins and latency bins may be used at the same time.

Note that when using ATM ports, different types of ATM encapsulation result in different length headers, as discussed in atmHeader. The data portion of the packet normally follows the header, except in the case of the two LLC Bridged Ethernet choices, where 12 octets of MAC address and 2 octets of Ethernet type follow the header. The offsets used in this command is with respect to the beginning of the AAL5 packet and must be adjusted by hand to account for the header.

STANDARD OPTIONS
allocateUdf true | false

Assigns one of the User-Defined Fields for use with the Sequence Number. (default = true)

delayVariationMode

Selects Delay Variation measurement mode (under Latency/Jitter Measurement). This only is available when measurementMode is set to packetGroupModeDelayVariation.

Note: When Delay Variation mode is selected, then under Sequence Checking the only available option is Threshold Sequence Checking.

Delay Variation options include:

Option

Value

Usage

delayVariationWith

SequenceErrors

0

(default) delay variation with sequence errors

delayVariationWith

LatencyMinMax

1

delay variation with latency min/max

delayVariationWith

LatencyAvg

2

delay variation with latency average

enable128kBinMode

true | false

If true, then the length of the packet group ID field is increased to 17 bits. (default = false)

enableGroupIdMask

true | false

Enables the use of the groupId mask. (default = false)

enableInsertPgid

true | false

Enables inserting the PGID into the packet. (default = false)

enableLastBitTime

Stamp true/false

If true, enables selection of last bit time stamp. If false, the first bit time stamp is used. (default = false)

enableLatencyBins

true | false

Enables the use of latency bins on receive. (default = false)

enableReArmFirstTimeStamp

Enables the use of RE Arm first time stamp.

enableRxFilter

true | false

Enables the use of the headerFilterMask mask. (default = false)

enableSignatureMask

true | false

Enables the use of the signatureMask mask. (default = false)

enableTimeBins

true | false

Enables the use of time bins on receive. (default = false)

groupId

Unique value used to identify one packet group for another. Up to 57344 different packet groups may be defined. (default = 0)

groupIdMask

A two-byte mask applied to the group ID. Bits which are `1' in the mask are set to `0' in the received group ID. (default = 0)

groupIdMode

This option provides a convenience mechanism for setting the groupIdOffset and groupIdMask.

Option

Value

Usage

packetGroupCustom

0

(default) The offset and mask are set in groupIdOffset and groupIdMask.

packetGroupDscp

1

The offset and mask are set to the DSCP location; that is, groupIdOffset=14 and groupIdMask=FF03.

packetGroupIpV6TrafficClass

2

The offset and mask are set to the destination IPv6 address' traffic class; that is, groupIdOffset=14 and groupIdMask=FD3F.

packetGroupMplsExp

3

The offset and mask are set to the MPLS label's Experimental field; that is, groupIdOffset=16 and groupIdMask=F1FF.

packetGroupSplit

4

The offset and mask are set in to split PGIDs.

groupIdOffset

The offset, within the packet, of the group id value. (default = 52)

headerFilter

A set of 16 bytes used to match the header of packets to be considered for signature masking. (default = {00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00})

headerFilterMask

A mask to be applied to the headerFilter. Bits which are `1' are ignored in the match. (default = {00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00})

ignoreSignature

true / false

In receive mode, the signature field is not matched and all packets are counted. (default = false)

insertSequence

Signature true / false

Inserts a sequence signature into the packet as indicated by signatureOffset, signatureValue, groupIdOffset, signatureNumberOffset and allocateUdf. (default = false)

insertSignature true|false

Inserts the packet group signature into the transmitted stream. (default = false) Note: For calculating latency values need to configure stream config -fir true.

latencyBinList

If enableLatencyBins is true, this TCL array of floating point numbers, each of which is expressed in milliseconds, indicates the dividing line between latency bins. As per the discussion at the head of this command, there is one fewer dividing times than latency bins. The first bin always starts at 0 and the last bin always ends at the maximum possible latency. The list is sorted before use. There must not be any duplicate values. (default = "")

latencyControl

Defines the mechanism used to calculate latency. Possible values include:

Option

Value

Usage

cutThrough

0x01

(default) first data bit in to first data bit out

storeAndForward

0x03

last data bit in to first data bit out

storeAndForwardPreamble

0x05

last data bit in to first preamble out

interArrivalJitter

0x07

inter-arrival jitter

This selection automatically activates measurementMode inter-arrival time mode.

firstInLastOut

0x08

first in last out

lastInLastOut

0x09

last in last out

maxRxGroupId

Read only. Displays the maximum number of PGIDs available for the port based on the receive side configuration.

measurementMode

Defines the measurement mode used to calculate latency. Possible values include:

Option

Value

Usage

packetGroupModeLatency

0

(default) latency mode

packetGroupModeInter

ArrivalTime

1

inter-arrival time mode

Note: Requires latencyControl to be set to interArrivalJitter.

On the other hand, simply setting latencyControl to interArrivalJitter automatically selects this value for measurementMode.

packetGroupModeDelay

Variation

2

delay variation mode

Selecting this mode automatically enables delayVariationMode option.

multiSwitchedPath

Mode

Two alternatives exist for the manner in which time stamps are used when sequenceCheckingMode is set to seqMultiSwitchedPath:

Option

Value

Usage

seqSwitchedPathPGID

0

(default) Time stamps are used to hold the time stamp of the first packet received for each packet group ID.

seqSwitchedPathDuplication

1

Time stamps are used to hold the first detected packet duplication.

Note: Not available when in Delay Variation mode.

numPgidPerTimeBin

If enableTimeBins is true, this is used as the number of packet group IDs to be received for each time bin defined by timeBinDuration. Note that this value must be a power of 2; for example, 1, 2, 4, 8, 16, .. Note that the product of this number and the next higher power of 2 of the numTimeBins option must not exceed the total number of packet group IDs available for the port if enableTimeBins were false. (default = 32)

numTimeBins

If enableTimeBins is true, this is used as the number of distinct time bins to collect latency over, per packet group ID. The range of legal values is from 1 to 2048. The length of all time bins is dictated by timeBinDuration. Note that the product of the next higher power of 2 of this number and numPgidPerTimeBin option must not exceed the total number of packet group IDs available for the port if enableTimeBins were false. (default = 10)

preambleSize

Length of preamble, in bytes, of received frame. (default = 8)

seqAdvTracking

If true, allows to track a frame by following five new statistics:

statistics

In Order

Reorder

Duplicate

Late

Lost

seqAdvTrackingLate

Threshold

A fixed value that sets a threshold to track the expected sequence value. The Late Threshold value is subtracted from the expected sequence number when the received sequence numbers are less than the late threshold value.

sequenceError

Threshold

The threshold value used to determine whether a sequence error has occurred. (default = 2)

sequenceChecking

Mode

The manner in which sequence checking is performed.

Option

Value

Usage

seqThreshold

0

(default) Sequence errors are determined by checking sequence numbers against sequenceErrorThreshold.

seqMultiSwitchedPath

1

Sequence checking is performed looking for skipped and duplicate sequence numbers. Check the portFeatureMultiSwitchPacketDetection feature for availability of this choice.

seqAdvTracking

2

Advanced sequence tracking is enabled.

sequenceNumberOffset

The offset within the packet of the sequnce number. This is valid only when sequence checking is enabled. (default = 44)

signature

In the transmitted packet, the signature uniquely signs the transmitted packet as one destined for packet group filtering on the receive port. On the receive port, the signature is used to filter only those packets that have a matching signature and the minimum, maximum and average latencies are obtained for those packets. (default = {08 71 18 05})

signatureMask

A four-byte mask applied to the signature. Bits which are `1' in the mask are ignored. (default = {00 00 00 00})

signatureOffset

The offset, within the packet, of the packet group signature. (default = 48)

timeBinDuration

If enableTimeBins is true, this is the length of each time bin. This value is expressed in nanoseconds. (default = 1000000)

COMMANDS

The packetGroup command is invoked with the following sub-commands. If no sub-command is specified, returns a list of all sub-commands available.

packetGroup cget option

Returns the current value of the configuration option given by option. Option may have any of the values accepted by the packetGroup command.

packetGroup config option value

Modify the Packet Group configuration options of the port. If no option is specified, returns a list describing all of the available Packet Group options (see STANDARD OPTIONS) for port.

packetGroup getCircuitTx chasID cardID portID [circuitID] streamID

Gets the current configuration of the stream with id streamID in the circuit with circuitID on port portID, card cardID, chassis chasID from its hardware.

packetGroup getQueueTx chasID cardID portID [queueID] streamID

Gets the current configuration of the stream with id streamID in the queue with queueID on port portID, card cardID, chassis chasID from its hardware.

packetGroup getRx chasID cardID portID

Gets the current receive Packet Group configuration of the port with id portID on card cardID, chassis chasID. Call this command before calling packetGroup cget option value to get the value of the configuration option. Specific errors are:

packetGroup getTx chasID cardID portID streamID [type]

Gets the current transmit Packet Group configuration of the stream with id portID on card cardID, chassis chasID, stream streamID.

Disable Sequence Checking checkbox per stream that is also visible in IxExplorer GUI inside the Instrumentation Offsets window.

packetGroup config -insertSequenceSignature 0

packetGroup setTx portList

In the first form, the queueID indicates the particular queue for load modules which use multiple queues, such as ATM cards.

In the second form, the type of stream (stream or flow) is selected. One of.

Option

Value

Usage

streamSequenceTypeAll

0

(default) Both streams and flows. This option can be used for ports that do not use flows.

streamSequenceTypeStreams

1

Stream only.

streamSequenceTypeFlows

2

Flow only.

Call this command before calling packetGroup cget option value to get the value of the configuration option. specific errors are:

packetGroup setCircuitTx chasID cardID portID [circuitD] streamID

Sets the configuration of the stream with id streamID on its circuit circuitID on port portID, card cardID, chassis chasID in IxHAL by reading the configuration option values set by the packetGroup config option value command.

packetGroup setDefault

Sets to IxTclHal default values for all configuration options.

packetGroup setQueueTx chasID cardID portID [queueID] streamID

Sets the configuration of the stream with id streamID on its queue queueID on port portID, card cardID, chassis chasID in IxHAL by reading the configuration option values set by the packetGroup config option value command.

packetGroup setRx chasID cardID portID

Sets the receive Packet Group configuration of the port with id portID on card cardID, chassis chasID by reading the configuration option values set by the packetGroup config option value command. Specific errors are:

packetGroup setTx chasID cardID portID streamID [type]

Sets the transmit Packet Group configuration of the stream with id portID on card cardID, chassis chasID, stream streamID by reading the configuration option values set by the packetGroup config option value command.

In the first form, the queueID indicates the particular queue for load modules which use multiple queues, such as ATM cards.

In the second form, the type of stream (stream or flow) is selected. One of.

Option

Value

Usage

streamSequenceTypeAll

0

(default) Both streams and flows. This option can be used for ports that do not use flows.

streamSequenceTypeStreams

1

Stream only.

streamSequenceTypeFlows

2

Flow only.

After calling this command, the Packet Group configuration should be committed to hardware using stream write or ixWriteConfigToHardware commands. Specific errors are:

EXAMPLES

package require IxTclHal

 

# In this example, we'll measure the latency for different frame

# sizes through a simple switch using packet groups.

# Latency bins will also be retreived

# Port 1 is used to transmit three streams, each with a packet

# group signature and packet group ID equal to the stream ID.

# 100,000 packets are transmitted by each stream

# Port 2 is used to received the data using Packet Group Mode.

# A short stream is transmitted from this port to the switch in

# order to get the switch to 'learn' its MAC address

# Separate sections are included for latency bins and time bins

 

# Connect to chassis and get chassis ID

set host techpubs-400

set username user

# Check if we're running on UNIX - connect to the TCL Server

# which must be running on the chassis

if [isUNIX] {

if [ixConnectToTclServer $host] {

ixPuts "Could not connect to $host"

return 1

}

}

 

# Now connect to the chassis

if [ixConnectToChassis $host] {

ixPuts $::ixErrorInfo

return 1

}

# Get the chassis ID to use in port lists

set chas [ixGetChassisID $host]

 

# Assumes that card 1 is a 10/100 card with both ports connected

# to a simple L2 switch

set card 1

set txPort 1

set rxPort 2

 

# Useful port lists

set portList [list [list $chas $card $txPort] \

[list $chas $card $rxPort]]

 

# Login before taking ownership

if [ixLogin $username] {

ixPuts $::ixErrorInfo

return 1

}

# Take ownership of the ports we'll use

if [ixTakeOwnership $portList] {

ixPuts $::ixErrorInfo

return 1

}

 

set p1MAC [list 00 00 00 01 01 01]

set p2MAC [list 00 00 00 01 01 02]

 

set numFrames 4

set numBursts 240

set minSize 64

set maxSize 1024

set stepSize 64

 

set lb [list 0.70 0.72 0.74 0.76]

 

# Need to clear time stamps

if [ixClearTimeStamp portList] {

ixPuts $::ixErrorInfo

}

 

ixPuts "Testing $chas:$card:$txPort -> $chas:$card:$rxPort"

 

# Set up Transmit Port

port setFactoryDefaults $chas $card $txPort

port config -autonegotiate true

 

# stream: from port 1 MAC to port 2 MAC, stream size as per array

# Make sure to insert time stamp (fir)

set streamID 1

 

stream setDefault

stream config -numFrames $numFrames

stream config -numBursts $numBursts

stream config -sa $p1MAC

stream config -da $p2MAC

stream config -fir true

stream config -dma stopStream

stream config -frameSizeType sizeIncr

stream config -frameSizeMIN $minSize

stream config -frameSizeMAX $maxSize

stream config -frameSizeStep $stepSize

stream config -enableIbg false

stream config -enableIsg false

stream config -rateMode usePercentRate

stream config -percentPacketRate 0.04512

 

udf setDefault

udf config -enable true

udf config -counterMode udfCounterMode

udf config -continuousCount false

udf config -initval 0

udf config -repeat 4

udf config -udfSize c16

udf config -offset 52

 

if [udf set 1] {

errorMsg "Error in udf set"

return "FAIL"

}

if [stream set $chas $card $txPort $streamID] {

errorMsg "Error in stream set"

return "FAIL"

}

 

Example of shared values list between UDF 1 and UDF 5:

udf setDefault

udf config -enable true

udf config -offset 12

udf config -counterMode udfValueListMode

udf config -countertype -1

udf config -valueList {{11 11 11 11} {22 22 22 22}}

udf config -udfSize 32

udf config -valueRepeatCount 1

udf config -useSharedUDFValueList 0

udf config -sharedValueListStream 1

udf config -sharedValueListUDF 1

if {[udf set 1]} {

errorMsg "Error calling udf set 1"

set retCode $::TCL_ERROR

}

udf setDefault

udf config -enable true

udf config -offset 22

udf config -counterMode udfValueListMode

udf config -countertype -1

udf config -valueList {}

udf config -udfSize 32

udf config -cascadeType udfCascadeFromSelf

udf config -valueRepeatCount 1

udf config -useSharedUDFValueList 1

udf config -sharedValueListStream 1

udf config -sharedValueListUDF 1

if {[udf set 5]} {

errorMsg "Error calling udf set 5"

set retCode $::TCL_ERROR

}

 

# Make sure to insert a PG signature and streamID = PGID

packetGroup setDefault

packetGroup config -insertSignature true

if [packetGroup setTx $chas $card $txPort $streamID] {

errorMsg "error in packetGroup setTx (1)"

return "FAIL"

}

 

# Set up Receive Port

port setFactoryDefaults $chas $card $rxPort

port config -autonegotiate true

 

# the port must be in packet group mode

port config -receiveMode $::portRxModeWidePacketGroup

 

if [port set $chas $card $rxPort] {

errorMsg "Error in port set"

return "FAIL"

}

 

# Set up receive packet group mode (store and forward)

packetGroup setDefault

packetGroup config -latencyControl storeAndForward

 

#############################################################

#

# Latency Bin sample

#

#############################################################

 

# set the latency bin list

packetGroup config -enableLatencyBins true

packetGroup config -latencyBinList $lb

 

if [packetGroup setRx $chas $card $rxPort] {

errorMsg "Error in packetGroup setRx"

return "FAIL"

}

###############################################################################################

# Configuring 8K stat & 32K stat through TCL for Novus 40G/100G, K400 100G, NOVUS25/10GE8SFP28 [10G/25G]

###############################################################################################

packetGroup setDefault

# For 8K stat

packetGroup config -pgidStatMode 0

OR

# For 32K stat

packetGroup config -pgidStatMode 1

if {[packetGroup setRx $chas $card $rxPort]} {

errorMsg "Error calling packetGroup setRx $chas $card $rxPort "

set retCode $::TCL_ERROR

}

# Let the hardware know about the two ports

ixWriteConfigToHardware portList

 

if [packetGroup getRx $chas $card $rxPort] {

errorMsg "Error in packetGroup getRx"

return "FAIL"

}

#####################################################################

# Configuring 8K stat & 16K stat through TCL for Novus 50G, K400 50G

#####################################################################

packetGroup setDefault

# For 8K stat

packetGroup config -pgidStatMode 0

OR

# For 16K stat

packetGroup config -pgidStatMode 1

if {[packetGroup setRx $chas $card $rxPort]} {

errorMsg "Error calling packetGroup setRx $chas $card $rxPort "

set retCode $::TCL_ERROR

}

# Let the hardware know about the two ports

ixWriteConfigToHardware portList

 

if [packetGroup getRx $chas $card $rxPort] {

errorMsg "Error in packetGroup getRx"

return "FAIL"

}

#########################################################################

# Configuring 4K stat & 8K stat through TCL for Novus 10G/25G, K400 100G

#########################################################################

packetGroup setDefault

# For 4K stat

packetGroup config -pgidStatMode 0

OR

# For 8K stat

packetGroup config -pgidStatMode 1

if {[packetGroup setRx $chas $card $rxPort]} {

errorMsg "Error calling packetGroup setRx $chas $card $rxPort "

set retCode $::TCL_ERROR

}

# Let the hardware know about the two ports

ixWriteConfigToHardware portList

 

if [packetGroup getRx $chas $card $rxPort] {

errorMsg "Error in packetGroup getRx"

return "FAIL"

}

 

# Wait for changes to take affect and make sure links are up

after 1000

ixCheckLinkState portList

 

# Start the packet groups on the receive port

# and then the transmit from the transmit port

 

ixPuts "Starting packet groups"

ixStartPortPacketGroups $chas $card $rxPort

 

ixPuts "Starting port transmit"

ixStartPortTransmit $chas $card $txPort

 

after 1000

 

# and then wait for things to be done

ixPuts "Waiting for transmit done"

ixCheckPortTransmitDone $chas $card $txPort

 

ixPuts "Stopping packet groups"

ixStopPortPacketGroups $chas $card $rxPort

 

# Now get the statistics back

# First a get for all of the packet groups

if [packetGroupStats get $chas $card $rxPort 0 16384] {

errorMsg "Error in packetGroupStats get"

return "FAIL"

}

set numGroups [packetGroupStats cget -numGroups]

 

set numRxLatencyBins [packetGroupStats cget -numLatencyBins]

ixPuts "# received latency bins = $numRxLatencyBins"

 

ixPuts "PGID LBin FrameSz # MinLat MaxLat AvgLat byRate frRate stdDev "

ixPuts "------- ------- ------- ------- ------- ------- ------- ------- ------- ------- "

 

for {set i 0} {$i < $numFrames} {incr i} {

 

packetGroupStats getGroup $i

set totalFrames [packetGroupStats cget -totalFrames]

 

ixPuts -nonewline "$i\t"

ixPuts -nonewline "All\t"

ixPuts -nonewline "[expr ($i+1) * 64]\t"

ixPuts -nonewline "$totalFrames\t"

ixPuts -nonewline [packetGroupStats cget -minLatency]

ixPuts -nonewline "\t"

ixPuts -nonewline [packetGroupStats cget -maxLatency]

ixPuts -nonewline "\t"

ixPuts -nonewline [packetGroupStats cget -averageLatency]

ixPuts -nonewline "\t"

ixPuts -nonewline [packetGroupStats cget -byteRate]

ixPuts -nonewline "\t"

ixPuts -nonewline [packetGroupStats cget -frameRate]

ixPuts -nonewline "\t"

ixPuts [packetGroupStats cget -standardDeviation]

 

for {set latencyBin 0} {$latencyBin < $numRxLatencyBins} \

{incr latencyBin} \

{

if {$latencyBin == 0} {

if [packetGroupStats getFirstLatencyBin] {

errorMsg "Error in packetGroupStats getFirstLatencyBin"

return "FAIL"

}

} else {

if [packetGroupStats getNextLatencyBin] {

errorMsg "Error in packetGroupStats getNextLatencyBin"

return "FAIL"

}

}

set numLatencyFrames [latencyBin cget -numFrames]

 

if [packetGroupStats getLatencyBin $latencyBin] {

errorMsg "Error in packetGroupStats getLatencyBin"

return "FAIL"

}

 

ixPuts -nonewline "\t"

ixPuts -nonewline "$latencyBin\t\t"

ixPuts -nonewline "$numLatencyFrames\t"

ixPuts -nonewline [latencyBin cget -minLatency]

ixPuts -nonewline "\t"

ixPuts -nonewline [latencyBin cget -maxLatency]

ixPuts -nonewline "\t\t"

ixPuts -nonewline [latencyBin cget -byteRate]

ixPuts -nonewline "\t"

ixPuts [latencyBin cget -frameRate]

}

}

 

#############################################################

#

# Time Bin sample

#

#############################################################

 

set numPgidPerTimeBin 4

set numTimeBins 2

set timeBinDuration 10000000000

 

# set the time bin options

packetGroup config -enableLatencyBins false

packetGroup config -enableTimeBins true

packetGroup config -numPgidPerTimeBin $numPgidPerTimeBin

packetGroup config -numTimeBins $numTimeBins

packetGroup config -timeBinDuration $timeBinDuration

 

if [packetGroup setRx $chas $card $rxPort] {

errorMsg "Error in packetGroup setRx"

return "FAIL"

}

 

# Let the hardware know about the two ports

ixWriteConfigToHardware portList

 

if [packetGroup getRx $chas $card $rxPort] {

errorMsg "Error in packetGroup getRx"

return "FAIL"

}

###############################################################

packetGroup setDefault

# For 8K stat

packetGroup config -pgidStatMode 0

OR

# For 32K stat

packetGroup config -pgidStatMode 1

if {[packetGroup setRx $chassis $card $port]} {

errorMsg "Error calling packetGroup setRx $chassis $card $port"

set retCode $::TCL_ERROR

}

################################################################

# Wait for changes to take affect and make sure links are up

after 1000

ixCheckLinkState portList

 

# Start the packet groups on the receive port

# and then the transmit from the transmit port

 

ixPuts "Starting packet groups"

ixStartPortPacketGroups $chas $card $rxPort

 

 

ixStartPortTransmit $chas $card $txPort

 

after 1000

 

# and then wait for things to be done

ixPuts "Waiting for transmit done"

ixCheckPortTransmitDone $chas $card $txPort

 

ixPuts "Stopping packet groups"

ixStopPortPacketGroups $chas $card $rxPort

 

# Now get the statistics back

# First a get for all of the packet groups

if [packetGroupStats get $chas $card $rxPort 0 16384] {

errorMsg "Error in packetGroupStats get"

return "FAIL"

}

set numGroups [packetGroupStats cget -numPgidPerTimeBin]

 

set numRxTimeBins [packetGroupStats cget -numTimeBins]

ixPuts "# received time bins = $numRxTimeBins"

ixPuts "# PGID per time bin = $numGroups"

 

ixPuts "T-BIN PGID FrameSz # MinLat MaxLat AvgLat byRate frRate stdDev "

ixPuts "------- ------- ------- ------- ------- ------- ------- ------- ------- ------- "

 

for {set t 1} {$t < = $numRxTimeBins} {incr t} {

for {set i 0} {$i < $numPgidPerTimeBin} {incr i} {

 

packetGroupStats getGroup $i $t

set totalFrames [packetGroupStats cget -totalFrames]

 

ixPuts -nonewline "$t\t"

ixPuts -nonewline "$i\t"

ixPuts -nonewline "[expr ($i+1) * 64]\t"

ixPuts -nonewline "$totalFrames\t"

ixPuts -nonewline [packetGroupStats cget -minLatency]

ixPuts -nonewline "\t"

ixPuts -nonewline [packetGroupStats cget -maxLatency]

ixPuts -nonewline "\t"

ixPuts -nonewline [packetGroupStats cget -averageLatency]

ixPuts -nonewline "\t"

ixPuts -nonewline [packetGroupStats cget -byteRate]

ixPuts -nonewline "\t"

ixPuts -nonewline [packetGroupStats cget -frameRate]

ixPuts -nonewline "\t"

ixPuts [packetGroupStats cget -standardDeviation]

}

}

SEE ALSO

packetGroupStats.