Python or Jython?
You'll often hear Python referred to as "Jython" by advanced users of Ignition. Python is the language, Jython is the implementation of the language that we use. Most users of Python use the implementation called "CPython" - they just don't realize it. See http://en.wikipedia.org/wiki/Python_(programming_language)#Implementations.
One of the powerful things about using Jython is that your script has access to the entire Java standard library. In the Client, this will be Java 5 or above. When running under the Gateway, this will be Java 6 and above. For more information, see Accessing Java.
Many scripting users are blown away by their script's speed. We can't take credit for this - the Jython engine hot-compiles (compiles the code when it is run) your Jython code to Java bytecode, which means it runs natively in the JVM, which in turn can hot-compile it to machine code. It's fast.
Which version of Python is Used?
Ignition uses Jython 2.5. Jython is the Python programming language implemented over the Java Virtual Machine. When looking at outside documentation, such as on www.python.org, verify that you are looking at the correct version of the documentation.
Jython 2.5 allows us to use the standard functions and tools in Python 2.5, so if you want to look up something in the Python docs, make sure to use version 2.5 (https://docs.python.org/2/).
Why not VBA?
Many HMI/SCADA packages use VBA, or Visual Basic for Applications. As such, many engineers switching to our software inquire about it. There are a variety of reasons we don't use VBA:
- It is not compatible with Java, the language that Ignition is written in. This also means that it is not cross-platform.
- It is a dying language (Microsoft has phased it out as of July, 2007).
- It is full of security holes.
- It is an ugly language!