UJVM
| Preview release | 0.1.0
/ December 11, 2018 |
|---|---|
| Repository | github |
| Written in | C, Java |
| Engine | |
| Available in | English |
| License | Apache License |
Search UJVM on Amazon.
A micro Java Virtual Machine (uJVM) is an open-source Java Virtual Machine implementation specifically developed for use on embedded systems with low RAM and persistent storage available (e.g., a variety of boards based on ARM Cortex-M processor cores (M3, M4F, M23) and Atmel AVR microcontroller boards with at least 64 kB of Flash memory). Developers intend to follow the Java Virtual Machine Specification Java SE 7 Edition.[1] While the amount of hardware resources available on embedded systems necessarily constrains the size of executable code and available libraries, uJVM provides interfaces that let Java applications interact with hardware devices (timers, GPIO interfaces, etc.).
Implementation overview
uJVM was designed in accordance with the overall architecture described in the Java Virtual Machine Specification Java SE 7 Edition. So, basically, it can be divided into three parts:
- Class loader
The class loader of uJVM can load the contents of classes stored in .class or .jar files into memory, perform linking, and initialization.
- Managed memory areas
uJVM supports thread-specific register storage, memory allocation for heap and thread-specific stacks, and garbage collection.
- Execution engine
Due to severe memory footprint restrictions, uJVM has only a bytecode interpreter as an execution engine—implementing a JIT compiler would greatly increase memory consumption. The uJVM execution engine gives Java code access to JNI methods; however, as of January 2019, Java classes that directly contain native C code are not yet supported.
Supported platforms
- x86_64 Linux
- STM32F103-BluePill[2]
- STM32F4Discovery[3]
- STM32F429I-DISCO[4]
- Arduino MEGA 2560[5]
- MSP-EXP432P401R[6]
- EK-TM4C1294XL[7]
- NuMaker-PFM-M2351[8]
For every supported platform, there is a quick start guide and working source code examples.
Future plans
As of January 2019, uJVM is used as a bare-metal application that does not require any OS for hardware interaction; however, there are plans to make it usable as a framework that enables the execution of Java applications for RTOSes, e.g., FreeRTOS, NuttX or Zephyr.
See also
References
- ↑ "The Java Virtual Machine Specification Java SE 7 Edition" (PDF).
- ↑ "STM32F103-BluePill". 2018-10-29.
- ↑ "STM32F4Discovery" (PDF). 2017-05-31.
- ↑ "STM32F429I-DISCO".
- ↑ "Arduino MEGA 2560" (PDF).
- ↑ "MSP-EXP432P401R". 2018-03-08.
- ↑ "EK-TM4C1294XL".
- ↑ "NuMaker-PFM-M2351" (PDF). 2018-08-29.
This article "UJVM" is from Wikipedia. The list of its authors can be seen in its historical and/or the page Edithistory:UJVM. Articles copied from Draft Namespace on Wikipedia could be seen on the Draft Namespace of Wikipedia and not main one.
