neuron-explorer
Qwen3.5‑4B 전용 조향형 뉴런 탐색기, 모든 MLP 뉴런을 밀어 결과를 보관·탐색
Java 바이트코드 일부를 Arduino UNO R4 WiFi와 UNO Q용 Cortex‑M4 어셈블리로 바로 컴파일, 보드에 JVM 필요 없음
An ahead-of-time compiler that lowers a checked subset of Java bytecode straight to Cortex-M4 assembly for the Arduino UNO R4 WiFi and UNO Q — no JVM on the board.
개발 도구Java · CGitHub @jabrena온라인운영자 미확인
써 보셨어요? 한 번만 눌러 주세요. 로그인은 필요 없어요.
아직 감지된 업데이트가 없습니다. GitHub 릴리스가 나오면 여기에 보입니다.
개인 계정의 공개 저장소 소유자는 GitHub로 로그인해 운영자를 확인하고 소개를 직접 관리할 수 있습니다. 관리자 승인은 필요하지 않습니다.
로그인한 뒤 확인 파일을 만들어 이 저장소의 기본 브랜치에 30분 안에 커밋해 주세요. 다른 브랜치나 포크의 파일은 인정하지 않습니다. 파일을 올린 뒤 아래에서 확인하면 관리자 승인 없이 관리할 수 있습니다. 자격을 유지하려면 파일을 남겨 두세요.
로그인이 필요하면 로그인 화면으로 이동합니다. 로그인 후 이곳으로 돌아와 원하는 확인 버튼을 다시 눌러 주세요.
프로젝트 폴더에서 /nomorevibe verify를 실행하면 소유권을 확인하고 소개를 직접 관리할 수 있습니다.
1분 만에 확인하기Juno is an ahead-of-time compiler for running a practical subset of Java on Arduino Uno R4 WiFi & Arduino Uno Q
저장소 README에서 가져옴
README 전체를 불러오는 중입니다. 아래는 저장된 발췌입니다.
Juno is an ahead-of-time compiler for running a practical subset of Java on the Arduino UNO R4 WiFi
and the Arduino UNO Q. It keeps javac as the Java frontend, performs
closed-world linking on the development machine, and emits GNU ARM (Cortex-M4, Thumb-2) assembly.README 전문 보기 ↗JUno /ˈxu.no/ is an ahead-of-time compiler for running a practical subset of Java on Arduino boards & M5Stack Cardputer. It keeps javac as the Java frontend, performs
closed-world linking on the development machine, and emits Assembly.
Traditionally, Java programs require a JVM to run. However, in memory-constrained environments, running Java programs inside a JVM can be difficult. Juno enables developers to create small Java programs for microcontrollers such as Arduino.
Requirements: Arduino CLI, JDK 27+, Maven 3.10+.
On macOS, install Arduino CLI with Homebrew and verify that it is on your PATH:
brew update
brew install arduino-cli
arduino-cli version
See Arduino's installation guide for direct downloads and other options.
sdk env install
./mvnw clean install
Blink runs unmodified on every
supported board. Its built-in LED alternates on and off every 500 ms (one full cycle per second).
package io.github.jabrena.juno.api.hardware.gpio;
import io.github.jabrena.juno.hardware.ArduinoUno;
import io.github.jabrena.juno.hardware.gpio.DigitalOutput;
import io.github.jabrena.juno.util.Delay;
public final class Blink {
public static void main(String[] args) {
DigitalOutput led = DigitalOutput.of(ArduinoUno.getGpio().getBuiltinLed());
while (true) {
led.high();
Delay.millis(500);
led.low();
Delay.millis(500);
}
}
}
The project provides a Maven plugin to help the user with the common operations. juno:upload generates the sketch, verifies it with arduino-cli, and flashes it in one step.
Blink has no board restriction, so pick a target with -Djuno.board:
./mvnw -f juno-examples/pom.xml compile juno:upload \
-Djuno.main=io.github.jabrena.juno.api.hardware.gpio.Blink \
-Djuno.board=arduino-uno-q
# -Djuno.board=arduino-uno-r4-wifi
# -Djuno.board=arduino-uno-r3-wifi-rev2
# -Djuno.board=arduino-uno-r3
# -Djuno.board=arduino-nano-esp32
Select another supported board with -Djuno.board. The plugin auto-detects the port when exactly one matching board is
connected; otherwise, specify it with -Djuno.port=<PORT>.
After uploading the program, you could monitor what happen in the board using the following command:
./mvnw -f juno-examples/pom.xml juno:monitor \
-Djuno.board=arduino-uno-q
The juno Maven plugin provides these goals. The commands below run them from the examples module;
add -Djuno.main=<fully-qualified-class-name> and -Djuno.board=<id> when the entry point has no single-board
@Board declaration.
For example, verify the Grove Temperature and Humidity Sensor Pro monitor for a UNO WiFi Rev2 without uploading it:
./mvnw -f juno-examples/pom.xml compile juno:verify \
-Djuno.main=io.github.jabrena.juno.api.hardware.device.grove.sensors.GroveDht22Monitor \
-Djuno.board=arduino-uno-r3-wifi-rev2
Juno is an ahead-of-time compiler, not a JVM, so it intentionally supports a focused, predictable
subset of Java that can be translated into native code for resource-constrained Arduino boards.
Programs are first compiled normally with javac; Juno then performs closed-world linking from
main, follows every reachable method, and validates the bytecode before generating the sketch.
Valid Java is therefore not automatically valid Juno input. If reachable code needs an unsupported
bytecode instruction, JDK feature, or invokedynamic bootstrap, compilation stops instead of
emitting code with uncertain behavior. The diagnostic identifies the method, bytecode offset, and
unsupported operation or bootstrap. The currently supported Java subset includes:
static void main(String[]), the embedded-friendly
static void main(), static methods with primitive arguments and results, direct closed-world
calls, and removal of unreachable methods. See
HelloWorld and
Methods.boolean, byte, short, char, int, long, float, and double.
The example prints each type's size and range using javac-folded BYTES, MIN_VALUE, and
MAX_VALUE constants. See
PrimitiveTypes.switch, and loops. See
Variables,
Operators, and
ControlFlow.boolean through double, including fixed-size
multidimensional arrays) allocated from the fixed 8 KiB arena, and static final read-only lookup
tables with an all-constant initializer, kept in flash instead of RAM. See
.This is a multi-module Maven build:
juno-api/ — the programming model: the Java-facing hardware API the compiler
recognizes as intrinsics (api/) and the @Board annotations used to select a compilation
target (annotations/). This is the only artifact programs compile against.juno-compiler/ — the compiler (classfile, bytecode, linker, backend, …),
which depends on juno-api. Builds the executable juno-compiler/target/juno-compiler-<version>.jar.juno-maven-plugin/ — Maven goals for generating a sketch (juno:compile),
compiling it with Arduino CLI (juno:verify), uploading it (juno:upload), and opening the
serial monitor (juno:monitor).juno-examples/ — example Java programs written against juno-api, built
like any other Maven module so they're checked for compile errors on every build.juno-site/ — the Roq/Quarkus static site generator behind
the documentation site. docs/ is entirely generated from
Markdown under juno-site/src/main/resources/content/ — see
Documentation site below to regenerate it.juno-third-parties/ — integrations maintained outside the core compiler,
currently including the independent H8/300 firmware generator for the LEGO RCX, its S-record,
and the generated Java representation consumed by .Juno is an ahead-of-time compiler, not a virtual machine. An Arduino board has no JVM, so nothing is
interpreted at run time: the Java program is compiled with javac as usual, and Juno then translates the
resulting JVM bytecode into native ARM assembly that the Arduino toolchain builds into the sketch's firmware.
The compiler is closed-world: it only sees the classes reachable from main, so it can resolve every call
at build time, drop everything unused, and reject anything outside the supported subset before generating a
single instruction. That is also why there is no dynamic class loading, reflection, or general heap.
Hello.java ──javac──▶ Hello.class ──▶ Juno ──▶ Hello.S + HelloShim.cpp + HelloAsm.ino ──arduino-cli──▶ board
│
classfile → bytecode → linker → lowering → optimize → backend
@Board.
Maven runs javac; Juno consumes the resulting .class files.main, keeps only reachable code, converts hardware calls into
intrinsics, and rejects unsupported bytecode with a precise diagnostic..ino under target/juno/<Main>Asm/.juno:verify to
compile it, juno:upload to flash it, and juno:monitor to read its serial output.ArraysString.valueOf(int), length(), and charAt(int) for runtime
string references, equals, plus + concatenation of strings and a StringBuilder. See
Strings.java.math.BigInteger and BigDecimal, with
MathContext and the RoundingMode constants. Arithmetic, pow, sqrt, division by scale,
RoundingMode or MathContext, setScale, round, comparisons, conversions and toString /
toPlainString follow the JDK's results, scales and rounding. Values are immutable blocks in the
8 KiB arena and are garbage-collected, so precision is limited by memory, not by a fixed width. See
ScopedValuesPrecision.now(), MIN, the date and time getters, equals and ISO-8601 toString. now()
gets UTC from an SNTP server once Wi-Fi is up (JUNO_SNTP_HOST, default pool.ntp.org;
JUNO_SNTP_PORT, default 123) and returns LocalDateTime.MIN while it is unavailable. Works on every
Wi-Fi board, including the UNO R3 with the Arduino WiFi Shield. See
SntpTime and
SntpTimeSD
(server read from the SD card).java.util.UUID supports construction, parsing, formatting, comparison, 16-byte conversion through
UuidCodec, and randomUUID() on all boards. On the classic UNO R3, random UUIDs are weak and non-cryptographic;
use them only for node identities, as shown by WeakUuid.Objects and
Interfaces.LambdaMetafactory.metafactory. See
Lambdas.java.lang.Math subset and Arduino-backed bounded
pseudorandom numbers. See
MathFunctionsSinglePrecision,
MathFunctionsDoublePrecision and
RandomNumbers.throw, try/catch (including multi-catch and catching by a supertype),
finally, nested handlers, propagation between methods, custom final exception classes, and
try-with-resources. See
Exceptions.Thread.startVirtualThread, join, isAlive) and the
supported JDK 27 preview StructuredTaskScope subset with cooperative subtasks (up to four threads including main, with
Thread.sleep and Thread.yield), restricted monitors and ReentrantLock, and ScopedValue bindings
inherited by forked subtasks. Platform threads (new Thread) and Thread.ofVirtual() builders are
rejected at compile time; AtomicInteger, AtomicBoolean and AtomicLong are available. See
Synchronization,
VirtualThreads,
StructuredConcurrency (subtasks owned by a scope that is joined and closed before the owner reads their results), and
ScopedValuesPrecision
(a scoped MathContext shared by three parallel subtasks).Blink (GPIO and delays),
SerialCounter (serial I/O),
HttpServerStatus (clocks),
LedMatrixHeart (LED matrix),
WifiStatus (Wi-Fi),
WifiStatusSD (Wi-Fi credentials loaded from an SD card),
WifiStatusSDLcd (the same, with an LCD Keypad Shield),
WifiProvisioning (access point and HTTP server to provide Wi-Fi credentials),
HttpsMethods (HTTP/HTTPS and JSON),
Miner2 (UDP between boards:
factor numbers together and chain the verified answers as a leaderless, Bitcoin-style proof-of-work chain), and
SdFileOperations (SD card).GroveDht22Monitor.
The LCD Keypad Shield (16x2 display, buttons,
backlight) is shown in
LcdKeypadDemo.
The ELEGOO 2.8" TFT touch shield (display, touch,
microSD) is shown in
TouchPaintTFT and
WifiStatusSDTFT.
The AZDelivery Data Logger Shield provides the SD card for
WifiStatusSD.
The Arduino WiFi Shield brings Wi-Fi, UDP, TCP, plain HTTP and the SNTP clock to the UNO R3, as shown by
UdpEcho and
PlainHttpWeather.juno-examples