Recommended to use the new python package for scripting: https://x2cscope.github.io/pyx2cscope/
The MPLAB X plugin is not updated anymore.
Legacy MPLAB X plugin scripting summary:
X2Cscope can run scripts with the help of Java and netbeans platform. It supports Python 2 (Jython engine) and Javascript (Java nashorn engine).
X2Cscope plugin exports 2 interfaces:
public interface ISymbolManager
public interface IScopeManager
Before the selected script is executed, 2 variables with the type of these interfaces are getting initialised. This is for abstraction and user convinience. The two prepared objects that can be used without initialisation:
-
x2c_symbol Access to global variables directly via scripting.
-
x2c_scope Access global variables via a virtual scope and monitor them.
Examples
Script examples are included within the demo applications. See the Demos/Download page.
Python syntax highlight in MPLAB X
- Download the python package for Netbeans: http://plugins.netbeans.org/plugin/56795/python4netbeans802
- Install the org-netbeans-modules-python-editor.nbm from the package.
- Tools–>Plugins–>Downloaded–>Add Plugin..
- Install
- Restart MPLAB X