Tool/software: Code Composer Studio
Hi,
Im using CCS Version: 6.1.2.00015, im having trouble in using hotmenu_addJSFunction to add menu item in the CCS IDE.
Below is my sample code:
from CCSDebuSession.js i tried to load Gel file
@CCSDebuSession.js
debugSessionM3VIDEO = debugServer.openSession(Emulator);
debugSessionM3VIDEO.target.connect();
debugSessionM3VIDEO.memory.loadProgram(Out_File);
debugSessionM3VIDEO.target.run();
debugSessionM3VIDEO.expression.evaluate('GEL_LoadGel("C:/script.gel")');
from script.gel i put the function dump and the hotmenu_addJSFunction so that i can add a menu item.
@script.gel
function dump(){
var Arrayaddr = mySession.symbol.getAddress("Var_array");
var ArraySize = mySession.expression.evaluate("sizeof(Var_array)");
mySession.memory.saveBinary(Arrayaddr, 0, ArraySize, Dump_Filetxt);
}
hotmenu_addJSFunction("Dump/StartDump", "dump()");
IDE Error/Issue
GEL: Error loading file
line 1: expecting LeftParen, found 'dump'
unexpected token: "Dump/StartDump"
unexpected token: "dump()"
Can somebody give advice if how to correctly use the hotmenu_addJSFunction.
Thanks!
Jessie