This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

CODECOMPOSER: .out file slow to load under dss.sh js environment

Part Number: CODECOMPOSER
Other Parts Discussed in Thread: CCSTUDIO

Ubuntu 18.04

No AV software running

CCS 1110

J7100(J7ES) EVM version E7 SOM with on board XDS110 debug probe

Running java script with dss.sh that will sequentially load multiple .out files, run them and store the CIO results in individual report files.  Flow runs but all .out loads after the first one take 10min or more (first load takes seconds).  I can change the order of the .out files and swap first and second and it is always the second and subsequent loads that take longer.

Possibly related, I have also had this experience on CCS 10.1.1 running on Windows 10 doing manual loads... power cycling the board and unplug/plug the USB will clear it in that case.

Any ideas on how to speed this up would be greatly appreciated!

TIA,
Frank Cano

Here is a the JavaScript

importPackage( Packages.com.ti.debug.engine.scripting )
importPackage( Packages.com.ti.ccstudio.scripting.environment )
importPackage(java.io);
importPackage(java.lang);

arguments = this.arguments;

var runDir, exePattern, kernelList, testCaseList, configFile, reportDir, testCase;
//if (arguments.length < 3)
if (arguments.length < 5)
{
exitWithHelp();
} else {
runDir = arguments[0];
kernelList = arguments[1];
testCaseList = arguments[2];
configFile = arguments[3];
reportDir = arguments[4];
}


debugServer = ScriptingEnvironment.instance().getServer( "DebugServer.1" )
debugServer.setConfig( configFile )

//m3ds = debugServer.openSession( "Spectrum Digital XDS560V2 STM USB Emulator_0/DMSC_Cortex_M3_0" );
m3ds = debugServer.openSession( "Texas Instruments XDS110 USB Debug Probe_0/DMSC_Cortex_M3_0" );

// m3ds = debugServer.openSession(
// "Texas Instruments XDS110 USB Debug Probe_0/DMSC_Cortex_M3_0"
// );


print ("Connecting to M3 ...")
m3ds.target.connect();
print ("Connected to M3!")

/* Run the DDR Configuration */
print("Running the DDR configuration... Wait till it completes!");
m3ds.target.halt();
m3ds.expression.evaluate("J7ES_LPDDR4_Config()");
// m3ds.target.runAsynch();

// for (i=0;i<numReset;i++)
// {
// reset[i]=m3ds.getResetType(i);


// // Issue a system reset
// if (reset[i].getName().indexOf("System Reset") != -1)
// {
// print ("Issuing System Reset")
// reset[i].issueReset();
// print(reset[i].getName());
// }
// }

// m3ds.target.reset();
// m3ds.expression.evaluate("OnTargetConnect()");

//dspds = debugServer.openSession( "Spectrum Digital XDS560V2 STM USB Emulator_0/C71X_0" );
dspds = debugServer.openSession( "Texas Instruments XDS110 USB Debug Probe_0/C71X_0" );
// dspds = debugServer.openSession(
// "Texas Instruments XDS110 USB Debug Probe_0/C71X_0"
// );
dspds.target.connect();
// dspds.target.reset();

var kernelListFileReader = new FileReader(kernelList);
var kernelBufferedReader = new BufferedReader(kernelListFileReader);
var kernelLine, testCaseLine;
var exeFile;
var kernelDir;
var kernelName;

print ("Running all kernels and all test cases in a loop");
while ((kernelLine = kernelBufferedReader.readLine()) != null) {
kernelName = kernelLine;
kernelDir = runDir + kernelName;
testCaseList = kernelDir + "/test_reports/test_id_list.txt"
var testCaseListFileReader = new FileReader(testCaseList);
var testCaseBufferedReader = new BufferedReader(testCaseListFileReader);
while ((testCaseLine = testCaseBufferedReader.readLine()) != null) {
// print (kernelName.split("/").pop());
// kernelName.match(/\/(.*)/)
exeFile = kernelDir + '/' + "out" + '/' + kernelName.split("/").pop() + "_C7100_test_case_" + testCaseLine + ".out";
// m3ds.expression.evaluate("Toggle_C7x_LRST()");
print ("Loading binary: " + exeFile + "...");
dspds.memory.loadProgram(exeFile);
reportDir = kernelDir + "/test_reports/"
dspds.beginCIOLogging(reportDir + "test_dump_case_" + testCaseLine);
dspds.target.run();
dspds.endCIOLogging();
// dspds.target.reset();
}
testCaseBufferedReader.close();
}