Java on ESP32

ElectricThanhTung
Posts: 1
Joined: Mon May 20, 2024 1:30 pm

Java on ESP32

Postby ElectricThanhTung » Tue Sep 17, 2024 6:41 pm

Have you ever thought or wished you could execute java code on ESP32?
Today I will share an open source project to support that and you can even debug each line of java code and see the values ​​of variables with Visual Studio Code.

Features:
+ Support execution of most java bytecode instructions.
+ Support throw and catch mechanism.
+ Support simple garbage collectors.
+ Support multi-threading.
+ Support debugging with Visual Studio Code via UART, USB CDC (may support wifi in the future):
- Pause, Continue, Restart, Step Over, Step Into, Step Out.
- Stack trace.
- Set and remove breakpoints.
- Stop on exception and display exception information.
- View local variables and evaluate expressions.
- Display message printed from java code.
[Watch demo video on youtube]
Image

How to use:
+ First you need to flash FlintESPJVM to ESP32. This is the java virtual machine that helps ESP32 understand and execute compiled java files (class files).
+ Install FlintJVMDebug on Visual Studio Code to support loading java class file to ESP32 and run with debug.
+ Refer to FlintExample to see and run the first program.

Git repositories:
+ FlintESPJVM - JVM on ESP32 : https://github.com/FlintVN/FlintESPJVM
+ FlintJVMDebug - VSCode extension to support debug: https://github.com/FlintVN/FlintJVMDebug
+ FlintExample: https://github.com/FlintVN/FlintExample.
Attachments
demo.gif
demo.gif (385.33 KiB) Viewed 785 times

Who is online

Users browsing this forum: No registered users and 12 guests