Teledyne LeCroy USBTracer_Trainer - Users Manual User Manual

Page 333

Advertising
background image

USB Protocol Suite User Manual

Chapter 12: Traffic Generation (3.0 Exerciser)

LeCroy Corporation

319

Step 2 Enter file information in beginning comment lines:

#######################################################
# FILE INFORMATION:
# FILE:
# DESCRIPTION:
# REVISION HISTORY:
#######################################################

Step 3 Add a comment line by starting the line with #:

# INCLUDE FILES:

Step 4 To include main definitions and templates, add an include file line:

%include "Include\FrameworkLib.ginc"

Step 5 Add constants:

Const EndpointNum = 1
Const DeviceNumber = 1

Step 6 Add data patterns:

DataPattern SetAddrReq = { 00 05 00 00 00 00 00 00 }

Step 7 Add frame and structure templates:

struct DeliveryID
{
Sel : 1 = 1 # Stream Index
Val : 3
}

Step 8 (optional) Add global variables.

Step 9 (optional) Add generation settings.

Step 10Add the Main generation procedure, such as the following example:

Main
{
# Place your generations instructions here.
SetLinkState (LinkState = U0)
Call GetDescriptor(EndpointNum,0,DEVICE_DESC,0x00,
0x00,0x1200,WaitTPSleep,WaitDPSleep)
Call SetAddress(EndpointNum, DeviceNumber * 256,
WaitTPSleep, WaitDPSleep)
}

Note: You can use the Text Snippets on the left Text Snippets panel to add
commands and their parameters.

Advertising
This manual is related to the following products: