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.

RTOS/TDA3XEVM: multi-code program load EVE had trouble

Part Number: TDA3XEVM
Other Parts Discussed in Thread: CCSTUDIO

Tool/software: TI-RTOS

1. I design a board based TDA3x

2. I build the code build by Vision SDK. 

3. I load the code by launch_visionsdk_tda3xx.js,

    VSDK-do everything, then EVE had trouble,the error informatiom as follow

 ARP32_EVE_1: Trouble Determining Current Execution Packet(s): (Error -2138 @ 0x0) Unable to determine device revision. Reset the device, and retry the operation. If error persists, confirm configuration, power-cycle the board, and/or try more reliable JTAG settings (e.g. lower TCLK). (Emulation package 7.0.100.0) 

Then the CCS is stop at load the eve program!!!!!, I try to slow the TCLK, but it not work!

I try to find the printf infomation in all gel file ,but I can't find. How Can I to fix it

Thank you!!!!

  • Hi,

    Can you try loading the individual binaries.
    Please make sure that you issue a CPU reset on EVE before loading EVE binary.

    Regards,
    Rishabh
  • Hi Rishabh Garg
    Yes I can loading individual EVE binaries or out file to EVE!
    It work!!!
  • Hi,

    Kindly mark the post that answers your query as "This resolved my issue" and close the thread.

    Regards,
    Rishabh
  • Hi
    It is mistake,It is just can load individual EVE binaries or out file to EVE!
    But the load file by launch_visionsdk_tda3xx.js failed
  • Hi Rishabh Garg
    I load the problem one by one core by CCS;,Then run it on by on. The program is ok.
    But But the load program by launch_visionsdk_tda3xx.js do->everying.
    It had the error information as my questing, Then the stop at the loading EVE program phase!
  • Maybe the core is reseting

    Cortex_M4_IPU1_C0: GEL Output: --->>> TDA3xx Target Connect Sequence Begins ... <<<---
    Cortex_M4_IPU1_C0: GEL Output: --->>> A device reset occurred <<<---
    Cortex_M4_IPU1_C0: GEL Output: ==================================================
    Cortex_M4_IPU1_C0: GEL Output: ========= TDA3xx PG3.0 device detected =========
    Cortex_M4_IPU1_C0: GEL Output: ==================================================
    Cortex_M4_IPU1_C0: GEL Output: ========= TDA3xx PG3.0 device detected =========
    Cortex_M4_IPU1_C0: GEL Output: ========= TDA3xx GP Device detected ===========
    Cortex_M4_IPU1_C0: GEL Output: ========= TDA3xx 15x15 Device detected ===========
    Cortex_M4_IPU1_C0: GEL Output: ==================================================
    Cortex_M4_IPU1_C0: GEL Output: ========= TDA3xx GP Device detected ===========
    Cortex_M4_IPU1_C0: GEL Output: ========= TDA3xx 15x15 Device detected ===========
    Cortex_M4_IPU1_C0: GEL Output: ==================================================
    Cortex_M4_IPU1_C0: GEL Output: Core Reset has occurred.

    Cortex_M4_IPU1_C0: GEL Output: --->>> All Control module lock registers are UNLOCKED <<<---
    Cortex_M4_IPU1_C0: GEL Output: --->>> Changing RTI1 reaction type to avoid RTI1 resetting the device after 3 minutes... <<<---
    Cortex_M4_IPU1_C0: GEL Output: --->>> Starting IPU A-MMU configurations... <<<---
    Cortex_M4_IPU1_C0: GEL Output: --->>> IPU A-MMU configuration completed. <<<---
    Cortex_M4_IPU1_C0: GEL Output: ------------------------------------------------------------------------------------------
    Cortex_M4_IPU1_C0: GEL Output: --->>> DDR and DPLL configuration Based on Package selection pin status(Sysboot[7]) <<<---
    Cortex_M4_IPU1_C0: GEL Output: ------------------------------------------------------------------------------------------
    Cortex_M4_IPU1_C0: GEL Output: --->>> 15x15 Package Detected(SYSBOOT[7]=0)... <<<---
    Cortex_M4_IPU1_C0: GEL Output: --->>> PRCM Clock Configuration for OPPNOM in progress... <<<---
    Cortex_M4_IPU1_C0: GEL Output: --->>> CORE DPLL OPP 0 clock config is in progress...
    Cortex_M4_IPU1_C0: GEL Output: --->>> CORE DPLL OPP 0 is DONE!
    Cortex_M4_IPU1_C0: GEL Output: --->>> PER DPLL OPP 0 clock config in progress...
    Cortex_M4_IPU1_C0: GEL Output: --->>> PER DPLL OPP 0 is DONE!
    Cortex_M4_IPU1_C0: GEL Output: --->>> DSP_GMAC DPLL OPP 0 clock config is in progress...
    Cortex_M4_IPU1_C0: GEL Output: --->>> DSP_GMAC DPLL OPP 0 is DONE!
    Cortex_M4_IPU1_C0: GEL Output: --->>> EVE_VID_DSP DPLL OPP 0 clock config is in progress...
    Cortex_M4_IPU1_C0: GEL Output: --->>> EVE_VID_DSP_DPLL OPP 0 is DONE!
    Cortex_M4_IPU1_C0: GEL Output: --->>> PRCM Clock Configuration for OPP 0 is DONE! <<<---
    Cortex_M4_IPU1_C0: GEL Output: --->>> PRCM Configuration for all modules in progress... <<<---
    Cortex_M4_IPU1_C0: GEL Output: --->>> PRCM Configuration for all modules is DONE! <<<---
    Cortex_M4_IPU1_C0: GEL Output: --->>> DDR3 initialization starts (TI 15x15 EVM)... <<<---
    Cortex_M4_IPU1_C0: GEL Output: --->>> DDR3 Initialization is in progress ... <<<---
    Cortex_M4_IPU1_C0: GEL Output: --->>> DDR DPLL clock config for 532MHz is in progress...
    Cortex_M4_IPU1_C0: GEL Output: --->>> DDR DPLL clock config for 532MHz is in DONE!
    Cortex_M4_IPU1_C0: GEL Output: Launch full leveling
    Cortex_M4_IPU1_C0: GEL Output: Updating slave ratios in PHY_STATUSx registers
    Cortex_M4_IPU1_C0: GEL Output: as per HW leveling output
    Cortex_M4_IPU1_C0: GEL Output: HW leveling is now disabled. Using slave ratios from
    Cortex_M4_IPU1_C0: GEL Output: PHY_STATUSx registers
    Cortex_M4_IPU1_C0: GEL Output: --->>> DDR3 532MHz Initialization is DONE! <<<---
    Cortex_M4_IPU1_C0: GEL Output: --->>> TDA3xx Begin All Pad Configuration for Vision Platform <<<---
    Cortex_M4_IPU1_C0: GEL Output: --->>> TDA3xx Begin All Pad Configuration for RGMII usage on EVM Platform <<<---
    Cortex_M4_IPU1_C0: GEL Output: --->>> TDA3xx Begin GMAC_SW MDIO Pad Configuration <<<---
    Cortex_M4_IPU1_C0: GEL Output: --->>> TDA3xx End GMAC_SW MDIO Pad Configuration <<<---
    Cortex_M4_IPU1_C0: GEL Output: --->>> TDA3xx Begin GMAC_SW RGMII0 Pad Configuration <<<---
    Cortex_M4_IPU1_C0: GEL Output: --->>> TDA3xx End GMAC_SW RGMII0 Pad Configuration <<<---
    Cortex_M4_IPU1_C0: GEL Output: --->>> TDA3xx End All Pad Configuration for RGMII usage on EVM Platform <<<---
    Cortex_M4_IPU1_C0: GEL Output: --->>> TDA3xx End All Pad Configuration for Vision Platform <<<---
    Cortex_M4_IPU1_C0: GEL Output: --->>> TDA3xx Target Connect Sequence DONE !!!!! <<<---
    Cortex_M4_IPU1_C0: GEL Output: !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
    Cortex_M4_IPU1_C0: GEL Output: For STM based tracing on TI EVMs,
    Cortex_M4_IPU1_C0: GEL Output: run 'TDA3x EVM I2C EXPANDER CONTROL -> Enable_Trace_Pins()' function from Scripts menu on M4/CS_DAP_DebugSS
    Cortex_M4_IPU1_C0: GEL Output: !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
    Cortex_M4_IPU1_C0: GEL Output: --->>> DSP1SS Initialization is in progress ... <<<---
    Cortex_M4_IPU1_C0: GEL Output: DEBUG: Clock is active ...
    Cortex_M4_IPU1_C0: GEL Output: DEBUG: Checking for data integrity in DSPSS L2RAM ...
    Cortex_M4_IPU1_C0: GEL Output: DEBUG: Data integrity check in GEM L2RAM is sucessful!
    Cortex_M4_IPU1_C0: GEL Output: --->>> DSP1SS Initialization is DONE! <<<---
    Cortex_M4_IPU1_C0: GEL Output: --->>> DSP2SS Initialization is in progress ... <<<---
    Cortex_M4_IPU1_C0: GEL Output: DEBUG: Clock is active ...
    Cortex_M4_IPU1_C0: GEL Output: DEBUG: Checking for data integrity in DSPSS L2RAM ...
    Cortex_M4_IPU1_C0: GEL Output: DEBUG: Data integrity check in GEM L2RAM is sucessful!
    Cortex_M4_IPU1_C0: GEL Output: --->>> DSP2SS Initialization is DONE! <<<---
    Cortex_M4_IPU1_C0: GEL Output: --->>> Starting A-MMU config for EVE Config space access <<<---
    Cortex_M4_IPU1_C0: GEL Output: --->>> EVESS Initialization is in progress ... <<<---
    Cortex_M4_IPU1_C0: GEL Output: DEBUG: Clock is active ...
    Cortex_M4_IPU1_C0: GEL Output: DEBUG: Resetting EVE MMU ...
    Cortex_M4_IPU1_C0: GEL Output: DEBUG: Configuring EVE MMU1 TLB entry 0: 0x00000001 --> 0x00000000
    Cortex_M4_IPU1_C0: GEL Output: DEBUG: Configuring EVE MMU1 TLB entry 0: 0x00000002 --> 0x80000000
    Cortex_M4_IPU1_C0: GEL Output: DEBUG: Configuring EVE MMU1 TLB entry 0: 0x00000003 --> 0x40000000
    Cortex_M4_IPU1_C0: GEL Output: DEBUG: Configuring EVE MMU1 TLB entry 0: 0x00000004 --> 0x48000000
    Cortex_M4_IPU1_C0: GEL Output: DEBUG: Configuring EVE MMU1 TLB entry 0: 0x00000005 --> 0x42000000
    Cortex_M4_IPU1_C0: GEL Output: DEBUG: Configuring EVE MMU1 TLB entry 0: 0x00000006 --> 0x4A000000
    Cortex_M4_IPU1_C0: GEL Output: DEBUG: Configuring EVE MMU1 TLB entry 0: 0x0000001F --> 0x54000000
    Cortex_M4_IPU1_C0: GEL Output: DEBUG: EVE0 MMU0 configured as per VisionSDK requirements!!!!
    Cortex_M4_IPU1_C0: GEL Output: DEBUG: MMU0 configured for EVE0
    Cortex_M4_IPU1_C0: GEL Output: --->>> EVESS Initialization is DONE! <<<---
    CS_DAP_DebugSS: GEL Output: --->>> TURNING ON L3_INSTR and L3_3 clocks required for debug instrumentation <<<<<<----
    CS_DAP_DebugSS: GEL Output: ---<<< L3 instrumentation clocks are enabled >>>> ---
    ARP32_EVE_1: Trouble Determining Current Execution Packet(s): (Error -2138 @ 0x0) Unable to determine device revision. Reset the device, and retry the operation. If error persists, confirm configuration, power-cycle the board, and/or try more reliable JTAG settings (e.g. lower TCLK). (Emulation package 7.0.100.0)
    ARP32_EVE_1: GEL Output: --->>> Resetting ARP32 ... <<<---
    Cortex_M4_IPU1_C0: GEL Output: --->>> A device reset occurred <<<---
    Cortex_M4_IPU1_C0: GEL Output: ==================================================
    Cortex_M4_IPU1_C0: GEL Output: ========= TDA3xx PG3.0 device detected =========
    Cortex_M4_IPU1_C0: GEL Output: ========= TDA3xx GP Device detected ===========
    Cortex_M4_IPU1_C0: GEL Output: ========= TDA3xx 15x15 Device detected ===========
    Cortex_M4_IPU1_C0: GEL Output: ==================================================
    Cortex_M4_IPU1_C0: GEL Output: Core Reset has occurred.
  • Hi,

    Can you share the launch_visionsdk_tda3xx.js file you are using.

    Regards,
    Rishabh
  • Hi Rishabh Garg

    This is the launch_visionsdk_tda3xx.js

    //
    //File Name: launch_visionsdk.js
    //Description:
    // Add entries in CCS menu to do common activities
    //
    //Usage:
    //From Command Window without CCS
    // 1. Open a command window
    // 2. cd <ccs_install_dir>\csv5\ccs_base\scripting\bin
    // 3. dss.bat <location_of_script>\launch_visionsdk_tda3xx.js
    //
    //From CCS Scripting console
    // 1. loadJSFile "C:\\ti\\launch_visionsdk_tda3xx.js"
    // <Ignore the error observed on the CCS scripting console
    // "Wrapped java.io.IOException: The handle is invalid (<location_of_script>\
    // launch_visionsdk.js#93)">
    //
    //Note:
    // 1. Search for "edit this" to look at changes that need to be edited
    // for your usage.
    //

    // Import the DSS packages into our namespace to save on typing
    importPackage(Packages.com.ti.debug.engine.scripting)
    importPackage(Packages.com.ti.ccstudio.scripting.environment)
    importPackage(Packages.java.lang)
    importPackage(java.io);
    importPackage(java.lang);

    //Path to CCXML file
    //<edit this>
    configFilePath = "E:\\ccs7_workspace\\seed_ccs7_tda3xx_emu.ccxml";
    //<edit this>
    disableGels=0

    function updateScriptVars(printEnable)
    {
    //<edit this> <start>
    //Path to vision-sdk binaries
    baseDir = "C:\\PROCESSOR_SDK_VISION_03_02_00_00\\vision_sdk\\binaries\\apps\\tda3xx_evm_bios_all\\vision_sdk\\bin\\tda3xx-evm\\"
    releaseMode = 0;
    IPU_0_en = 1;
    IPU_1_en = 1;
    DSP_0_en = 1;
    DSP_1_en = 1;
    EVE_0_en = 1;
    testsuite = 0;
    runAfterLoad = 0;
    //<edit this> <end>

    if(releaseMode)
    {
    IPU_0_exe = "vision_sdk_ipu1_0_release.xem4"
    IPU_1_exe = "vision_sdk_ipu1_1_release.xem4"
    DSP_0_exe = "vision_sdk_c66xdsp_1_release.xe66"
    DSP_1_exe = "vision_sdk_c66xdsp_2_release.xe66"
    EVE_0_exe = "vision_sdk_arp32_1_release.xearp32F"
    }
    else
    {
    IPU_0_exe = "vision_sdk_ipu1_0_debug.xem4"
    IPU_1_exe = "vision_sdk_ipu1_1_debug.xem4"
    DSP_0_exe = "vision_sdk_c66xdsp_1_debug.xe66"
    DSP_1_exe = "vision_sdk_c66xdsp_2_debug.xe66"
    EVE_0_exe = "vision_sdk_arp32_1_debug.xearp32F"
    }

    if (testsuite == 1)
    {
    if(releaseMode == 1)
    {
    IPU_0_exe = "vision_sdk_ipu1_0_release_testsuite.xem4";
    }
    else
    {
    IPU_0_exe = "vision_sdk_ipu1_0_debug_testsuite.xem4";
    }
    }

    //Open a debug session
    dsIPU_0 = debugServer.openSession( ".*Cortex_M4_IPU1_C0" );
    dsIPU_1 = debugServer.openSession( ".*Cortex_M4_IPU1_C1" );
    dsDSP_0 = debugServer.openSession( ".*C66xx_DSP1" );
    dsDSP_1 = debugServer.openSession( ".*C66xx_DSP2" );
    dsEVE_0 = debugServer.openSession( ".*ARP32_EVE_1" );

    if(printEnable == "1")
    {
    print("\nCores Enabled:");
    if(IPU_0_en) print("IPU1_0 is enabled!");
    if(IPU_1_en) print("IPU1_1 is enabled!");
    if(DSP_0_en) print("DSP_0 is enabled!");
    if(DSP_1_en) print("DSP_1 is enabled!");
    if(EVE_0_en) print("EVE_0 is enabled!");
    }
    }

    function printVars()
    {
    updateScriptVars("1");
    }

    function connectTargets()
    {
    updateScriptVars("0");

    // Connect targets
    print("Connecting to IPU1_0!");
    dsIPU_0.target.connect();
    if(!disableGels)
    {
    script.setScriptTimeout(2000);
    print("Executing Gels");
    try
    {
    dsIPU_0.expression.evaluate("DSP1SSClkEnable_API()");
    }
    catch(e)
    {
    print("Some error in GEL execution for DSP_0");
    }
    try
    {
    dsIPU_0.expression.evaluate("DSP2SSClkEnable_API()");
    }
    catch(e)
    {
    print("Some error in GEL execution for DSP_1");
    }
    try
    {
    dsIPU_0.expression.evaluate("EVESSClkEnable_API()");
    }
    catch(e)
    {
    print("Some error in GEL execution for EVE");
    }
    script.setScriptTimeout(-1);
    }

    print("Connecting to IPU1_1!");
    dsIPU_1.target.connect();

    print("Connecting to DSP_0!");
    dsDSP_0.target.connect();
    print("Connecting to DSP_1!");
    dsDSP_1.target.connect();
    print("Connecting to EVE_0!");
    dsEVE_0.target.connect();
    }

    function disconnectTargets()
    {
    updateScriptVars("0");

    // Connect targets
    dsIPU_0.target.disconnect();
    dsIPU_1.target.disconnect();
    dsDSP_0.target.disconnect();
    dsDSP_1.target.disconnect();
    dsEVE_0.target.disconnect();
    }

    function loadTargets_IPU_0() { updateScriptVars("0"); dsIPU_0.target.connect(); if(IPU_0_en) dsIPU_0.memory.loadProgram( baseDir + IPU_0_exe ); }
    function loadTargets_IPU_1() { updateScriptVars("0"); dsIPU_1.target.connect(); if(IPU_1_en) dsIPU_1.memory.loadProgram( baseDir + IPU_1_exe ); }
    function loadTargets_DSP_0() { updateScriptVars("0"); dsDSP_0.target.connect(); if(DSP_0_en) dsDSP_0.memory.loadProgram( baseDir + DSP_0_exe ); }
    function loadTargets_DSP_1() { updateScriptVars("0"); dsDSP_1.target.connect(); if(DSP_1_en) dsDSP_1.memory.loadProgram( baseDir + DSP_1_exe ); }
    function loadTargets_EVE_0() { updateScriptVars("0"); dsEVE_0.target.connect(); if(EVE_0_en) dsEVE_0.memory.loadProgram( baseDir + EVE_0_exe ); }


    function loadTargets()
    {
    updateScriptVars("0");

    // Load the program
    try
    {
    print("Loading IPU_0_exe!");
    loadTargets_IPU_0();
    print("Loading IPU_1_exe!");
    loadTargets_IPU_1();
    print("Loading DSP_0_exe!");
    loadTargets_DSP_0();
    print("Loading DSP_1_exe!");
    loadTargets_DSP_1();
    print("Loading EVE_0_exe!");
    loadTargets_EVE_0();
    }
    catch (e)
    {
    print("Problems while loading!");
    }
    }

    function loadSymbols_IPU_0() { updateScriptVars("0"); dsIPU_0.target.connect(); if(IPU_0_en) dsIPU_0.symbol.load( baseDir + IPU_0_exe ); }
    function loadSymbols_IPU_1() { updateScriptVars("0"); dsIPU_1.target.connect(); if(IPU_1_en) dsIPU_1.symbol.load( baseDir + IPU_1_exe ); }
    function loadSymbols_DSP_0() { updateScriptVars("0"); dsDSP_0.target.connect(); if(DSP_0_en) dsDSP_0.symbol.load( baseDir + DSP_0_exe ); }
    function loadSymbols_DSP_1() { updateScriptVars("0"); dsDSP_1.target.connect(); if(DSP_1_en) dsDSP_1.symbol.load( baseDir + DSP_1_exe ); }
    function loadSymbols_EVE_0() { updateScriptVars("0"); dsEVE_0.target.connect(); if(EVE_0_en) dsEVE_0.symbol.load( baseDir + EVE_0_exe ); }

    function loadSymbolsTargets()
    {
    updateScriptVars("0");

    // Load the program
    loadSymbols_IPU_0();
    loadSymbols_IPU_1();
    loadSymbols_DSP_0();
    loadSymbols_DSP_1();
    loadSymbols_EVE_0();
    }

    function resetTargets()
    {
    updateScriptVars("0");

    // Run the program
    if(dsIPU_0.target.isConnected()) dsIPU_0.target.reset();
    if(dsIPU_1.target.isConnected()) dsIPU_1.target.reset();
    if(dsDSP_0.target.isConnected()) dsDSP_0.target.reset();
    if(dsDSP_1.target.isConnected()) dsDSP_1.target.reset();
    if(dsEVE_0.target.isConnected()) dsEVE_0.target.reset();
    }

    function restartTargets()
    {
    updateScriptVars("0");

    // Run the program
    if(IPU_0_en) dsIPU_0.target.restart();
    if(IPU_1_en) dsIPU_1.target.restart();
    if(DSP_0_en) dsDSP_0.target.restart();
    if(DSP_1_en) dsDSP_1.target.restart();
    if(EVE_0_en) dsEVE_0.target.restart();
    }

    function runTargets()
    {
    updateScriptVars("0");

    // Run the program
    if(IPU_0_en) dsIPU_0.target.runAsynch();
    if(IPU_1_en) dsIPU_1.target.runAsynch();
    if(DSP_0_en) dsDSP_0.target.runAsynch();
    if(DSP_1_en) dsDSP_1.target.runAsynch();
    if(EVE_0_en) dsEVE_0.target.runAsynch();
    }

    function haltTargets()
    {
    updateScriptVars("0");
    script.setScriptTimeout(5000);

    try
    {
    // Run the program
    if(dsIPU_0.target.isConnected()) dsIPU_0.target.halt();
    if(dsIPU_1.target.isConnected()) dsIPU_1.target.halt();
    if(dsDSP_0.target.isConnected()) dsDSP_0.target.halt();
    if(dsDSP_1.target.isConnected()) dsDSP_1.target.halt();
    if(dsEVE_0.target.isConnected()) dsEVE_0.target.halt();
    }
    catch (e)
    {
    print("Problems while halting!");
    }
    script.setScriptTimeout(-1);
    }

    function doEverything()
    {
    printVars();
    haltTargets();
    connectTargets();
    resetTargets();
    loadTargets();
    if(runAfterLoad == 1)
    {
    runTargets();
    }
    }

    var ds;
    var debugServer;
    var script;

    // Check to see if running from within CCSv4 Scripting Console
    var withinCCS = (ds !== undefined);

    // Create scripting environment and get debug server if running standalone
    if (!withinCCS)
    {
    // Import the DSS packages into our namespace to save on typing
    importPackage(Packages.com.ti.debug.engine.scripting);
    importPackage(Packages.com.ti.ccstudio.scripting.environment);
    importPackage(Packages.java.lang);

    // Create our scripting environment object - which is the main entry point into any script and
    // the factory for creating other Scriptable ervers and Sessions
    script = ScriptingEnvironment.instance();

    // Get the Debug Server and start a Debug Session
    debugServer = script.getServer("DebugServer.1");
    }
    else // otherwise leverage existing scripting environment and debug server
    {
    debugServer = ds;
    script = env;
    }

    debugServer.setConfig(configFilePath);

    if (!withinCCS)
    {
    doEverything();
    System.out.println("Press Any key to stop...");
    var reader = new BufferedReader( new InputStreamReader(System['in']) );
    reader.readLine();

    System.out.println("End of application. Exiting");

    dsIPU_0.terminate();
    dsIPU_1.terminate();
    dsDSP_0.terminate();
    dsDSP_1.terminate();
    dsEVE_0.terminate();

    debugServer.stop();
    }

    if (withinCCS)
    {
    dsIPU_0 = debugServer.openSession( ".*Cortex_M4_IPU1_C0" );
    print("Look for new menu under Scripts for IPU1_0!");
    if(disableGels) dsIPU_0.expression.evaluate("GEL_UnloadAllGels()");

    hotmenu.remove("VSDK/Do everything");
    hotmenu.remove("VSDK/Connect targets");
    hotmenu.remove("VSDK/Disconnect targets");
    hotmenu.remove("VSDK/Reset targets");
    hotmenu.remove("VSDK/Restart targets");
    hotmenu.remove("VSDK/Load targets");
    hotmenu.remove("VSDK/Run targets");
    hotmenu.remove("VSDK/Halt targets");

    hotmenu.remove("VSDK/Load symbols/All");
    hotmenu.remove("VSDK/Load symbols/A15_0");
    hotmenu.remove("VSDK/Load symbols/IPU1_0");
    hotmenu.remove("VSDK/Load symbols/IPU1_1");
    hotmenu.remove("VSDK/Load symbols/DSP_0");
    hotmenu.remove("VSDK/Load symbols/DSP_1");
    hotmenu.remove("VSDK/Load symbols/EVE_0");
    hotmenu.remove("VSDK/Load symbols/EVE_1");
    hotmenu.remove("VSDK/Load symbols/EVE_2");
    hotmenu.remove("VSDK/Load symbols/EVE_3");

    hotmenu.remove("VSDK/Load targets/All");
    hotmenu.remove("VSDK/Load targets/A15_0");
    hotmenu.remove("VSDK/Load targets/IPU1_0");
    hotmenu.remove("VSDK/Load targets/IPU1_1");
    hotmenu.remove("VSDK/Load targets/DSP_0");
    hotmenu.remove("VSDK/Load targets/DSP_1");
    hotmenu.remove("VSDK/Load targets/EVE_0");
    hotmenu.remove("VSDK/Load targets/EVE_1");
    hotmenu.remove("VSDK/Load targets/EVE_2");
    hotmenu.remove("VSDK/Load targets/EVE_3");

    hotmenu.remove("VSDK/Print script variables");

    hotmenu.addJSFunction("VSDK/Do everything", "doEverything()");
    hotmenu.addJSFunction("VSDK/Connect targets", "connectTargets()");
    hotmenu.addJSFunction("VSDK/Disconnect targets", "disconnectTargets()");
    hotmenu.addJSFunction("VSDK/Reset targets", "resetTargets()");
    hotmenu.addJSFunction("VSDK/Restart targets", "restartTargets()");
    hotmenu.addJSFunction("VSDK/Load targets", "loadTargets()");
    hotmenu.addJSFunction("VSDK/Run targets", "runTargets()");
    hotmenu.addJSFunction("VSDK/Halt targets", "haltTargets()");

    hotmenu.addJSFunction("VSDK/Load symbols/All", "loadSymbolsTargets()");
    hotmenu.addJSFunction("VSDK/Load symbols/IPU_0", "loadSymbols_IPU_0()");
    hotmenu.addJSFunction("VSDK/Load symbols/IPU_1", "loadSymbols_IPU_1()");
    hotmenu.addJSFunction("VSDK/Load symbols/DSP_0", "loadSymbols_DSP_0()");
    hotmenu.addJSFunction("VSDK/Load symbols/DSP_1", "loadSymbols_DSP_1()");
    hotmenu.addJSFunction("VSDK/Load symbols/EVE_0", "loadSymbols_EVE_0()");

    hotmenu.addJSFunction("VSDK/Load targets/All", "loadTargets()");
    hotmenu.addJSFunction("VSDK/Load targets/IPU_0", "loadTargets_IPU_0()");
    hotmenu.addJSFunction("VSDK/Load targets/IPU_1", "loadTargets_IPU_1()");
    hotmenu.addJSFunction("VSDK/Load targets/DSP_0", "loadTargets_DSP_0()");
    hotmenu.addJSFunction("VSDK/Load targets/DSP_1", "loadTargets_DSP_1()");
    hotmenu.addJSFunction("VSDK/Load targets/EVE_0", "loadTargets_EVE_0()");

    hotmenu.addJSFunction("VSDK/Print script variables", "printVars()");
    }
  • Hi,

    Can you attach the file using "Insert Code, Attach Files and more..." button on the right corner.

    Regards,
    Rishabh
  • loadX.txt
    //
    //File Name: launch_visionsdk.js
    //Description:
    //   Add entries in CCS menu to do common activities
    //
    //Usage:
    //From Command Window without CCS
    //  1. Open a command window
    //  2. cd <ccs_install_dir>\csv5\ccs_base\scripting\bin
    //  3. dss.bat <location_of_script>\launch_visionsdk_tda3xx.js
    //
    //From CCS Scripting console
    //  1. loadJSFile "C:\\ti\\launch_visionsdk_tda3xx.js"
    //     <Ignore the error observed on the CCS scripting console
    //     "Wrapped java.io.IOException: The handle is invalid (<location_of_script>\
    //     launch_visionsdk.js#93)">
    //
    //Note:
    //  1. Search for "edit this" to look at changes that need to be edited
    //     for your usage.
    //
    
    // Import the DSS packages into our namespace to save on typing
    importPackage(Packages.com.ti.debug.engine.scripting)
    importPackage(Packages.com.ti.ccstudio.scripting.environment)
    importPackage(Packages.java.lang)
    importPackage(java.io);
    importPackage(java.lang);
    
    //Path to CCXML file
    //<edit this>
    configFilePath = "E:\\ccs7_workspace\\seed_ccs7_tda3xx_emu.ccxml";
    //<edit this>
    disableGels=0
    
    function updateScriptVars(printEnable)
    {
     //<edit this> <start>
        //Path to vision-sdk binaries
        baseDir = "C:\\PROCESSOR_SDK_VISION_03_02_00_00\\vision_sdk\\binaries\\apps\\tda3xx_evm_bios_all\\vision_sdk\\bin\\tda3xx-evm\\"
        releaseMode = 0;
        IPU_0_en = 1;
        IPU_1_en = 1;
        DSP_0_en = 1;
        DSP_1_en = 1;
        EVE_0_en = 1;
        testsuite = 0;
        runAfterLoad = 0;
     //<edit this> <end>
    
        if(releaseMode)
        {
            IPU_0_exe = "vision_sdk_ipu1_0_release.xem4"
            IPU_1_exe = "vision_sdk_ipu1_1_release.xem4"
            DSP_0_exe = "vision_sdk_c66xdsp_1_release.xe66"
            DSP_1_exe = "vision_sdk_c66xdsp_2_release.xe66"
            EVE_0_exe = "vision_sdk_arp32_1_release.xearp32F"
        }
        else
        {
            IPU_0_exe = "vision_sdk_ipu1_0_debug.xem4"
            IPU_1_exe = "vision_sdk_ipu1_1_debug.xem4"
            DSP_0_exe = "vision_sdk_c66xdsp_1_debug.xe66"
            DSP_1_exe = "vision_sdk_c66xdsp_2_debug.xe66"
            EVE_0_exe = "vision_sdk_arp32_1_debug.xearp32F"
        }
    
    	if (testsuite == 1)
    	{
    	   if(releaseMode == 1)
    	   {
    	       IPU_0_exe = "vision_sdk_ipu1_0_release_testsuite.xem4";
    	   }
    	   else
    	   {
               IPU_0_exe = "vision_sdk_ipu1_0_debug_testsuite.xem4";
    	   }
    	}
    
        //Open a debug session
        dsIPU_0 = debugServer.openSession( ".*Cortex_M4_IPU1_C0" );
        dsIPU_1 = debugServer.openSession( ".*Cortex_M4_IPU1_C1" );
        dsDSP_0 = debugServer.openSession( ".*C66xx_DSP1" );
        dsDSP_1 = debugServer.openSession( ".*C66xx_DSP2" );
        dsEVE_0 = debugServer.openSession( ".*ARP32_EVE_1" );
    
        if(printEnable == "1")
        {
            print("\nCores Enabled:");
            if(IPU_0_en) print("IPU1_0 is enabled!");
            if(IPU_1_en) print("IPU1_1 is enabled!");
            if(DSP_0_en) print("DSP_0 is enabled!");
            if(DSP_1_en) print("DSP_1 is enabled!");
            if(EVE_0_en) print("EVE_0 is enabled!");
        }
    }
    
    function printVars()
    {
        updateScriptVars("1");
    }
    
    function connectTargets()
    {
        updateScriptVars("0");
    
        // Connect targets
        print("Connecting to IPU1_0!");
        dsIPU_0.target.connect();
        if(!disableGels)
        {
            script.setScriptTimeout(2000);
            print("Executing Gels");
            try
            {
                dsIPU_0.expression.evaluate("DSP1SSClkEnable_API()");
            }
            catch(e)
            {
                print("Some error in GEL execution for DSP_0");
            }
            try
            {
                dsIPU_0.expression.evaluate("DSP2SSClkEnable_API()");
            }
            catch(e)
            {
                print("Some error in GEL execution for DSP_1");
            }
            try
            {
                dsIPU_0.expression.evaluate("EVESSClkEnable_API()");
            }
            catch(e)
            {
                print("Some error in GEL execution for EVE");
            }
            script.setScriptTimeout(-1);
        }
    
        print("Connecting to IPU1_1!");
        dsIPU_1.target.connect();
    
        print("Connecting to DSP_0!");
        dsDSP_0.target.connect();
        print("Connecting to DSP_1!");
        dsDSP_1.target.connect();
        print("Connecting to EVE_0!");
        dsEVE_0.target.connect();
    }
    
    function disconnectTargets()
    {
        updateScriptVars("0");
    
        // Connect targets
        dsIPU_0.target.disconnect();
        dsIPU_1.target.disconnect();
        dsDSP_0.target.disconnect();
        dsDSP_1.target.disconnect();
        dsEVE_0.target.disconnect();
    }
    
    function loadTargets_IPU_0() { updateScriptVars("0"); dsIPU_0.target.connect(); if(IPU_0_en) dsIPU_0.memory.loadProgram( baseDir + IPU_0_exe ); }
    function loadTargets_IPU_1() { updateScriptVars("0"); dsIPU_1.target.connect(); if(IPU_1_en) dsIPU_1.memory.loadProgram( baseDir + IPU_1_exe ); }
    function loadTargets_DSP_0() { updateScriptVars("0"); dsDSP_0.target.connect(); if(DSP_0_en) dsDSP_0.memory.loadProgram( baseDir + DSP_0_exe ); }
    function loadTargets_DSP_1() { updateScriptVars("0"); dsDSP_1.target.connect(); if(DSP_1_en) dsDSP_1.memory.loadProgram( baseDir + DSP_1_exe ); }
    function loadTargets_EVE_0() { updateScriptVars("0"); dsEVE_0.target.connect(); if(EVE_0_en) dsEVE_0.memory.loadProgram( baseDir + EVE_0_exe ); }
    
    
    function loadTargets()
    {
        updateScriptVars("0");
    
        // Load the program
    	try
    	{
            print("Loading IPU_0_exe!");
            loadTargets_IPU_0();
            print("Loading IPU_1_exe!");
            loadTargets_IPU_1();
            print("Loading DSP_0_exe!");
            loadTargets_DSP_0();
            print("Loading DSP_1_exe!");
            loadTargets_DSP_1();
            print("Loading EVE_0_exe!");
            loadTargets_EVE_0();
        }
        catch (e)
        {
            print("Problems while loading!");
        }
    }
    
    function loadSymbols_IPU_0() { updateScriptVars("0"); dsIPU_0.target.connect(); if(IPU_0_en) dsIPU_0.symbol.load( baseDir + IPU_0_exe ); }
    function loadSymbols_IPU_1() { updateScriptVars("0"); dsIPU_1.target.connect(); if(IPU_1_en) dsIPU_1.symbol.load( baseDir + IPU_1_exe ); }
    function loadSymbols_DSP_0() { updateScriptVars("0"); dsDSP_0.target.connect(); if(DSP_0_en) dsDSP_0.symbol.load( baseDir + DSP_0_exe ); }
    function loadSymbols_DSP_1() { updateScriptVars("0"); dsDSP_1.target.connect(); if(DSP_1_en) dsDSP_1.symbol.load( baseDir + DSP_1_exe ); }
    function loadSymbols_EVE_0() { updateScriptVars("0"); dsEVE_0.target.connect(); if(EVE_0_en) dsEVE_0.symbol.load( baseDir + EVE_0_exe ); }
    
    function loadSymbolsTargets()
    {
        updateScriptVars("0");
    
        // Load the program
        loadSymbols_IPU_0();
        loadSymbols_IPU_1();
        loadSymbols_DSP_0();
        loadSymbols_DSP_1();
        loadSymbols_EVE_0();
    }
    
    function resetTargets()
    {
        updateScriptVars("0");
    
        // Run the program
        if(dsIPU_0.target.isConnected()) dsIPU_0.target.reset();
        if(dsIPU_1.target.isConnected()) dsIPU_1.target.reset();
        if(dsDSP_0.target.isConnected()) dsDSP_0.target.reset();
        if(dsDSP_1.target.isConnected()) dsDSP_1.target.reset();
        if(dsEVE_0.target.isConnected()) dsEVE_0.target.reset();
    }
    
    function restartTargets()
    {
        updateScriptVars("0");
    
        // Run the program
        if(IPU_0_en) dsIPU_0.target.restart();
        if(IPU_1_en) dsIPU_1.target.restart();
        if(DSP_0_en) dsDSP_0.target.restart();
        if(DSP_1_en) dsDSP_1.target.restart();
        if(EVE_0_en) dsEVE_0.target.restart();
    }
    
    function runTargets()
    {
        updateScriptVars("0");
    
        // Run the program
        if(IPU_0_en) dsIPU_0.target.runAsynch();
        if(IPU_1_en) dsIPU_1.target.runAsynch();
        if(DSP_0_en) dsDSP_0.target.runAsynch();
        if(DSP_1_en) dsDSP_1.target.runAsynch();
        if(EVE_0_en) dsEVE_0.target.runAsynch();
    }
    
    function haltTargets()
    {
        updateScriptVars("0");
        script.setScriptTimeout(5000);
    
    	try
    	{
            // Run the program
            if(dsIPU_0.target.isConnected()) dsIPU_0.target.halt();
            if(dsIPU_1.target.isConnected()) dsIPU_1.target.halt();
            if(dsDSP_0.target.isConnected()) dsDSP_0.target.halt();
            if(dsDSP_1.target.isConnected()) dsDSP_1.target.halt();
            if(dsEVE_0.target.isConnected()) dsEVE_0.target.halt();
        }
        catch (e)
        {
            print("Problems while halting!");
        }
        script.setScriptTimeout(-1);
    }
    
    function doEverything()
    {
        printVars();
        haltTargets();
        connectTargets();
        resetTargets();
        loadTargets();
        if(runAfterLoad == 1)
        {
            runTargets();
        }
    }
    
    var ds;
    var debugServer;
    var script;
    
    // Check to see if running from within CCSv4 Scripting Console
    var withinCCS = (ds !== undefined);
    
    // Create scripting environment and get debug server if running standalone
    if (!withinCCS)
    {
        // Import the DSS packages into our namespace to save on typing
        importPackage(Packages.com.ti.debug.engine.scripting);
        importPackage(Packages.com.ti.ccstudio.scripting.environment);
        importPackage(Packages.java.lang);
    
        // Create our scripting environment object - which is the main entry point into any script and
        // the factory for creating other Scriptable ervers and Sessions
        script = ScriptingEnvironment.instance();
    
        // Get the Debug Server and start a Debug Session
        debugServer = script.getServer("DebugServer.1");
    }
    else // otherwise leverage existing scripting environment and debug server
    {
        debugServer = ds;
        script = env;
    }
    
    debugServer.setConfig(configFilePath);
    
    if (!withinCCS)
    {
        doEverything();
        System.out.println("Press Any key to stop...");
        var reader = new BufferedReader( new InputStreamReader(System['in']) );
        reader.readLine();
    
        System.out.println("End of application. Exiting");
    
        dsIPU_0.terminate();
        dsIPU_1.terminate();
        dsDSP_0.terminate();
        dsDSP_1.terminate();
        dsEVE_0.terminate();
    
        debugServer.stop();
    }
    
    if (withinCCS)
    {
        dsIPU_0 = debugServer.openSession( ".*Cortex_M4_IPU1_C0" );
        print("Look for new menu under Scripts for IPU1_0!");
        if(disableGels) dsIPU_0.expression.evaluate("GEL_UnloadAllGels()");
    
        hotmenu.remove("VSDK/Do everything");
        hotmenu.remove("VSDK/Connect targets");
        hotmenu.remove("VSDK/Disconnect targets");
        hotmenu.remove("VSDK/Reset targets");
        hotmenu.remove("VSDK/Restart targets");
        hotmenu.remove("VSDK/Load targets");
        hotmenu.remove("VSDK/Run targets");
        hotmenu.remove("VSDK/Halt targets");
    
        hotmenu.remove("VSDK/Load symbols/All");
        hotmenu.remove("VSDK/Load symbols/A15_0");
        hotmenu.remove("VSDK/Load symbols/IPU1_0");
        hotmenu.remove("VSDK/Load symbols/IPU1_1");
        hotmenu.remove("VSDK/Load symbols/DSP_0");
        hotmenu.remove("VSDK/Load symbols/DSP_1");
        hotmenu.remove("VSDK/Load symbols/EVE_0");
        hotmenu.remove("VSDK/Load symbols/EVE_1");
        hotmenu.remove("VSDK/Load symbols/EVE_2");
        hotmenu.remove("VSDK/Load symbols/EVE_3");
    
        hotmenu.remove("VSDK/Load targets/All");
        hotmenu.remove("VSDK/Load targets/A15_0");
        hotmenu.remove("VSDK/Load targets/IPU1_0");
        hotmenu.remove("VSDK/Load targets/IPU1_1");
        hotmenu.remove("VSDK/Load targets/DSP_0");
        hotmenu.remove("VSDK/Load targets/DSP_1");
        hotmenu.remove("VSDK/Load targets/EVE_0");
        hotmenu.remove("VSDK/Load targets/EVE_1");
        hotmenu.remove("VSDK/Load targets/EVE_2");
        hotmenu.remove("VSDK/Load targets/EVE_3");
    
        hotmenu.remove("VSDK/Print script variables");
    
        hotmenu.addJSFunction("VSDK/Do everything", "doEverything()");
        hotmenu.addJSFunction("VSDK/Connect targets", "connectTargets()");
        hotmenu.addJSFunction("VSDK/Disconnect targets", "disconnectTargets()");
        hotmenu.addJSFunction("VSDK/Reset targets", "resetTargets()");
        hotmenu.addJSFunction("VSDK/Restart targets", "restartTargets()");
        hotmenu.addJSFunction("VSDK/Load targets", "loadTargets()");
        hotmenu.addJSFunction("VSDK/Run targets", "runTargets()");
        hotmenu.addJSFunction("VSDK/Halt targets", "haltTargets()");
    
        hotmenu.addJSFunction("VSDK/Load symbols/All",   "loadSymbolsTargets()");
        hotmenu.addJSFunction("VSDK/Load symbols/IPU_0", "loadSymbols_IPU_0()");
        hotmenu.addJSFunction("VSDK/Load symbols/IPU_1", "loadSymbols_IPU_1()");
        hotmenu.addJSFunction("VSDK/Load symbols/DSP_0", "loadSymbols_DSP_0()");
        hotmenu.addJSFunction("VSDK/Load symbols/DSP_1", "loadSymbols_DSP_1()");
        hotmenu.addJSFunction("VSDK/Load symbols/EVE_0", "loadSymbols_EVE_0()");
    
        hotmenu.addJSFunction("VSDK/Load targets/All",   "loadTargets()");
        hotmenu.addJSFunction("VSDK/Load targets/IPU_0", "loadTargets_IPU_0()");
        hotmenu.addJSFunction("VSDK/Load targets/IPU_1", "loadTargets_IPU_1()");
        hotmenu.addJSFunction("VSDK/Load targets/DSP_0", "loadTargets_DSP_0()");
        hotmenu.addJSFunction("VSDK/Load targets/DSP_1", "loadTargets_DSP_1()");
        hotmenu.addJSFunction("VSDK/Load targets/EVE_0", "loadTargets_EVE_0()");
    
        hotmenu.addJSFunction("VSDK/Print script variables", "printVars()");
    }
    

  • Hi

    Not support the js format,So I upload a txt file for you!!
  • Hi,

    Script seems to be fine, no obvious issues.
    Can you set runAfterLoad=1 and see if has any effect.

    Regards,
    Rishabh
  • Hi Rishabh Garg

    I try it, The error is still the same!!
  • It stop at this time!!!!

  • Hi,

    What are the gel files that you are using.
    You should use the one given here: PROCESSOR_SDK_VISION_03_02_00_00\ti_components\ccs_csp\.
    Can you also share the TDA3xx multicore gel file.

    Regards,
    Rishabh
  • OK

    I use the file,unzip to CCS7.4 path!  But I not should it, I can replace it and try!

    0675.TDA3xx_multicore_reset.gel

  • Hi Rishabh Garg

    I compare those files, It is the same , and the data is 2017-10-10

    It work in the TDA3x_EVM, But it failed in my custom board!!!
  • Hi,

    The gel files matches with file I am using.
    And as you correctly said it is working on EVM.
    As a workaround on custom board you can modify the script file to load the cores other than EVE and load the EVE core manually.

    Regards,
    Rishabh
  • OK,

    I load all core program manually!Is there any clue to fix the custom board?
  • Hi,

    I will ask the EVE experts.

    Regards,
    Rishabh
  • Hi,

    I check with EVE experts.
    EVE reset is the only care about here.
    I think you can go ahead with manual load for EVE on custom board if the script is not working.

    Regards,
    Rishabh
  • Hi,

    I will close this thread.
    Feel free to start a new thread if you have any further questions.

    Regards,
    Rishabh