This repository contains additional documentation for Calimero and code examples.
- Create a KNX link (using default settings)
- Create a KNX link (with more options)
- Process communication (read/write datapoints)
- Use logging output
- KNX address converter
All examples can be built (not executed) using Gradle (./gradlew build
)
- Discover KNXnet/IP servers
- Discover KNX USB devices
- Create client-side KNXnet/IP tunneling network link
- Create client-side KNX USB network link
- Create TPUART network monitor link
- Process communication
- Group monitor
- DPT translation
- Network state buffering
- KNX push-button device
- KNX IP push-button device supporting discovery & self description
Build examples using ./gradlew :2.5:build
, run with ./gradlew :2.5:run
- KNX IP Secure routing network link
- ETS keyring viewer, run it with Gradle using
./gradlew :2.5:run -DmainClass=KeyringViewer --args="--pwd pwd '/path/to/keyring.knxkeys'"
- Run the example in your IDE. Or, from the terminal (put the required
jar
dependencies in the introduction directory: calimero-core, calimero-device, slf4j-api, optionally slf4j-simple):
# Compile the Java file
$ javac -cp "./*" src/main/java/PushButtonDevice.java
# Start the KNX device
$ java -cp "./*:src/main/java/" PushButtonDevice
- Use process communication to read/write the push button state. For example, start the Calimero process communication tool) in group monitor mode (
monitor
) in a second terminal. Using maven:
$ mvn exec:java -Dexec.args="groupmon 224.0.23.12"
and enter the following commands:
read 1/0/3 switch
[response should be printed with switch state off]
write 1/0/3 on
r 1/0/3
[response should be printed with switch state on]
Ctrl^C
- Read device information of the Calimero KNX device. For example, using the Calimero Device Info tool
$ mvn exec:java -Dexec.args="devinfo 224.0.23.12 1.1.10"
-
Discover KNX IP device (for the example which supports KNXnet/IP Discovery & Self Description)
The device should show up in the ETS. Otherwise, you can also use the Calimero discover tool. Using Gradle
./gradlew run -Dexec.args="discover"
Example output:
Using /192.168.10.10 at en0 --------------------------- Control endpoint 192.168.10.17:3671 (IPv4 UDP) "Push Button (KNX IP)" KNX address 1.1.10 KNX medium KNX IP installation 0 - project 0 (ID 0) routing multicast address 224.0.23.12 MAC address f4:5c:89:8a:f4:9b S/N 0x000000000000 Supported services: Core (v1)