Can not launch jmav sim I need help

Hello I’m a beginner in PX4. I encountered the following problem yesterday.
When I try to launch/ run Jmav sim in Visual Studio code I received the error massage “The terminal process “/usr/bin/bash ‘-c’, ‘java -Djava.ext.dirs= -jar jmavsim_run.jar -r 250 -lockstep -tcp localhost:4560 -qgc’” terminated with exit code: 1.” I guess this error has something to do with the java installation on my computer.
Edit: My goal is to use the Software in the SITL mode.

Sincerely yours HenriH

How can I resolve this Java error while executing the make Jmavsim command in the terminal of Visual Studio Code?

make px4_sitl_default jmavsim
[0/1] cd /home/henri/PX4-Autopilot/build/px4_sitl_default/tmp && /home…e/henri/PX4-Autopilot /home/henri/PX4-Autopilot/build/px4_sitl_default
SITL ARGS
sitl_bin: /home/henri/PX4-Autopilot/build/px4_sitl_default/bin/px4
debugger: none
program: jmavsim
model: none
world: none
src_path: /home/henri/PX4-Autopilot
build_path: /home/henri/PX4-Autopilot/build/px4_sitl_default
empty model, setting iris as default
SITL COMMAND: “/home/henri/PX4-Autopilot/build/px4_sitl_default/bin/px4” “/home/henri/PX4-Autopilot/build/px4_sitl_default”/etc -s etc/init.d-posix/rcS -t “/home/henri/PX4-Autopilot”/test_data
Creating symlink /home/henri/PX4-Autopilot/build/px4_sitl_default/etc → /home/henri/PX4-Autopilot/build/px4_sitl_defau


| ___ \ \ \ / / / |
| |/ / \ V / / /| |
| __/ / \ / /
| |
| | / /^\ \ ___ |
_| / / |_/

px4 starting.

INFO [px4] Calling startup script: /bin/sh etc/init.d-posix/rcS 0
INFO [init] found model autostart file as SYS_AUTOSTART=10016
INFO [param] selected parameter default file eeprom/parameters_10016
[param] parameter file not found, creating eeprom/parameters_10016
SYS_AUTOCONFIG: curr: 0 → new: 1
SYS_AUTOSTART: curr: 0 → new: 10016
CAL_ACC0_ID: curr: 0 → new: 1310988
CAL_GYRO0_ID: curr: 0 → new: 1310988
CAL_ACC1_ID: curr: 0 → new: 1310996
CAL_GYRO1_ID: curr: 0 → new: 1310996
CAL_ACC2_ID: curr: 0 → new: 1311004
CAL_GYRO2_ID: curr: 0 → new: 1311004

  • CAL_MAG0_ID: curr: 0 → new: 197388
  • CAL_MAG1_ID: curr: 0 → new: 197644
  • SENS_BOARD_X_OFF: curr: 0.0000 → new: 0.0000
  • SENS_DPRES_OFF: curr: 0.0000 → new: 0.0010
  • SYS_AUTOCONFIG: curr: 1 → new: 0
  • IMU_INTEG_RATE: curr: 200 → new: 250
    INFO [dataman] data manager file ‘./dataman’ size is 7866640 bytes
    Buildfile: /home/henri/PX4-Autopilot/Tools/jMAVSim/build.xml
    PX4 SIM HOST: localhost
    INFO [simulator] Waiting for simulator to accept connection on TCP port 4560

make_dirs:

compile:

create_run_jar:

copy_res:

BUILD SUCCESSFUL
Total time: 0 seconds
Options parsed, starting Sim.
Starting GUI…
Exception in thread “main” java.lang.reflect.InvocationTargetException
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at org.eclipse.jdt.internal.jarinjarloader.JarRsrcLoader.main(JarRsrcLoader.java:61)
Caused by: java.lang.UnsatisfiedLinkError: Can’t load library: /usr/lib/jvm/java-11-openjdk-amd64/lib/libawt_xawt.so
at java.base/java.lang.ClassLoader.loadLibrary(ClassLoader.java:2630)
at java.base/java.lang.Runtime.load0(Runtime.java:768)
at java.base/java.lang.System.load(System.java:1837)
at java.base/java.lang.ClassLoader$NativeLibrary.load0(Native Method)
at java.base/java.lang.ClassLoader$NativeLibrary.load(ClassLoader.java:2442)
at java.base/java.lang.ClassLoader$NativeLibrary.loadLibrary(ClassLoader.java:2498)
at java.base/java.lang.ClassLoader.loadLibrary0(ClassLoader.java:2694)
at java.base/java.lang.ClassLoader.loadLibrary(ClassLoader.java:2648)
at java.base/java.lang.Runtime.loadLibrary0(Runtime.java:830)
at java.base/java.lang.System.loadLibrary(System.java:1873)
at java.desktop/java.awt.Toolkit$3.run(Toolkit.java:1399)
at java.desktop/java.awt.Toolkit$3.run(Toolkit.java:1397)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at java.desktop/java.awt.Toolkit.loadLibraries(Toolkit.java:1396)
at java.desktop/java.awt.Toolkit.(Toolkit.java:1429)
at java.desktop/java.awt.Component.(Component.java:621)
at me.drton.jmavsim.Simulator.(Simulator.java:193)
at me.drton.jmavsim.Simulator.main(Simulator.java:944)
… 5 more