Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The following presents typical issues and how to solve them.

IssueTypical Error MessagesDescriptionSolution
leJOS EV3 does not support Java 8

"java.lang.UnsupportedClassVersionError"

"unsupported major.minor version"

You compile the sources in your project with Java 8 and upload them to the brick. However the lejos EV3 does not support Java 8Go to the project properties and switch to Java 7 (Right Click on project > Properties > Java Compiler > Compiler compliance level)

Uploading to the brick does not respond


You compile a file successfully and when uploading the result, the connected brick is found. Anyway the upload does not terminate and does not react.Flash the brick with the current leJOS firmware. If the brick is recognized correctly and the attempt to upload a compiled file fails then the firmware on the brick might be outdated. If connecting via bluetooth works add -b to the uxjupload/nxj command.
Compilation and uploading works from command line but not when using KIELER

This Java instance does not support a 32-bit JVM. Please install the desired version.

You can compile and upload code to the brick using the command line tools but when using KIELER an error message apprears because Java does not support 32-bit JVM.Set the LEJOS_NXT_JAVA_HOME environment variable, such that it points to an 32-bit JDK and is visible for GUI applications (or at least KIELER). The process to do so differs on every OS. As alternative, execute KIELER from terminal.
Brick does nothing after program finished and prints "Program exit"
A program was uploaded and finished without errors. Afterwards the brick prints "Program exit" but does not open the main menu.

This is normal behaviour if uploading a program in debug mode instead run mode (Debug As instead Run As in Eclipse). To get back to the main menu, press the ENTER and ESCAPE button of the brick at the same time.

Cannot simulate but compileJavac/gcc not foundJavac and gcc have to be available in the pathAdd javac/gcc to your path
Cannot simulate but compileCannot find fileKIELER has no rights to write to the file systemUse a workspace in which KIELER has write access
LEFT and RIGHT button cannot be pressed at the same time
If you press the ENTER and LEFT button both are true, if you press the ENTER and RIGHT button both are true. If you press the LEFT and RIGHT button only the LEFT button is true.Do not write a program that requires the LEFT and RIGHT button to be presssed at the same time.
Too many variablesNo more than 255 fields expectedIf your generated Java Code uses more than 255 variables it cannot run on the NXT.Try using less super states or concurrent regions (during actions create concurrent regions).
KIELER and compilation use two different java versions

Main

has

been

compiled

by

a

more

recent

version

of

the

Java

Runtime

(class

file

version

55.0),
this

version

of

the

Java

Runtime

only

recognizes

class

file

versions

up

to

52.0


Make sure KIELER uses the same java version as the one in the path (for example Java 11). Lejos can still use java 8, if you set the LEJOS_NXT_JAVA_HOME variable (in windows this is a 32-bit java installation)
NXT program cannot be stopped in RConsole mode
You deploy a program to the NXT with RConsole enabledPress Esc (dark grey button) and Enter (organge Button) at the same time