Skip to main content
Paul Hankins
Associate
July 27, 2019
Question

With Windows 10 I installed openjdk version 1.8.0_222 but STM32CubeMX does not see that openjdk is there. Says it can not find java runtime environment. The readme with STM32CubeMX said openjdk would work.

  • July 27, 2019
  • 5 replies
  • 3567 views

After Oracle announcement related to ‘End of Public Updates for Oracle JDK 8’, you can access OpenJDK 8 via https://adoptopenjdk.net/. But it will not

This topic has been closed for replies.

5 replies

Pascal Rosin
Associate II
January 30, 2020

Same for me, I installed the OpenJDK 8 JRE. The output of `java -version` is the following:

C:\>java -version
openjdk version "1.8.0_242"
OpenJDK Runtime Environment (AdoptOpenJDK)(build 1.8.0_242-b08)
OpenJDK 64-Bit Server VM (AdoptOpenJDK)(build 25.242-b08, mixed mode)

The Installation program of STM32CubeMX-5.5.0 opens a window with the message "This application requires a Java Runtime Environment 1.8.0_45". The installation does not continue.

Victor Gomes
Visitor II
January 31, 2020

I had a similar problem, but STM32CubeMX was already installed in my machine. I couldn't use the software after I removed Oracle JRE in favor of OpenJDK. The message was the same as yours: "This application requires a Java Runtime Environment 1.8.0_45".

However, after a lot of searching, I saw someone running an executable directly with java (I don't recall whether it was the setup file or the actual software executable). So, I opened a cmd at my installation directory and executed:

java -jar STM32CubeMX.exe

And it worked. After that, I edited my shortcut in desktop to use `java -jar` as well.

I suggest you try the same with the setup file.

By the way, I'm using OpenJDK 13.0.1 and it seems to work fine.

Pascal Rosin
Associate II
February 5, 2020

Interesting, I tried to install CubeMX with an Oracle Java installation, after uninstalling this and installing the AdoptOpenJDK, I tried to run it from the command line, but it was not working. After installing CubeMX with

java -jar SetupSTM32CubeMX-5.5.0.exe

from an administrator command line, I can now start CubeMX from the start menu without even changing the shortcut.

Sadly this does not work for the STM32CubeProgrammer.

Associate
May 14, 2020

To easily fix this, install AdoptOpenJDK with the following settings:0693W000001cFYDQA2.png

shadab abedin
Associate II
August 26, 2020

thanks @Community member​  lastly it work after installation of adoptOpenJDK.Thanks Alot