Voltage Module Designer requires the Java Development Kit (JDK) version 8 or above. Voltage Modular currently supports the Java 11 instruction set, but don't worry: newer versions of the Java Development Kit will compile code that's compatible with Java 11 when used with Voltage Module Designer.
There are two popular versions of the JDK available, the Oracle JDK and the OpenJDK. The Oracle JDK is free for personal use, but requires a commercial license for commercial use. The open-source OpenJDK is free for both personal and commercial use. As a result, we recommend installing the free OpenJDK.
The current general release version of the OpenJDK is JDK 13. You can download the OpenJDK 13 Development Kit here:
Be sure to download and install the correct JDK version for your computer. “macOS” and “Windows x64” will be the most common downloads.
The OpenJDK downloads as a zip file. Inside the zip file is a folder with a name similar to "jdk-13.0.1". You will want to copy this folder in its entirety to the folder %ProgramFiles%\Java\. For most users, this will be C:\Program Files\Java.
You will need to modify your Path to point to the Java JDK’s bin folder. Please see Oracle's Documentation for instructions. You’ll want to add something like
C:\Program Files\Java\jdk-13.0.1\bin to your Path environment variable.
In addition, the Java Development Kit on Windows typically requires you to set the JAVA_HOME environment variable. Right click My Computer and select Properties. On the Advanced tab, select Environment Variables, and then edit JAVA_HOME to point to where the JDK software is located, for example, C:\Program Files\Java\jdk-13.0.1.
The OpenJDK downloads as a tar.gz file. Inside the tar.gz file is a folder with a name similar to "jdk-13.0.1.jdk". You will want to move this folder in its entirety to the folder /Library/Java/JavaVirtualMachines. (Note: moving the folder to this location will require that you to enter an administrator password.)
Verifying the Installation
Once you’ve run the JDK installer, open a Command Prompt in Windows or a Terminal on OSX, and type in the following command:
You should see something like this in response:
Be sure the version shown is the version that you installed. If the java or javac commands cannot be found, there may be an issue with your installation. If you’re using Windows, you probably forget to add the Java folder to your system path. See the link above for instructions.
Please note: If you have JDK version 12 or newer installed, be careful not to use any JDK12+ commands in your Java module, because they won’t compile or work in Voltage Modular's Java 11 virtual machine.
If your Java version is correct, and you’ve installed the Voltage Module Designer, then you’re done! Let’s start building modules!