4 itrace::exporttotext, Itrace::exporttotext – Teledyne LeCroy FireInspector Automation Application Programming Interface User Manual
Page 35

31
FireInspector Automation User’s Manual
CATC
Version 1.0
2.4.4
ITrace::ExportToText
Exports trace into text file, allows to export a range of packets
Syntax
HRESULT ExportToText (
[in] BSTR file_name,
[in, defaultvalue(-1)] long packet_from,
[in, defaultvalue(-1)] long packet_to );
Parameters
•
file_name
–
string providing the full pathname to file where trace is exported
•
packet_from
–
beginning packet number when you are exporting a range of packets,
value –1 means that the first packet of exported trace would be the first packet of this
trace
•
packet_to
–
ending packet number when you are exporting a range of packets, value
–1 means that the last packet of exported trace would be the last packet of this trace
Return values
•
ANALYZERCOMERROR_UNABLESAVE
–
unable to export trace file
Remarks
Use this method if you want to export recorded or opened trace into the text file. If the dis-
play options applied to this trace (see ITrace::ApplyDisplayOptions
and
IAnalyzer::LoadDisplayOptions on page 20) then hidden packets would not be exported.
If packet range is specified and it is invalid (for example
packet_to
is more than last
packet number in the trace, or
packet_from
is less then first packet number in the
trace, or
packet_from
is more then
packet_to
) then packet range will be adjusted
automatically.
Here is a snippet of export file:
File C:\Program Files\CATC\FireInspector\Samples\AVC.fdb.
From Packet #0 to Packet #60.
Packet#
11_____| S(1) WriteResp(lbl: 0) dest_ID(FFC0) src_ID(FFC2)
rt(X)
_______| rcode(complete) header_CRC(0x2007F63C)
ACK(complete) Idle( 20.096 ms)
_______| Time Stamp(00018.5600 0805)
_______|___________________________________________________
12_____| S(1) WriteDB(lbl: 48) dest_ID(FFC0) src_ID(FFC2)
rt(X)
_______| dest_offset(FFFF: F0000B00) data_len(8)
header_CRC(0x119EA4CA)
_______| Data(2 quadlets) data_CRC(0x690D88A9) ACK(complete)
Idle( 6.454 ms)
_______| Time Stamp(00018.5761 0123)
_______|___________________________________________________
13_____| S(1) WriteDB(lbl: 0) dest_ID(FFC2) src_ID(FFC0)
rt(X)
_______| dest_offset(FFFF: F0000D00) data_len(8)
header_CRC(0xD98CC0DC)