You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: content/_index.md
+3-1Lines changed: 3 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,7 +4,7 @@ title: Welcome to Pi4J
4
4
5
5
## Welcome to Pi4J
6
6
7
-
**Latest release: V3.0.3 (2025-09-23, see [Release Notes](/about/release-notes/)).**
7
+
**Latest release: V4.0.0 (2025-02-20, see [Release Notes](/about/release-notes/)).**
8
8
9
9
This project is intended to provide **a friendly object-oriented I/O API and implementation libraries for Java Programmers** to access the **full I/O capabilities of the Raspberry Pi platform**. This project abstracts the low-level native integration and interrupt monitoring to enable Java programmers to **focus on implementing their application business logic**.
10
10
@@ -28,6 +28,8 @@ The Pi4j project has evolved in all these years as the whole Java eco-system and
28
28
* In 2.5.0, support for the Raspberry Pi 5 was added. Because of the new [GPIO chip RP1](https://www.raspberrypi.com/documentation/microcontrollers/rp1.html), a new GPIO Provider was needed. See the [this interview](/blog/2024/20240318_interview_alexander_liggesmeyer/).
29
29
*[V3.X.X](/about/info-v3): Based on Pi4J 2.8.0 and Java 21.
30
30
* Please [read this blog post for more info](/blog/2025/20250211-welcome-java-21/).
31
+
*[V4.X.X](/about/info-v4): Based on Pi4J 3.0.3 and Java 25, introducing the [FFM plugin](/documentation/providers/ffm/).
32
+
* Please [read this interview with Nick Gritsenko (aka DigitalSmile) for more info](/blog/2025/2025????-interview-nick-ffm/).
Versions 4.0.0 is based on 3.0.3 (released on 2025-09-23), but bumps the **Java version to 25** and has a new plugin that uses the Foreign Function & Memory (FFM) API. See the [release notes](/about/release-notes/).
8
+
9
+
## FFM Plugin
10
+
11
+
The goal of this bump to V4 is to enable the use of the Foreign Function & Memory (FFM) API in Pi4J. This FFM API has been introduced in OpenJDK 22 and simplifies the use of native libraries in Java. And native libraries are "the heart" of the Pi4J project as they provide the connection between your Java code and the hardware.
12
+
13
+
Thanks to the contributions by [Nick Gritsenko (aka DigitalSmile)](https://github.com/DigitalSmile) in [pull request #458](https://github.com/Pi4J/pi4j/pull/458), a complete new plugin got added to Pi4J. Read more about the work by Nick in this [interview](/blog/2025/2025????-interview-nick-ffm/).
14
+
15
+
## Sources
16
+
17
+
The Pi4J V4 source code is available in this GitHub repository: [`pi4j/pi4j` GitHub Repository](https://github.com/Pi4J/pi4j)
Copy file name to clipboardExpand all lines: content/about/release-notes.md
+27Lines changed: 27 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,6 +5,33 @@ weight: 40
5
5
6
6
All releases of Pi4J V2+ are listed on [github.com/Pi4J/pi4j/releases](https://github.com/Pi4J/pi4j/releases).
7
7
8
+
## V4
9
+
10
+
Requires Java 25, see [What's New in V4](/about/info-v4/) for more info.
11
+
12
+
### 2025-02-20 - V4.0.0
13
+
14
+
This is a big release with almost 400 commits and 300+ files added/changed...! **Pi4J V4 introduces the new [FFM plugin](/documentation/provider/ffm) and bumps the Java version to 25**. The FFM plugin makes use of the now Foreign Function & Memory API (FFM) to access the GPIOs. The FFM API got introduced in Java 22 with [JEP 454](https://openjdk.org/jeps/454).
15
+
16
+
This is the most tested release of Pi4J yet! The `pi4j-test` module has been reworked by [@taartspi](https://github.com/taartspi) to provide a smoke test approach with a fixed hardware setup that uses, for instance, input GPIOs to validate output GPIOs and PWM. Check [Hardware Testing](/architecture/about-the-code/hardware-testing/) for more info and how to setup.
17
+
18
+
Some highlights of all the changes in this release:
19
+
20
+
*[Issue #454](https://github.com/Pi4J/pi4j/issues/454): Implement new FFM API approach. First big pull request by [@DigitalSmile](https://github.com/DigitalSmile): [#458](https://github.com/Pi4J/pi4j/pull/458) with more for further improving, finetuning, and testing.
21
+
* Consistent use of `bcm`, `channel`, `bus`, `chip` when initializing an IO instead of the sometimes confusing `pin`or `address`. With related changes in the Pi4J registry to be able to correctly remove and reuse IO instances.
22
+
*[Issue #478](https://github.com/Pi4J/pi4j/issues/478): Race condition in GpioDDigitalInput causes monitor thread to exit
23
+
* BoardInfo: added CM5 Lite, and 500 Plus
24
+
* Bump Docker builder to JDK 25
25
+
* Nexus staging plugin replaced with Central Publishing plugin
26
+
* Rework of the [pi4j-test](https://github.com/Pi4J/pi4j/tree/develop/pi4j-test) module to provide an easy SmokeTest approach with a fixed hardware test setup.
27
+
* Various LinuxFS plugin improvements.
28
+
* Overall code fixes, improvements, new helper methods, cleanup, etc..
29
+
* Complete removal of serial support, use jSerialComm instead of Pi4J for serial communication, as [explained here](https://www.pi4j.com/documentation/io-types/serial/).
30
+
31
+
Thanks to contributions by [@DigitalSmile](https://github.com/DigitalSmile), [@IAmNickNack](https://github.com/IAmNickNack), [@stefanhaustein](https://github.com/stefanhaustein), [@taartspi](https://github.com/taartspi), [@eitch](https://github.com/eitch), [@fdelporte](https://github.com/fdelporte).
32
+
33
+
Detailed list of all the changes: https://github.com/Pi4J/pi4j/compare/3.0.3...4.0.0
34
+
8
35
## V3
9
36
10
37
Requires Java 21, see [What's New in V3](/about/info-v3/) for more info.
{{% notice warning %}}This is an experimental project which will need a lot of love... The new Raspberry
7
-
Pi Pico with a lot of GPIOs for a very low price, seems even to be a better fit for this project compared to the
8
-
Arduino Due... To be further investigated!{{% /notice %}}
9
-
10
-
To minimize the required time and efforts to test a new release, V2+ aims to include an automated test which performs
11
-
I/O testing on each I/O interface on each model of RPi. Ideally this would happen as part of the unit testing sequence
12
-
for each code commit or at least as part of the release cycle.
13
-
14
-
To achieve this, an Arduino Due board with lots of on board I/O capability is being used. The
15
-
[firmware that gets loaded onto the Arduino board](https://github.com/Pi4J/pi4j/tree/master/pi4j-test-harness/src/main/arduino)
16
-
listens on the serial port for instructions on which pins to use and what type of test to perform. The
17
-
"Test Harness" project also includes a [Java library that is used to communicate with the Arduino and instrument tests](https://github.com/Pi4J/pi4j/tree/master/pi4j-test-harness/src/main/java).
18
-
19
-
Next, a given [I/O provider plugin](https://github.com/Pi4J/pi4j/tree/master/plugins/pi4j-plugin-pigpio/src/test/java/com/pi4j/plugin/pigpio/test)
20
-
includes test classes that instrument the test harness and perform live I/O testing between the SBC (or other hardware)
21
-
and the Arduino Test Harness.
22
-
23
-
To be able to fully test all board types, a custom PCB needs to be created to perform all the interconnects between
24
-
the Raspberry Pi 26-pin/40-pin headers, and the Arduino board. This way enough test harnesses could be build for each
25
-
Raspberry Pi model and have a permanent setup for on-demand testing. This of course is a huge effort just by itself,
26
-
and perhaps too ambitious -- but seeking a means to reach automated testing is really needed for the long term.
0 commit comments