Home

Net Protocol Suite API Reference Manual

image

Contents

1. API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred API ERROR INVALID TRIGGER NAME 7 Invalid trigger name API ERROR INVALID DEVICE INDEX 5 Invalid device index 5 6 12 APlAnalyzerSettings_SetTrigPosition Prototype APIAnalyzerSettings SetTrigPosition APIAnalyzerSettings api analyzer settings int device index int trig position Description It sets the trigger position Parameters api analyzer settings Analyzer settings pointer device index Zero based index of the device Trio position Project triggers position It can be 1 to 99 Table 37 Error codes for APlAnalyzerSettings SetTrigPosition API error code Value Description API ERROR INVALID OBJECT 2 The API object is not valid API EXCEPTION 1 An exception occurred API ERROR INVALID TRIGGER POSITION 8 Invalid trigger position It must be between 1 and 99 API ERROR INVALID DEVICE INDEX 5 Invalid device index 5 6 13 APIAnalyzerSettings GetTrigPosition Prototype APIAnalyzerSettings GetTrigPosition APIAnalyzerSettings api analyzer settings int device index int trig position Description It returns the trigger position Parameters api analyzer settings Pointer of the analyzer settings device index Zero based index of the device trig position Project trigger s position It can be 1 to 99 Page 41 Net Protocol Suite API Ref
2. Page 39 Net Protocol Suite API Reference Manual Teledyne LeCroy Table 34 Error codes for APlAnalyzerSettings_ SetTrigMode API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred API_ERROR_INVALID_TRIG_MODE 11 Invalid trigger mode 5 6 10 APIAnalyzerSettings GetTrigMode Prototype APIAnalyzerSettings_GetTrigMode APIAnalyzerSettings api analyzer settings ETriggerMode trig mode Description It returns trigger mode Parameters api analyzer settings Analyzer settings pointer trig mode Returns trigger mode SNAPSHOT 0 PATTERN 1 Table 35 Error codes for APlAnalyzerSettings_GetTrigMode API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred 5 6 11 APlAnalyzerSettings_SetTrigFilterSetting Prototype APIAnalyzersettings_SetTrigFiltersetting APIAnalyzersettings api_analyzer_settings int device_index const char trig_setting_name Description It sets trigger filter setting Parameters api_analyzer_settings Pointer of the analyzer settings trig_setting_name Null terminated Trigger Filter setting name in the currently opened project Page 40 Teledyne LeCroy Net Protocol Suite API Reference Manual Table 36 Error codes for APlAnalyzerSettings_SetTrigFilterSetting
3. 40 Table 34 Error codes for APIAnalyzerSettings SetTrigMode 40 Table 36 Error codes for APlAnalyzerSettings_SetTrigFilterSetting oooooonniiiinnn 41 Table 37 Error codes for APIAnalyzerSettings SetTrigPosition 41 Table 38 Error codes for APIAnalyzerSettings GetTrigPosition 42 Table 39 Error codes for AP Trace_create cancelan 43 Table 40 Error codes for APlTrace_destroy 2 2 42 cececteceeeeeeeeeeseeeeeeeeeeseesneccenens 43 Table 41 Error codes for APITrace Open issus 44 Table 42 Error codes for AP Trace_Close nes 44 Table 43 Error codes for APITrace GetStartDateTime c 0oooooooccoccccccccccccccccccncnnnannnnanano nono 45 Table 44 Error codes for APITrace GetEndDateTime c oooooococccoocccccccccccccccccccnananananana nono 45 Table 45 Error codes for APITrace GetTriggerDateTime 45 Table 46 Error codes for APITracePacket Create 46 Table 47 Error codes for APITracePacket_destroy ocooocccccccccoconococccccccococcccncccncnananannnnnos 46 Table 48 Error codes for APITracePacket GetTimeStamp oooooocccccccccccccccccccnonananananannno 47 Table 49 Error codes for APITracePacket_GetChannel 47 Table 50 Error code
4. Prototype APIAnalyzerSettings GetSegmentBufferSize APIAnalyzerSettings api analyzer settings int device index int segment buffer size Description It returns the size of the segment buffer Parameters api analyzer settings Pointer of the analyzer settings device index Zero based index of the device Segment buffer size Segment buffer size specified in KB Table 28 Error codes for APIAnalyzerSettings_GetSegmentBufferSize API error code Description API ERROR INVALID OBJECT The API object is not valid API EXCEPTION An exception occurred API ERROR INVALID DEVICE INDEX Invalid device index 5 6 4 APlAnalyzerSettings_SetSegmentBufferSize Prototype APIAnalyzerSettings SetSegmentBufferSize APIAnalyzerSettings api analyzer settings int device index int segment size Description It sets the size of a segment buffer Parameters api analyzer settings Pointer of the analyzer settings device index Zero based index of the device segment size New segment size in Kbytes Table 29 Error codes APlAnalyzerSettings SetSegmentBufferSize API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred API ERROR INVALID SEGMENT SIZE 9 Invalid segment size API ERROR INVALID DEVICE INDEX 5 Invalid device index Page 37 Net Protocol Suite API Reference Manual Teledyne LeCroy 5 6 5 APlAnalyzerSettings_Se
5. log Studio 2012 v110 b gt gt Build Events BEE Using ATL gt Custom Build Step Character Set Use Multi Byte Character Set gt Managed Resources Common Language Runtime Support No Common Language Runtime Support gt Custom Build Tool Whole Program Optimization No Whole Program Optimization gt XML Data Generator Tool Windows Store App Support No Figure 4 Defining output directory 3 Set the path to the output directory Highlight this text and replace with c Users Public Documents LeCroy Net Protocol Suite API SDK bin For Windows XP the directory is c Program Files LeCroy Net Protocol Suite API SDK bin 4 2 2 Select input file 1 Under Configuration Properties select Linker and under that select Input Page 18 Teledyne LeCroy Net Protocol Suite API Reference Manual 2 Select Additional Dependencies pop popes Poe TT Configuration Active Debug v Platform Active Win32 gt Common Properties A Additional Dependencies kernel32 lib user a Configuration Properties Ignore All Default Libraries General Ignore Specific Default Libraries Debugging Module Definition File VC Directories Add Module to Assembly b C C Embed Managed Resource File 4 Linker Force Symbol References General Delay Loaded Dlls input Assembly Link Resource Manifest File Debugging Figure 5 Defining dependencies 3 Copy this into the field to the right c Users Public Documents Le
6. It cannot stop jammer process Page 35 Net Protocol Suite API Reference Manual Teledyne LeCroy The following errors are returned by callback function Table 25 Callback Errors for APIProject StopJammers API error code Value Description API_ERROR_JAMMER 18 An error occurred during jammer process 5 6 Analyzer settings Declarations and prototypes APIAnalyzerSettings h 5 6 1 APlAnalyzerSettings_create Prototype APIAnalyzerSettings create APIAnalyzerSettings api analyzer settings Description It creates a new analyzer settings object Parameters api analyzer settings Itis a pointer reference to created analyzer settings object Table 26 Error codes for APlAnalyzerSettings create API error code Value Description API ERROR INSUFFICIENT MEMORY 3 There is insufficient memory to create a new API object 5 6 2 APlAnalyzerSettings destroy Prototype APIAnalyzerSettings destroy APIAnalyzerSettings api analyzer settings Description It destroys the created APlAnalyzerSettings object Parameters api analyzer setting Pointer to the APlAnalyzerSettings object Table 27 Error codes for APIAnalyzerSettings destroy API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid Page 36 Teledyne LeCroy Net Protocol Suite API Reference Manual 5 6 3 APlAnalyzerSettings_GetSegmentBufferSize
7. device_index Index of device It is a zero based index Table 13 Error codes for APIProject_Assign API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred API_ERROR_INVALID_CHAIN_INDEX 4 Invalid chain index API_ERROR_INVALID_DEVICE_ INDEX 5 Invalid device index API_ERROR_SELECTED_DEVICE_IS_NOT_UPDATED 27 The selected device is not updated API_ERROR_CAN_NOT_ASSIGN_TO_DEVICE 31 It cannot assign to the selected device 5 5 12 APIProject StartRecording Prototype APIProject StartRecording APIProject api project int chain index int trigger settings count const char trigger settings names OnTracecreatedProc OnTracecreated OnReportRecordingStatusProc OnReportRecordingstatus OnAnalyzerErrorProc OnError int time out Description It starts the recording process Parameters api project Pointer of the project object opened by APIProject Open chain index Index of chain It is a zero based index trigger settings count Number of trigger setting names trigger setting names Null terminated Trigger Filter setting name in the current opened project If it is Null the default is used event handler It refers to a callback function to handle event notifications from the APIs If it is NULL then events will not be sent to the client If the user wants to follow or perform any process during a different recoding
8. iterator will be initialized to the beginning of the trace Parameters api trace Trace object Api trace iterator Reference pointer of created iterator object Table 63 Error codes for APITracelterator create API error code Value Description API ERROR INVALID TRACE 14 Invalid API trace object API ERROR INSUFFICIENT MEMORY 3 There is insufficient memory to create a new API object 5 9 2 APlTracelterator_destroy Prototype APITraceIterator destroy APITraceIterator api_trace_iterator Description It destroys the created trace iterator object Parameters api trace iterator Pointer to the trace iterator object Table 64 Error codes for APITracelterator destroy API error code Value Description API ERROR INVALID OBJECT 2 The API object is not valid 5 9 3 APlTracelterator_HasNext Prototype APITraceIterator HasNext APITraceIterator api trace iterator bool has next Description It returns true if iteration has more packets when traversing in forward direction otherwise returns false Parameters api trace iterator Pointer to the trace iterator object Page 52 Teledyne LeCroy Net Protocol Suite API Reference Manual has next If there is a next packet it will be true otherwise it will be false Table 65 Error codes for APITracelterator HasNext API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid
9. of the packet Returned value It returns packet bookmark strings only the bookmark title The packet object manages the returned buffers Do not attempt to manually delete the buffers The buffers are valid as long as the packet object is alive and the trace is open Table 61 Error codes for APITracePacket_GetBookmark API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred 5 8 9 APITracePacket_SetBookmark Prototype APITracePacket_SetBookmark APITracePacket api_trace_packet const char bookmark Description It places a new bookmark on the packet If the packet already has an existing bookmark it is replaced with the new one Page 50 Teledyne LeCroy Net Protocol Suite API Reference Manual Parameters api_trace_packet Pointer to the trace packet object bookmark Name of the bookmark Table 62 Error codes for APITracePacket_SetBookmark API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred Page 51 Teledyne LeCroy Net Protocol Suite API Reference Manual 5 9 Trace iterator methods Declarations and prototypes APITracelterator h 5 9 1 APlTracelterator_create Prototype APITraceIterator create APITrace api trace APITraceIterator api trace iterator Description It creates a new trace iterator object The
10. open Table 53 Error codes for APITracePacket_GetData API error code Value Description API ERROR INVALID OBJECT 2 The API object is not valid API EXCEPTION 1 An exception occurred The format for each packet type is as follows Unless otherwise specified the byte ordering is little endian Table 54 Connect Disconnect DWord Description 0 Connect 1 Disconnect 0 Table 55 Ethernet Frame DWord Description 0 Ethernet Frame 1 Ethernet Frame 2 Ethernet Frame N Ethernet Frame Table 56 FC Frame DWord Description 0 SOF 1 FC Frame 2 FC Frame N EOF Table 57 Ethernet Ordered Set DWord Description 0 Order Set Data 64 bits 1 2 Order Set Count Page 49 Net Protocol Suite API Reference Manual Teledyne LeCroy Table 58 FC Ordered Set DWord Description 0 Order Set Data 32 bits 1 Order Set Count Table 59 Auto Negotiation Packed Format DWord Description 9 Count Table 60 Training Sequence DWord Description 0 Control Field Status Fields 1 Count 5 8 8 APITracePacket_GetBookmark Prototype APITracePacket_GetBookmark APITracePacket api_trace_packet char bookmark Description It returns the packet s bookmark Parameters api_trace_packet Pointer to the trace packet object bookmark Current bookmark
11. pair port index API_ERROR_CAN_NOT_STOP_JAMMER 2 It cannot stop jammer process The following errors are returned by callback function Table 23 Callback Errors for APIProject StopJammer API error code Value Description API_ERROR_JAMMER 18 An error occurred during jammer process 5 5 17 APIProject_StopJammers Prototype APIProject_StopJammers APIProject api project int chain index int device index int count int pair port indexes Description It stops the jammer process on a set of ports If any port has a problem it does not stop and continues to stop jamming other ports It returns the last error code if any exists Otherwise it returns zero Parameters api project Pointer of the project object opened by APIProject Open chain index The chain s index It is a zero based index device index The device s index It is a zero based index count The jammer count pair port indexes Array of indexes of pair ports It is a zero based index Table 24 Error codes for APIProject_StopJammers API error code Value Description API ERROR INVALID OBJECT 2 The API object is not valid API EXCEPTION An exception occurred API ERROR INVALID CHAIN INDEX Invalid chain index 1 4 API ERROR INVALID DEVICE INDEX 5 Invalid device index 6 API ERROR INVALID PAIR PORT INDEX Invalid pair port index API ERROR CAN NOT STOP JAMMER 2
12. project object created by APIProject_create file_name Null terminated project file name Table 5 Error codes for APIProject_Open API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred API ERROR CAN NOT OPEN PROJECT 25 It cannot open the project 5 5 4 APIProject Close Prototype APIProject Close APIProject api project Description It disconnects from all boards and closes the opened project by calling APIProject open Parameters api project Pointer of the project object opened by APIProject Open Table 6 Error codes for APIProject Close API error code Value Description API ERROR INVALID OBJECT 2 The API object is not valid API EXCEPTION 1 An exception occurred API ERROR CAN NOT CLOSE PROJECT 23 It cannot close project API ERROR CAN NOT SAVE PROJECT 24 It cannot save project API ERROR CAN NOT DISCONNECT FROM DEVICE 26 It cannot disconnect from a device 5 5 5 APIProject_Save Prototype APIProject Save APIProject api project Description It saves the project Page 26 Teledyne LeCroy Net Protocol Suite API Reference Manual Parameters api_project Pointer of the opened project object by APIProject_create Table 7 Error codes for APIProject_Save API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid A
13. 8 APIAnalyzerSettings GetNumberOfSegment J rrnrnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnennnnnnnnnnnnnnnnnnnnnsnsenenennr 39 APIAnalyzerSettings SetTrigMode sn 39 APlAnalyzerSettings_GetTrigMode sms 40 APIAnalyzerSettings SetTrigFilterSetting sise 40 APIAnalyzerSettings SetTrigPosition sise 41 APIAnalyzerSettings GetTrigPosition ss 41 57 Trace methods thea nent en sne metre ed nage i tre sde ge reseau sui ees 43 APITrace Create agents eee tenant mn te nanenies 43 APITrace destroy 5 8 dre sn sie TS 43 APIT race OPen a ARLA AR AARAA ERER 43 APITr ce CloSe iii bis 44 APITrace GetStartDateTime mmrnavvvnnnnnnnvvnnnnnnnnvnnnnnnnnnvnennnnnnnvnnnnnnnnvnnnnnnnnnnnnnnnnnnnnnnnnnnnnennnnnnnnnennnn 44 APITrace GetEndDateTime rrnnnnnvvnnnnnnnnvvnnnnnnnnvnnnnnnnnnvnnnnnnnnnvnnnnnnnnnvnennnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnenr 45 APITrace GetTriggerDateTime rnnnnnnnnnvnnnnnnnnvnnnnnnnnnvnnnnnnnnnvnnnnnnnnnnnennnnnnennnnnnnnsnnnnnnnnnnnnnnnnnnnnnennen 45 5 8 Packet Method iii id dd e in id 46 APITFACOPACKet Createl ege Eege i 46 Ablfracebacket desttovtt ee EKER ESA arancel cl i n 46 APITracePacket GetTimeStamp rernnnnnnnnnvnnnnnnnnvnnnnnnnnnvnvnnnnnnnvnnnnnnnnvnnnnnnnnnnennnnnnnnnnnnnnnnenennnnnnnnnn 46 4 Net Protocol Suite API Reference Manual Contents Teledyne LeCroy APITracePacket GetChannel rrrnnavvn
14. API_EXCEPTION 1 An exception occurred 5 9 4 APlTracelterator_HasPrevious Prototype APITraceIterator HasPrevious APITraceIterator api trace iterator bool has previous Description It returns true if iteration has more packets when traversing in backward direction otherwise returns false Parameters api trace iterator Pointer to the trace iterator object has previous lfthere is any previous packet it will be true otherwise it will be false Table 66 Error codes for APITracelterator HasPrevious API error code Value Description API ERROR INVALID OBJECT 2 The API object is not valid API EXCEPTION 1 An exception occurred 5 9 5 APlTracelterator_GetNext Prototype APITraceIterator GetNext APITraceIterator api_trace_iterator APITracePacket api trace packet Description It returns the iterator packet and moves the iterator forward Parameters api trace iterator Pointer to the trace iterator object api trace packet Next packet container Returned value It returns next packet of iterator and moves the iterator forward Page 53 Teledyne LeCroy Net Protocol Suite API Reference Manual Table 67 Error codes for APITracelterator GetNext API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred 5 9 6 APlTracelterator_GetPrevious Prototype APITraceIterator GetP
15. Croy Net Protocol SuiteNAPINSDKALibXTLNetAPI Tib e For Windows XP use this instead C Program Files LeCroy Net Protocol Suite API SDK Lib TLNetAPIL lib 4 2 3 Select directory for include files 1 Under Configuration Properties select C C and under that select General Page 19 Net Protocol Suite API Reference Manual Teledyne LeCroy 2 Goto Additional Include Directories Project1 Property Pages Configuration Active Debug v Platform Active Win32 gt Common Properties a Additional Include Directories a Configuration Properties Additional using Directories General Debug Information Format Program Database for Edit Debugging Common Language RunTime Support VC Directories Consume Windows Runtime Extension a C C Suppress Startup Banner Yes nologo General Warning Level Level3 W3 Optimization Treat Warnings As Errors No WX d t SDL checks Yes sdl Code Generation S Ce Multi processor Compilation Language Precompiled Heade Figure 6 Defining include directories 3 Enter the following directory c Users Public Documents LeCroy Net Protocol Suite API SDK Include 4 On the Property Pages window select OK to accept these changes The contents of the include folder are listed below TLNetAPI h Initializes and releases the API gets the final internal error code and gets a description of any internal error code functions APIProject h Declares the project func
16. EXCEPTION 1 An exception occurred 5 4 Error handling All API functions return an integer value in code from the API ErrorCode enumeration H any error occurs a proper error code is returned If no code is returned then that means that no error occurred In some cases more details are available about the error APIError_GetLastError can be called to return the internal error code The description of an internal error code returned by APIError_GetLastError can be collected by calling APIError GetDescription Declarations and prototypes TLNetAPI h 5 4 1 APIError_GetLastError Prototype APIError_GetLastError int Description If any error occurs during an API function call the function returns an error in code from the EAPIErrorCode enumeration In some cases more details are available about the error This function returns the last occuring internal error code The returned value is an integer To collect a complete description call APIError GetDescription Parameters None Returned value It returns the last internal API error code 5 4 2 APIError_GetDescription Prototype APIError_GetDescription int error_code char error_description int max_length_error_description void Description It returns a description of an error code Parameters error_code An integer value as error code error_description An allocated buffer that is passed to collect the description of the error max_length_e
17. Manual Teledyne LeCroy 5 8 Packet methods Declarations and prototypes APITracePacket h 5 8 1 APITracePacket_create Prototype APITracePacket create APITracePacket api_trace_packet Description It creates a new trace object Parameters api trace packet Itis a pointer reference to a created packet object Table 46 Error codes for APITracePacket create API error code Value Description API ERROR INSUFFICIENT MEMORY 3 There is insufficient memory to create a new API object 5 8 2 APITracePacket destroy Prototype APITracePacket destroy APITracePacket api trace packet Description It destroys the created packet object Parameters api trace packet Pointer to the trace object Table 47 Error codes for APITracePacket destroy API error code Value Description API ERROR INVALID OBJECT 2 The API object is not valid 5 8 3 APITracePacket_GetTimeStamp Prototype APITracePacket_GetTimeStamp APITracePacket api_trace_packet __int64 timestamp Description It returns time stamp of the packet in picosecconds One picosecond is equal to 1 1000 nanosecond Parameters api_trace_packet Pointer to the trace packet object timestamp Timestamp of the packet in picoseconds Page 46 Teledyne LeCroy Net Protocol Suite API Reference Manual Table 48 Error codes for APITracePacket_GetTimeStamp API error code Value Description API_ER
18. PI_EXCEPTION 1 An exception occurred API ERROR CAN NOT SAVE PROJECT 24 It cannot save the project 5 5 6 APIProject_GetChainCount Prototype APIProject GetChaincCount APIProject api project int chain count Description It returns the number of included chains in the project Parameters api project Pointer of the project object opened by APIProject create chain count The number of chains in the project Table 8 Error codes for APIProject GetChainCount API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred 5 5 7 APIProject_GetDeviceCount Prototype APIProject_GetDevicecount APIProject api_project int chain_index int device_count Description It returns the number of devices in project s chain Parameters api_project Pointer of the project object opened by APIProject_create chain index Index of the chain It is a zero based index device_count Number of devices in index th chain of the project Table 9 Error codes for APIProject_GetDeviceCount API error code Value Description API_ERROR_INVALID_OBJECT The API object is not valid API_EXCEPTION An exception occurred Page 27 Net Protocol Suite API Reference Manual Teledyne LeCroy 5 5 8 APIProject GetPairPortCount Prototype APIProject GetPairPortCount APIProject api project int chain index int device index
19. ROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred 5 8 4 APITracePacket GetChannel Prototype APITracePacket GetChannel APITracePacket api trace packet int channel Description It returns the packet s channel Parameters api trace packet Pointer to the trace packet object channel Channel of the packet Table 49 Error codes for APITracePacket_GetChannel API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred 5 8 5 APlTracePacket_GetSpeed Prototype APITracePacket_GetSpeed APITracePacket api_trace_packet EAnalyzerSpeed speed Description It returns the packet s speed Parameters api_trace_packet Pointer to the trace packet object speed Speed of the packet Table 50 Error codes for APITracePacket_GetSpeed API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred 5 8 6 APITracePacket GetType Prototype APITracePacket GetType APITracePacket api trace packet EDataType type Description It returns the packet s protocol Page 47 Net Protocol Suite API Reference Manual Teledyne LeCroy Parameters api_trace_packet Pointer to the trace packet object type Itreturns the type of the packet The Packet Type enumeration is given below ConnectDis
20. _iterator Description It moves the iterator pointer to the last packet Parameters api_trace_iterator Pointer to the trace iterator object Table 73 Error codes for APITracelterator ToBack API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred 5 9 12 APITracelterator ToFront Prototype APITraceIterator ToFront APITraceIterator api trace iterator void Description It moves the iterator pointer to the first packet Parameters api trace iterator Pointer to the trace iterator object Table 74 Error codes for APITracelterator ToFront API error code Value Description API ERROR INVALID OBJECT 2 The API object is not valid API EXCEPTION 1 An exception occurred 5 10 Examples The following is a simple example for using the API to iterate through all the packets in a trace file For complete examples please refer to the API examples named Trace and Project which are provided with the Net Protocol Suite installer This example is located in the directory API Examples Project and API Examples Trace Page 56 Teledyne LeCroy 6 How to Contact Teledyne LeCroy Net Protocol Suite API Reference Manual Type of Service Contact Call for technical support US and Canada 1 800 909 2282 Worldwide 1 408 653 1260 Fax your questions Worldwide 1 408 727 6622 Write a l
21. atus OnJammerErrorProc OnError Description It starts the jammer process Parameters api_project Pointer of the project object opened by APIProject_Open chain_index The chain s index It is a zero based index device_index The device s index It is a zero based index pair_port_index The pair port s index It is a zero based index scenario_name Null terminated Scenario name If it is Null then the project default is used event handler It refers to a callback function to handle the events If it is NULL the events will not be sent to the client Table 18 Error codes for APIProject_StartJammer API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred API ERROR CAN NOT START JAMMER 13 It cannot start jammer process API ERROR SELECTED DEVICE IS NOT UPDATED 27 The selected device is not updated API ERROR INVALID CHAIN INDEX 4 Invalid chain index API ERROR INVALID DEVICE INDEX 5 Invalid device index API ERROR INVALID PAIR PORT INDEX 6 Invalid pair port index API ERROR INVALID SCENARIO NAME 28 Invalid scenario name Page 32 Teledyne LeCroy Net Protocol Suite API Reference Manual The following errors are returned by callback function Table 19 Callback Errors for APIProject_StartJammer API error code Value Description API_ERROR_JAMMER 18 An error occurred during jammer pro
22. cess 5 5 15 APIProject_StartJammers Prototype APIProject_StartJammers APIProject api project int chain_index int device_index int count int pair_port_indexes const char scenario_names OnReportMonitoringStatusProc OnReportMonitoringStatus OnReportJammerStatusProc OnReportJammerstatus OnJammerErrorProc OnError Description It starts the jammer process on a set of ports If any port has a problem it does not stop it starts to jam another port It returns the last error code if any exists otherwise it returns zero Parameters api_project Pointer of the project object opened by APIProject Open chain index The chain s index It is a zero based index device_index The device s index lt is a zero based index count Jammer count pair_port_indexes Array of indexes of pair ports It is a zero based index scenario_names Array of indexes of scenario names Null terminated Scenario name If it is Null project default is used event_handler Itrefers to a callback function to handle the events If it is NULL the events will not be sent to the client Table 20 Error codes for APIProject_StartJammers API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred API ERROR CAN NOT START JAMMER 13 It cannot start jammer process API ERROR SELECTED DEVICE IS NOT UPDATED 27 The selected
23. connect 0 EthernetFrame 1 FCFrame 2 EthernetOrderedSet 3 FCOrderedSet 4 AutoNegotiation 5 TrainingSequence 6 Table 51 Error codes for APITracePacket_GetType API error code Value Description API ERROR INVALID OBJECT 2 The API object is not valid API EXCEPTION 1 An exception occurred Table 52 Packet type enumeration Packet Type Value enum Connect Disconnect 0 Ethernet Frame FC Frame Ethernet Ordered Set FC Ordered Set Auto Negotiation O oO A Goy N gt Training Sequence 5 8 7 APITracePacket_GetData Prototype APITracePacket_GetData APITracePacket api_trace_packet unsigned char data int data_length Description The raw_data parameter will be set to the address of the raw data buffer of the packet The return value shows the size of the buffer in bytes The packet object manages the raw data buffer Do not attempt to manually delete the buffer The buffer is valid as long as the packet object is alive and the trace is open Parameters api_trace_packet Pointer to the trace packet object data It will be set to the address of the packet s data buffer Page 48 Teledyne LeCroy Net Protocol Suite API Reference Manual data_length Data size in bytes The packet object manages the raw data buffer Do not attempt to manually delete the buffer The buffer is valid as long as the packet object is alive and the trace is
24. device is not updated API ERROR INVALID CHAIN INDEX 4 Invalid chain index API ERROR INVALID DEVICE INDEX 5 Invalid device index API ERROR INVALID PAIR PORT INDEX 6 Invalid pair port index API ERROR INVALID SCENARIO NAME 28 Invalid scenario name Page 33 Net Protocol Suite API Reference Manual Teledyne LeCroy The following errors are returned by callback function Table 21 Callback Errors for APIProject_StartJammers API error code Value Description API_ERROR_JAMMER 18 An error occurred during jammer process 5 5 16 APIProject_StopJammer Prototype APIProject StopJammer APIProject api_project int chain index int device index int pair port index Description It stops the jammer process Parameters api project Pointer of the project object opened by APIProject Open chain index The chain s index It is a zero based index device index The device s index It is a zero based index pair port index The pair port index It is a zero based index Page 34 Teledyne LeCroy Net Protocol Suite API Reference Manual Table 22 Error codes forAPIProject_StopJammer API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION An exception occurred API_ERROR_INVALID_CHAIN_INDEX Invalid chain index 1 4 API ERROR INVALID DEVICE INDEX 5 Invalid device index 6 API ERROR INVALID PAIR PORT INDEX Invalid
25. e run a scenario in jammer record a new trace Page 13 Net Protocol Suite API Reference Manual Teledyne LeCroy 3 System requirements 3 1 Operating System Windows XP Windows 7 Windows 8 1 Windows Server 2003 32 bit Windows Server 2008 R2 and Windows Server 2012 The latest Service Pack available for the Windows OS in use is required It is recommended that the 64 bit Windows version of the Operating Systems is installed as these allow using more RAM memory than the 32 bit ones 3 2 Required applications Microsoft Internet Explorer version 6 or newer To view the manuals datasheets and other documents you would need to install Adobe Acrobat Reader http get adobe com reader 3 3 Memory RAM For improved performance of the software it is recommended that 16GB of RAM is installed on the host machine Memory as little as 2GB will still allow the software to function but would impair its performance 3 4 Non volatile Storage SDD or Hard Disk Storage space of 200 MB is required for installing the Net Protocol Suite software onto the host machine Additional storage space is needed to operate the software application and to store recorded data in files Please remember that storing large captured traces can result in multiple gigabytes of file sizes and can quickly fill your available storage space 3 5 Connectivity Teledyne LeCroy recommended a Gigabit 1000 Mbps Ethernet or a USB 3 0 link for conn
26. ect GetPortConfiguration Prototype APIProject GetPortConfiguration APIProject api project int chain index int device index ELinkconfiguration port config Description It returns the port configuration of a device in a chain Parameters api_project Pointer of the project object by APIProject create chain index Index of the chain lt is a zero based index device index Index of the device It is a zero based index port_config Port configuration of the chain s device Table 12 Error codes for APIProject_GetPortConfiguration API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred API_ERROR_INVALID_DEVICE_INDEX 5 Invalid device index API_ERROR_INVALID_CHAIN_INDEX 4 Invalid chain index 5 5 11 APIProject_Assign Prototype APIProject_Assign APIProject api project unsigned short serial number EConnectionType connection type int chain index int device index Description It connects to a board and assigns it to a device of a chain in the project If any board needs to be updated it returns error codes Parameters api project Pointer of the project object opened by APIProject Open serial number The board s serial number connect type The board s connection type It can be USB or TCP chain index Index of chain It is a zero based index Page 29 Net Protocol Suite API Reference Manual Teledyne LeCroy
27. ecting with SierraNet analyzers At minimum the host machine should have either a 100 1000 Mbps Ethernet connection to the network or a USB 2 0 port If multiple analyzers are daisy chained and connected to the same host machine one Ethernet connection or one USB port is required for each analyzer Please note that there is no connectivity requirement if the analysis application is used to only view pre recorded traces For tips as for how to improve on the performance of the Teledyne LeCroy analysis system and more specifically on the performance of the software please refer to the User Manual Page 14 Teledyne LeCroy Net Protocol Suite API Reference Manual 4 Configure Visual Studio e Perform the following setup to use the library and create your own client applications Note In order for your application to be able to connect to analyzers over Ethernet your application must run a Windows message loop The following MSDN article has details about how to do this http msdn microsoft com en us library windows desktop ms644928 v vs 85 aspx 4 1 Install Net Protocol Suite 1 Download and install Teledyne LeCroy s Net Protocol Suite software e Use the CD that is included with the product 2 Or download the software from the Teledyne LeCroy website http teledynelecroy com support softwaredownload 3 Select Support Software Downloads Protocol Solutions Analysis Software and select Ethernet 4 2 Open Visua
28. eeeeeeeeeeeseeenesenenscceeeees 25 Table 5 Error c des for APIProject OPEN sfr ere ege ienest 26 Table 6 Error codes for APIProject_ Close ss ssen 26 Table 7 Error codes for APIProject_Save 27 Table 8 Error codes for APIProject_GetChainCount sseeeeeeeeeeeeeeeseesssssreerrerrerene 27 Table 9 Error codes for APIProject Geiievicet oun 27 Table 10 Error codes for APIProject GetboarbortC oun 28 Table 11 Error codes for APIProject GetAnalyzerSettings ooooocicccccnnccccnccnccccnncnnnicnnnnnns 28 Table 12 Error codes for APIProject GetPortConfiguration ssrrrrrrrnnnnnnnnnnnnnnnnrnnnnrnnnn 29 Table 13 Error codes for APIProject Assign cccccccccccccccinnnnnnnncconononnnoncnnnnnnnononnnnnnnnnnnns 30 Table 14 Error codes for APIProject StartRecording cccccocccccnconcconnnnnoncncncncncnnnnnininanannns 31 Table 15 Callback Errors for APIProject_StartRecording cooooccccccncncnonnnncccccccccncnnnncnanannns 31 Table 16 Error codes for APlProject_StopRecordingl cccccocncnnnnnnccononononcncnoncncnnnnnnnnnnnnnnns 31 Table 17 Callback Errors for APIProject_StopRecording 32 Table 18 Error codes for APIProject_StartJammer 32 Table 19 Callback Errors for APIProject Gtoartloammert 33 Table 20 Error codes for APIProject_StartJammers oooooccccnnncnncconononono
29. er it will change to the valid maximum segment buffer size depending on the quantity of current segments Page 38 Teledyne LeCroy Net Protocol Suite API Reference Manual Parameters api_analyzer_settings Pointer of the analyzer settings segment_number Number of segments Table 32 Error codes for APlAnalyzerSettings_SetNumberOfSegment API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred API ERROR INVALID NUMBER OF SEGMENT 10 Invalid number of segments 5 6 8 APIAnalyzerSettings GetNumberOfSegment Prototype APIAnalyzerSettings GetNumberofsegment APIAnalyzerSettings api analyzer settings int number of segment Description It returns the number of segments Parameters api analyzer settings Pointer of the analyzer settings segment number Number of segments Table 33 Error codes for APlAnalyzerSettings GetNumberOfSegment API error code Value Description API ERROR INVALID OBJECT 2 The API object is not valid API EXCEPTION 1 An exception occurred 5 6 9 APlAnalyzerSettings_ SetTrigMode Prototype APIAnalyzerSettings_SetTrigMode APIAnalyzerSettings api_analyzer_settings ETriggerMode trig_mode Description It sets trigger mode Parameters api_analyzer_settings Analyzer settings pointer trig_mode Trigger mode can be one of these values SNAPSHOT 0 PATTERN 1
30. erence Manual Teledyne LeCroy Table 38 Error codes for APlAnalyzerSettings_GetTrigPosition API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred API_ERROR_INVALID_DEVICE_INDEX 5 Invalid device index Page 42 Teledyne LeCroy Net Protocol Suite API Reference Manual 5 7 Trace methods Declarations and prototypes APITrace h 5 7 1 APlTrace_create Prototype APITrace_create APITrace api_trace Description It creates a new trace object Parameters api_trace Itis a pointer reference to a created trace object Table 39 Error codes for APITrace_create API error code Value Description API_ERROR_INSUFFICIENT_MEMORY 3 There is insufficient memory to create a new API object 5 7 2 APlTrace_destroy Prototype APITrace_destroy APITrace api_trace Description It destroys the created trace object It does not close the trace file It calls APITrace_Close function before destroying the api_trace object Parameters api_trace Pointer to the trace object Table 40 Error codes for APITrace_destroy API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred API_ERROR_CAN_NOT_SAVE_TRACE 21 It cannot save the trace API ERROR CAN NOT CLOSE TRACE 22 It cannot close the trace 5 7 3 APIT
31. etter Teledyne Lecroy Protocol Solutions Group Customer Support 3385 Scott Blvd Santa Clara CA 95054 3115 Send e mail psgsupport lecroy com Visit Teledyne LeCroy s website teledynelecroy com Page 57
32. ing Target Name S ProjectName VC Directories Target Extension ee gt C C Extensions to Delete on Clean cdf cache obj ilk resour gt Linker Build Log File S IntDir VS MSBuildProjectNam p Manifest Tool Platform Toolset Visual Studio 2012 v110 e zem Enable Managed Incremental Build No MIDL Project Defaults gt XML Document Generator Cas Type Appeton LA T is Use of MFC Use Standard Windows Librarie gt Build Events Use of ATL Not Using ATL gt Custom Build Step Character Set Use Multi Byte Character Set gt Managed Resources Common Language Runtime Support No Common Language Runtirr Custom Build Tool Whole Program Optimization No Whole Program Optimizatic gt XML Data Generator Tool Windows Store App Support No gt Code Analysis gt HLSL Compiler Figure 3 Property pages 4 2 1 Select output directory 1 In the drop down menu to the right select Browse 2 Find the directory C Users Public Documents LeCroy Net Protocol Suite APINSDKIbin e Or in the drop down menu to the right select Edit e The window Output Directory opens Page 17 Net Protocol Suite API Reference Manual Teledyne LeCroy figuration Active Debug x Platform Active Win32 Z Coni s General Common Properties Configuration Properties Output Directory SolutionDir Configuration General Intermediate Directory Configuration Debugai i ache obj ilk resources tlb tli S MSBuildProjectName
33. int pair port count Description It returns the number of pair ports supported by a device in a project s chain Parameters api_project Pointer of the project object opened by APIProject_create chain_index Index of the chain It is a zero based index device_index Index of the device It is zero based index pair port count Number of the device s pair port in the project Table 10 Error codes for APIProject_GetPairPortCount API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred 5 5 9 APIProject_GetAnalyzerSettings Prototype APIProject_GetAnalyzerSettings APIProject api_project int chain_index APIAnalyzerSettings api_analyzer_settings Description It returns the analyzer settings of a specific chain in the opened project Parameters api_project Pointer of the project object opened by APIProject_create chain_index Index of the chain It is a zero based index api_analyzer_settings Refers to the pointer of the analyzer settings of the project s chain_index Table 11 Error codes for APIProject GetAnalyzerSettings API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred API_ERROR_INVALID_CHAIN_INDEX 4 Invalid chain index Page 28 Teledyne LeCroy Net Protocol Suite API Reference Manual 5 5 10 APIProj
34. l Studio 1 Open Microsoft Visual Studio 2 Create or open a project pg Projectl Microsoft Visual Studio FILE EDIT VIEW PROJECT BUILD DEBUG TEAM S y if va elt v gt Local Windows Solution Explorer v 1 x o a gp Ap Search Solution Explorer Ctrl A 4 Project1 Sal Header Files Eg Resource Files ba Source Files Figure 1 Selecting project name Page 15 Net Protocol Suite API Reference Manual 3 Right click on Project e The Project menu opens Search Solution Explorer Ctrl fa Solutio 4 Pro Solution Exp E D Am FX E e Build Rebuild Clean Project Only Scope to This New Solution Explorer View Profile Guided Optimization Calculate Code Metrics Build Customizations Add References Class Wizard Manage NuGet Packages View Class Diagram Set as StartUp Project Debug Add Solution to Source Control Cut Remove Rename Unload Project Rescan Solution Open Folder in File Explorer Teledyne LeCroy Ctrl Shift X Ctrl X Del F2 Figure 2 Selecting properties menu item Page 16 Teledyne LeCroy Net Protocol Suite API Reference Manual 4 Select Properties e Project Property Pages opens Project1 Property Pages i Ga Configuration Platform Active Win32 gt Common Properties 4 General 4 Configuration Properties SolutionDir Configuration General Intermediate Directory S Configuration Debugg
35. le TELEDYNE LECROY Everywhereyoulook Net Protocol Suite API Reference Manual Generated October 13 2015 15 05 Net Protocol Suite API Reference Manual Teledyne LeCroy Document disclaimer The information contained in this document has been carefully checked and is believed to be reliable However no responsibility can be assumed for inaccuracies that may not have been detected Teledyne LeCroy reserves the right to revise the information presented in this document without notice or penalty Trademarks and servicemarks Teledyne LeCroy is a trademark of Teledyne LeCroy Microsoft and Windows are registered trademarks of Microsoft Inc All other trademarks are property of their respective companies Copyright Copyright 2014 Teledyne LeCroy All Rights Reserved This document may be printed and reproduced without additional permission but all copies should contain this copyright notice Page 2 Contents ss A A teesaceseeee 13 2 FUNCION iio 13 21 Operations On trace OUT 13 2 2 Packet TR 13 2 3 Project navigation recording and jammer rsenrnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnennnnnnnnnennnnnnnennn 13 3 System requirements RSR ener el NP a ee 14 3 1 Operating SysteM mociones a ten ana tente heve ne eEk 14 3 2 Required applications ic A ad 14 3 3 Memory RAM io ct ar lid veveeeegests 14 3 4 Non volatile Storage SDD or Hard Disk arernnnnnnnvnnnnnnnnnnvnnnnnnnnnvennnnnnnnvnn
36. nitialized Parameters None Returned value It always returns zero Page 22 Teledyne LeCroy Net Protocol Suite API Reference Manual 5 2 Enumerations All API enumerations are located in SDK Includes APIEnumerations h 5 3 Version Info Methods 5 3 1 APIGetVersion Prototype APIGetVersion int major int minor int build no Description This function gets the version of the software Parameters major major software version minor minor manor software version build no build number of software Table 1 Error codes for APIGetVersion API error code Value Description API EXCEPTION 1 An exception occurred 5 3 2 APIGetHardwarelnfo Prototype APIGetHardwarelnfo unsigned short serial number unsigned short product id Description It gets product ID of a device Parameters serial number serial number of the board product id product id of the board If no board with the input serial number exists the return value is 33 API ERROR INVALID ARGUMENT It is possible to get the complete description of the error code by calling APIError GetLastError and APIError GetDescription functions Product id it can be one of the following values Value Product Id 0x3102 M408 0x3502 M168 0x1402 M8 4 0x1802 M164 Page 23 Net Protocol Suite API Reference Manual Teledyne LeCroy Table 2 Error codes for APIGetHardwarelnfo API error code Value Description API_
37. nnccncncnononinininnnnnns 33 Table 21 Callback Errors for APIProject_StartJammers ooooonnciccnncccnnnoconcccnnnncnncnnnnninnnnns 34 Table 22 Error codes forAPIProject_StopJammer 95 Table 23 Callback Errors for APIProject_StopJammer 35 Table 24 Error codes for APIProject_StopJammers 35 Table 25 Callback Errors for APIProject_StopJammersS eeeeeeeeeeeeeeeeeeeeeeeeeeees 36 Table 26 Error codes for APIAnalyzerSettings Create 36 Table 27 Error codes for APlAnalyzerSettings _destroy seeeeeeeeeeeeeeeeeeeeeeeeeeeees 36 Table 28 Error codes for APlAnalyzerSettings_GetSegmentBufferSize 37 Table 29 Error codes APIAnalyzerSettings_SetSegmentBufferSize 37 Table 30 Error codes APlAnalyzerSettings_SetTraceFileName 38 Table 31 Error codes APlAnalyzerSettings_ GetTraceFileName rrrnnnnnnnnnnnnnnnnnnnnnnnnn 38 Net Protocol Suite API Reference Manual 9 Teledyne LeCroy Contents Table 32 Error codes for APIAnalyzerSettings SetNumberOfSegment 39 Table 33 Error codes for APIAnalyzerSettings GetNumberOfSegment s000sccesss0nn 39 Table 35 Error codes for APlAnalyzerSettings_GetTrigMode
38. nnnnnnnnnnnnnnnnnnsnnnnnnnnnsenennnnnnnnnnn 54 APITracelterator PeekPrevious rrnnnnnnnnnvvnnnnnnnvnnnnnnnnnvnnnnnnnnnvnnnnnnnnennnnnnnnnnnnnnnnnnnnnnnnnnnenennnnnnennen 55 APlTracelterator GetAt mida idas 55 APITracelterator GetCount rvrnnnnnnvnnnnnnnnnvnnnnnnnnvnnnnnnnnnvnnnnnnnnvnnnnnnnnennnnnnnnnnnnnnnnnnennnnnnnnsnnnnnnnnnnnnnnn 55 APITracelterator ToBack ooo ii EE re ENER ekke reabo bien itnn tn 56 APITracelterator ToFront minne deed is 56 5 10 Examples inte ee isse 56 6 How to Contact Teledyne LeCroy rrnnnnnnnnnnnnnnnnnnnnnnnnnnvvvnvnennnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnen 57 Net Protocol Suite API Reference Manual Teledyne LeCroy Contents 6 Net Protocol Suite API Reference Manual List of Figures Figure 1 Selecting project name A a 15 Figure 2 Selecting properties menu fem aient 16 Figure 3 Property pages os toa 17 Figure 4 Defining output directory a Ee ei A tt 18 Figure 5 Defining dependentes icon 19 Figure 6 Defining include directories ss same 20 Net Protocol Suite API Reference Manual 7 Teledyne LeCroy Contents 8 Net Protocol Suite API Reference Manual List of Tables Table 1 Error codes for APIGetVersion ss 23 Table 2 Error codes for APIGetHardwarelnfo 24 Table 3 Error codes for APIProject create 44 nn 25 Table 4 Error codes for APIProject_destroy 2 c ccceceeeee
39. nnnnnnnnvnnnnnnnnnvnnnnnnnnnvnnnnnnnnvnennnnnnnnnennnnnnnvnnnnnnnnnnennnnnnnnnnnnnnnnnnnen 47 APITracePacket GetSpeed J rnnnnnnnnvvvnnnnnnnnvvnnnnnnnnvnnnnnnnnnvnnnnnnnnvnnnnnnnnnnnnnnnnnnnnnnnnnnsnnnnnnnnnennnnnnnnnnnnn 47 APITracePacket GetType mmrnnnnnnnvvvnnnnnnnvvvnnnnnnnvvnnnnnnnnvnnnnnnnnnvnnnnnnnnnnvnnnnnnnnnnnnnnnnnenennnnnnnnnnnnnnnnnnnnnn 47 APITracePacket GetDatal a aa 48 APITracePacket GetBookmark sise 50 APITracePacket SetBookmark arrrnnnnnnnnvvnnnnnnnnnvnnnnnnnnnvennnnnnnvnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnennnnnnnnnenen 50 5 9 Trace iterator methods ii ccccicccsecctectecesesectcecesereeceseestunctecessnnctes sesctuncesesepnnciecaveaacter dE CERN 52 APITracelterator create ccccicecedevstecsneeeseccdeeescaccedes cteccedeescencadeceesaecedevscacce sesvences svedaveceteseeecesers 52 APlTracelterator_destroy ooioimniicaimiiii ii EVERE EEEEEEEEE KEEN 52 APITracelterator H sNext ooo cia if 52 APITracelterator HasPrevious mrravvvnnnnnnnvvnnnnnnnnvnnnnnnnnvnennnnnnnvnnnnnnnnnvnnnnnnnnnnnnnnnnnnnnnnnnnnnennnnnnsenenene 53 APITracelterator GetNext rrnnnnnnnnnvvnnnnnnnnvvnnnnnnnnvvnnnnnnnnvennnnnnnvnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnennnnn 53 APITracelterator GetPrevious J rrmmrnavvrnnnnnnnvvnnnnnnnvnnnnnnnnnvnnnnnnnnnvnnnnnnnnvnnnnnnnnnnnnnnnnnnnvnnnnnnnsnnnnnnnsnnnnnn 54 APITracelterator PeekNext J rrrnnnnnnnvvnnnnnnnnvvnnnnnnnvnnnnnnnnnvnnnnnnnnnvnnnnnnn
40. nnnnnnnvnnnnnnnnsvnnnnnnnnsvnennnnnnnnnnnnnr 14 3 5 Connectivity esiaren a iaa 14 4 Config re Visual Studio 4 15 4 1 Install Net Protocol Suite ege ENEE A a a en 15 4 2 Open Visual Studio iii iaa 15 Sel ct output directory eseu SEENEN DEE AER kanne eaeeera steere ducted eee 17 Select input TE 18 Select directory for include fileS rrrrnnnnnvnnnnnnnnnvnnnnnnnnvnnnnnnnnnvnnnnnnnnnnennnnnnnnnennnnnnnvnnnnnnnnenennnnnnenennnnnn 19 4 3 Creating and using Objects oooonmcccccnnnnencccnnnnnnencnnnnn nece 21 5 Understanding the library interface sense 22 5 1 Initialize release ad E E 22 APINE e paa Sake es 22 APIU initia LE ALT ER ER A Re 22 5 2 Enumeratlonsi smi areira aas n iss a aa ANA diets dessins nn AE NEA ane aari 23 5 3 Version Info MethodS cocotero AAN EEEa EE KARUAN ARAR NAATA RAA EUNANA REN 23 APIGetVersion oreen a EE ANE ENE E E EIE ANE A EARRA 23 APIGetH rdwarelnfo soiin ct tai 23 S4 Error handling a ad ti in 24 APIError GetkastError i 4 cosita a 24 APlError GetDescription lt oomcomia ia 24 5 5 Project methods ii A ENEE e Es 25 APIProj ct create i 25 Net Protocol Suite API Reference Manual 3 Teledyne LeCroy Contents APIProject destroy ccc ooo o ii 25 APIProject penis caridad 25 APlProject Close A R Aa A RAA EAER ENAA 26 APIProjeCt Savel A O 26 APIProject_GetChainCount ss sise rat 27 APIProject GetDeviceCount J rrmnnavvnnnnnnnnvvvnnnnnnnvnnnnnnnnnvnnnnnnnnnvnnn
41. nnnnnvnnnnnnnnnnnnnnnnnnnnnnnnnnnennnnnnnnnnnnnn 27 APIProject GetPairPortCount rrnnnnnvvnnnnnnnnvnnnnnnnnvnnnnnnnnnvnvnnnnnnnvnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnsenennnnennnene 28 APIProject GetAnalyzerSettings ss 28 APlProject_GetPortConfiguration sens 29 APIProject Ee UN BEE 29 APIProject_St rtRecording ociioicccincccicrnncccccrin nacida 30 APIProject StopRecording rrrnnnnnvnnnnnnnnnvnnnnnnnnnvnnnnnnnnvnnnnnnnnnvnnnnnnnnnnnnnnnnnnnnnnnnnnnnnennnnnnnnnnnnnnnnnnnnnnnnr 31 APIProj ct StartJammer mi2 5ssoasetsneetesnnpondnder enn ERR caseacctercsecndtcecarenaectecaseanciescassudtceceesvensivsssvescetts 32 APlProject_StartJammMers iioiooooci nicocaconnnnnncccdnn cannot ciclones 33 APIProject_StopJamimer onc riirii enai annaa EANN Naan ESNA NEn KA NAANA ANA AAE ESNS AARAA ERARA 34 APIProject StopJammers e ooo KARARAN ELERA A SORE ARRENA caseuectesavacnusccessevendiets exaataccsexevbeetes 35 5 6 Analyzer settings ici aida 36 APlAnalyzerSettings_create sms 36 APIAnalyzerSettings _destroy sms 36 APlAnalyzerSettings_GetSegmentBufferSize ss 37 APlAnalyzerSettings_SetSegmentBufferSize ss 37 APlAnalyzerSettings_SetTraceFileName csseecccceseseeeeeeeeeeeeeeeeseseeeeeeeeeeeeeeseeeesneeseeseseeeeeesesseeeeens 38 APlAnalyzerSettings_ GetTraceFileName sms 38 APIAnalyzerSettings SetNumberOfSegment ss sssnsssssssnnnmnneneneens 3
42. race_Open Prototype APITrace Open APITrace api trace const char file name Description It opens a trace If trace file needs to be updated it will be updated and then opened The update process updates the trace file without creating any backup from the updated trace file Page 43 Net Protocol Suite API Reference Manual Teledyne LeCroy Parameters api_trace Pointer to the trace object file_name Null terminated string providing the full pathname to the trace file Table 41 Error codes for APITrace_Open API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred API_ERROR_CAN_NOT_UPDATE_TRACE 20 It cannot update the trace API_ERROR_CAN_NOT_OPEN_TRACE 19 It cannot open the trace 5 7 4 APlTrace_Close Prototype APITrace Close APITrace api trace Description It closes the opened trace object If the trace has any modification it is saved and then closed Parameters api trace Pointer to the trace object Table 42 Error codes for APITrace Close APlerorcode Value Description API ERROR INVALID OBJECT 2 The API object is not valid APL EXCEPTION 1 Anexceptionoceurred API ERROR CAN NOT SAVE TRACE 21 Itcannotsavethetrace API ERROR CAN NOT CLOSE TRACE 22 Itcannotclosethetrace 5 7 5 APlTrace_GetStartDateTime Prototype APITrace GetStartDateTime APITrace api
43. red during uploading process 5 5 13 APIProject_StopRecording Prototype APIProject StopRecording APIProject api project int chain index bool do not upload Description It stops any recording or uploading process Parameters api project Pointer of the opened project object by APIProject Open chain index The chain s index It is a zero based index Do not upload If itis true it does not upload any trace file or stop uploading if the uploading was started automatically Table 16 Error codes for APIProject_StopRecording API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred API_ERROR_INVALID_CHAIN_INDEX 4 Invalid chain index API ERROR CAN NOT STOP RECORDING 29 Page 31 Net Protocol Suite API Reference Manual Teledyne LeCroy The following errors are returned by callback function Table 17 Callback Errors for APIProject_StopRecording API error code Value Description API_ERROR_RECORDING 16 An error occurred during recording process API_ERROR_UPLOADING 17 An error occurred during uploading process 5 5 14 APIProject_StartJammer Prototype APIProject_StartJammer APIProject api_project int chain_index int device_index int pair_port_index const char scenario_name OnReportMonitoringStatusProc OnReportMonitoringStatus OnReportJammerStatusProc OnReportJammerSt
44. revious APITraceIterator api trace iterator APITracePacket api trace packet Description It returns previous packet of iterator and moves the iterator backward Parameters api trace iterator Pointer to the trace iterator object api trace packet Previous packet container Table 68 Error codes for APITracelterator GetPrevious API error code Value Description API ERROR INVALID OBJECT 2 The API object is not valid API EXCEPTION 1 An exception occurred 5 9 7 APlTracelterator_PeekNext Prototype APITraceIterator PeekNext APITraceIterator api trace iterator APITracePacket api trace packet Description It returns next packet of iterator without moving the iterator forward Parameters api trace iterator Pointer to the trace iterator object api trace packet Previous packet container Table 69 Error codes for APITracelterator PeekNext API error code Value Description API ERROR INVALID OBJECT 2 The API object is not valid API EXCEPTION 1 An exception occurred Page 54 Teledyne LeCroy Net Protocol Suite API Reference Manual 5 9 8 APlTracelterator_PeekPrevious Prototype APITraceIterator PeekPrevious APITraceIterator api_trace_iterator APITracePacket api trace packet Description It returns previous packet of iterator without moving the iterator backward Parameters api trace iterator Pointer to the trace iterator object api trace packet Pre
45. rror_description Maximum length of error description buffer Returned value None Page 24 Teledyne LeCroy Net Protocol Suite API Reference Manual 5 5 Project methods Declarations and prototypes APIProject h 5 5 1 APIProject_create Prototype APIProject_create APIProject api_project Description It creates a new object of project type Parameters api_project A pointer reference to a created project object Table 3 Error codes for APIProject_create API error code Value Description API_ERROR_INSUFFICIENT_MEMORY 3 There is insufficient memory to create a new API object 5 5 2 APlProject_destroy Prototype APIProject_destroy APIProject api_project Description This function tries to destroy the input project object First it tries to save and close the project If it cannot save or close or if the project is in use this function cannot destroy the input object and it will return an error If the project is in use and API cannot destroy it nothing happens Parameters api_project Pointer to the project object created by APIProject_create Table 4 Error codes for APIProject_destroy API_ERROR_INVALID_OBJECT 2 The API object is not valid 5 5 3 APIProject_Open Prototype APIProject_Open APIProject api_project const char file_name Description It opens a project Page 25 Net Protocol Suite API Reference Manual Teledyne LeCroy Parameters api_project Pointer of the
46. s for APITracePacket_GetSpeed cc ccssesecccceeeeeeeeeeeeeeeeeeeeeeeeeeeees 47 Table 51 Error codes for APITracePacket_GetType oooooooocccccocooccccccccccnccccoconinanananananonono 48 Table 52 Packet type enumeration se 48 Table 53 Error codes for APITracePacket_GetData 49 Table 54 CEET SEET 49 Table 55 Ethernet in EE 49 Table 50 FG in ol seres see 49 Table 57 Ethernet Ordered Set 49 Table 61 Error codes for APITracePacket GetBookmark oooooocccccccccccccccccnininnnncccnnns 50 Table 58 gt Fo Ordered di 50 Table 59 Auto Negotiation Packed Format 50 Table Ce ne UE 50 Table 62 Error codes for APITracePacket SetBookmark 51 Table 63 Error codes for APITracelterator Create 52 Table 64 Error codes for APITracelterator_destroy 52 Table 65 Error codes for APITracelterator HasNext nono 53 Table 66 Error codes for APITracelterator HasPrevious 53 Table 67 Error codes for APITracelterator GetNext eeeesssssssssssesssssrrrrrrrrressssssssesreee 54 Table 68 Error codes for APITracelterator GetPrevious 54 Table 69 Error codes for APITracelterator PeekNext coooooooococcococccccccccccccccccccnnnnnnnnnnano nono 54 Table 70 Error codes for APITraceltera
47. status the OnReportRecordingStatus callback function can be used to report changes in the status of the recording process The OnError callback function is called to report any errors that occur during the recording or uploading processes When a trace is created the OnTraceCreated callback function reports that a trace files has been created Page 30 Teledyne LeCroy Net Protocol Suite API Reference Manual Lime out Ifthe timeout is greater than 0 a timer will begin counting down from the timeout value H the recording is still in progress when the timer expires the recording will automatically stop If the timeout is less then or equal to zero the recording will continue until stopped by other means Table 14 Error codes for APIProject_StartRecording API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred API_ERROR_CAN_NOT_START_RECORDING 30 It cannot start recording process API_ERROR_SELECTED_DEVICE_IS_NOT_UPDATED 27 The selected device is not updated API_ERROR_INVALID_TRIGGER_NAME 7 Invalid trigger name API_ERROR_INVALID_CHAIN_INDEX 4 Invalid chain index The following errors are returned by callback function Table 15 Callback Errors for APIProject_StartRecording API error code Value Description API_ERROR_RECORDING 16 An error occurred during recording process API_ERROR_UPLOADING 17 An error occur
48. tTraceFileName Prototype APIAnalyzerSettings_SetTraceFi leName APIAnalyzerSettings api_analyzer_settings const char file_name Description It sets the file name of the analyzer settings Parameters api_analyzer_settings Pointer of the analyzer settings file_name A null terminate file name of analyzer settings object Table 30 Error codes APlAnalyzerSettings_SetTraceFileName API error code Value Description API ERROR INVALID OBJECT 2 The API object is not valid API EXCEPTION An exception occurred 5 6 6 APIAnalyzerSettings GetTraceFileName Prototype APIAnalyzerSettings GetTraceFilename APIAnalyzerSettings api analyzer settings char trace file name Description It returns the trace file name of the analyzer settings object Parameters api analyzer settings Pointer of the analyzer settings file name Returned trace file name This pointer must not be deleted or destroyed by the user Table 31 Error codes APlAnalyzerSettings GetTraceFileName API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred 5 6 7 APlAnalyzerSettings_SetNumberOfSegment Prototype APIAnalyzerSettings SetNumberofsegment APIAnalyzerSettings api analyzer settings int segment number Description It sets the number of segments If the segment buffer size is not valid according to the device property and new segment numb
49. tions APIAnalyzerSettings h Declares the project s analyzer setting functions APIEventHandlers h Declares any callback functions that report the status of recording and jammer processes and reports any process errors or progress APITrace h Declares all functions APITraceIterator h Defines trace iterating APITracePacket h Defines packet navigating Page 20 Teledyne LeCroy Net Protocol Suite API Reference Manual 4 3 Creating and using objects 1 Create a Trace object and open the trace as follows 2 Create a Trace Iterator and pass the already created Trace Object during its construction 3 That s it You are now ready to use the different methods of trace and iterator 4 Don t forget to destroy all created objects Net Protocol Suite API Reference Manual Teledyne LeCroy 5 Understanding the library interface 5 1 Initialize release API Initialize and release the API before you use it Use the following functions to initialize and release the API Declarations and prototypes 5 1 1 APlinitialize Prototype Description This function initializes the API It must be called before any other API function calls Parameters None Returned value It always returns zero 5 1 2 APlUninitialize Prototype Description This function releases the API It must be called after the last API function call If any API function is called after this it returns an error code that means API has not been i
50. tor PeekPrevious 55 Table 71 Error codes for APITracelterator Gei 55 Table 72 Error codes for APITracelterator Gett oun 56 10 Net Protocol Suite API Reference Manual Contents Teledyne LeCroy Table 73 Error codes for APITracelterator_ToBack 56 Table 74 Error codes for APITracelterator ToFront c oooooococcconocccccccccccccncccccccnnanannnnaaannnnno 56 Net Protocol Suite API Reference Manual 11 Teledyne LeCroy Contents 12 Net Protocol Suite API Reference Manual Teledyne LeCroy Net Protocol Suite API Reference Manual 1 Introduction Teledyne LeCroy s Net Protocol Suite API Application Programming Interface is a C based library which allows you to extract link packets in net trace files open projects record traces and run jammer scenarios 2 Functions 2 1 Operations on trace file The API supports operations such as setting the trace file name of an project setting the number of segments setting the size of segment buffers running jammer scenarios and recording new traces 2 2 Packet navigation The API supports operations such as iterating through trace packets extracting full raw frame data and any metadata such as time stamps 2 3 Project navigation recording and jammer The API supports operations such as set trace file name of a project set number of segment set segment buffer siz
51. trace time t Start date time Description It returns the start date time of the trace object Parameters api trace Pointer to the trace object Start date time Start date time of the trace Page 44 Teledyne LeCroy Net Protocol Suite API Reference Manual Table 43 Error codes for APITrace_GetStartDateTime API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred 5 7 6 APlTrace_GetEndDateTime Prototype APITrace_GetEndDateTime APITrace api trace time_t end_date_time Description It returns the end date time of the trace object Parameters api_trace Pointer to the trace object end_date_time End date time of the trace Table 44 Error codes for APITrace_GetEndDateTime API_ERROR_INVALID_OBJECT NES The API object is not valid API_EXCEPTION EN An exception occurred 5 7 7 APlTrace_GetTriggerDateTime Prototype APITrace_GetTriggerDateTime APITrace api_trace time_t trig_date_time Description It returns the trigger date time of the trace object Parameters api_trace Pointer to the trace object trig_date_time Trig datetime of the trace Table 45 Error codes for APITrace_GetTriggerDateTime API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred Page 45 Net Protocol Suite API Reference
52. vious packet container Table 70 Error codes for APITracelterator PeekPrevious API error code Value Description API ERROR INVALID OBJECT 2 The API object is not valid API EXCEPTION 1 An exception occurred 5 9 9 APlTracelterator_GetAt Prototype APITraceIterator GetAt APITraceIterator api trace iterator int index APITracePacket api trace packet Description It returns packet in the input index Parameters api trace iterator Pointer to the trace iterator object index Index of record It is a zero based index api trace packet Packet container Table 71 Error codes for APITracelterator GetAt API ERROR INVALID OBJECT EC The API object is not valid API_EXCEPTION An exception occurred API ERROR INVALID INDEX OF PACKET 15 Invalid index of packet 5 9 10 APITracelterator GetCount Prototype APITraceIterator GetCount APITraceIterator api trace iterator int count Description It returns the number of packets Page 55 Teledyne LeCroy Net Protocol Suite API Reference Manual Parameters api_trace_iterator Pointer to the trace iterator object count Packet count Table 72 Error codes for APITracelterator_GetCount API error code Value Description API_ERROR_INVALID_OBJECT 2 The API object is not valid API_EXCEPTION 1 An exception occurred 5 9 11 APlTracelterator_ToBack Prototype APITraceIterator ToBack APITraceIterator api_trace

Download Pdf Manuals

image

Related Search

Related Contents

Honeywell Thermostat T8665A User's Manual  MODE D`EMPLOI - Comment remplir votre questionnaire  Socles de diascopie TL RC™ TL RCI™  Honeywell DR4300 Users manual, 44-01-25-16a  ディスポ電極 NC-032 ビトロード  取扱説明書  MEDISOUND pro II  XCellTM Sensor Replacement Instructions for ALTAIR® 4X  - LED Signs  Toshiba Satellite C55-B5200  

Copyright © All rights reserved.
Failed to retrieve file