Please enable JavaScript to view this site.

winIDEA Help

Version: 9.21.241

Navigation: EVE scripts

Scroll Prev Top Next More

Running EVE scripts

In this topic:

Refer to EVE Script User's Guide for more information on how to build and run EVE Scripts.

EVE Hello World

EVE script Call Points

Running EVE scripts

Shortcut for running EVE scripts

 

Embedded Virtual Engine (EVE) is our approach to customization of debug actions in winIDEA.

 

EVE scripts use cases differ from Python scripts which are used for the high-level control of winIDEA and configuration setup. EVE is a small execution engine that was designed to be placed at any level of winIDEA software and execute short programs of calls to available (i.e. registered) callbacks at a certain level.

 

i-icon

Refer to EVE Script User's Guide for more information on how to build and run EVE Scripts.

 

 

EVE Hello World

EVE scripts are written in C (C++). Following is a Hello World example:

 

#define SCRIPT_FOR_CALL_PT_DEFAULT
#include "ExtPoints.h"
#include "isysEveArgs.h"
 
/**
* Just say hello
*/
struct SEVEHelloWorld : public SEVEScriptBase
{
void Execute() override
 {
   m_log.LOGI("*** EVE script STARTED ***");
  bool bResult = true;
   m_log.LOGI("Hello");
   m_host.setRetValue32(RVI_EXIT_CODE, bResult ? 0 : 1);
   m_host.setRetString(RVS_EXIT_INFO, bResult ? "All OK" : "Error in script execution");
   m_log.LOGI("EVE script FINISHED\n");
 }
} g_EVEScript;

 

 

EVE script Call Points

There are several points in time when a custom EVE script is (or can be) called. These are referred to as call points. Most of them are predefined e.g. start of debug session, start of trace etc. This note focuses on the dry EVE script execution (CALL_PT_DEFAULT). It is achieved through isystem.connect service call.

Available callbacks in EVE script depend on which execution host the EVE script is run. Currently an EVE script can only be run in the SoC object context (EXT_PT_SoCWI) where SoC related callbacks can be made, e.g. debug signal control, JTAG scan, memory access, core debug register access etc. Execution host is determined by isystem.connect service call URL and is meant for future extensions.

 

 

Running EVE scripts

Dedicated  isystem.connect service also handles the EVE script compilation and can be limited to it. For details on various calls of said service see the following Python script from winIDEA installation dir subfolder EVE/Tools named runEveScript.py.

Python script can be called with an EVE script path as an only parameter to run an EVE script example on SoC execution host:

 

python runEveScript.py EVEHelloWorld.cpp

 

Running the script produces the following output in the Progress window:

EVEHelloWorldOutput

 

 

Shortcut for running EVE scripts

Custom winIDEA tool can be configured to run an EVE script active in the Editor:

 

number1

Add a script via Tools / Customize / Tools / Add / Browse.

Browse to winIDEA installation directory subfolder eve/tools and select runEveScript.py. Optionally you can enter $(EXEDIR)eve\tools\runEveScript.py to the Command field.

 

EVE_CreateShortcut

 

 

number2

Open an EVE script (.cpp file) in the Editor.

 

number3

Select Tools / runEveScript.

The command will run the file that was focused last in the Editor.

 

EVE_runEVE script

 

Look for the script output in the Progress window.

Copyright © 2024 TASKING Germany GmbH