MQTT.fx – bug fix release

You can download latest binaries at
Bugs and feature requests can be reported via the issue tracker.

Version contains some bug fixes (since 0.0.14 release):

  • [Fixed] Issue #27 Disconnection when publishing to a second broker
  • [Fixed] bug when to show only latest messages
  • [Fixed] bug when receiving broker status messages ($SYS-topics)

Introducing: FontAwesomeFX 8.1

I have started a new major of FontAwesomeFX.


First of all the new container for an icon character now extends javafx.scene.text.Text instead of javafx.scene.control.Label (see this post for details, many thanks to Peter Schulz for the hint!).
If you know former versions of FontAwesomeFX you may notice that AwesomeDude is now called GlyphsDude, AwesomeIconsStack is now GlyphsStack and so on. But the most significant change is the option to support basically any Glyph/Web Font by just adding a new implementation GlyphIcon where T implements the GlyphIconName interface and the name -> unicode mapping (as Enum).

Currently 2 icon fonts support are build-in:

(in respect to Dave Gandy (Yes: ‘fortawesome’ its not a typo ;-)))

(in respect to Erik Flowers and Lukas Bischoff

Usage in FXML


<?import de.jensd.fx.glyphs.fontawesome.*?>
<?import de.jensd.fx.glyphs.weathericons.*?>

<fx:root prefHeight="300.0" prefWidth="600.0" type="VBox" xmlns="" xmlns:fx="">
        <VBox alignment="CENTER" spacing="10.0">
                <FontAwesomeIcon iconName="STAR" size="12em" glyphStyle="-fx-fill: linear-gradient(#70b4e5 0%, #247cbc 70%, #2c85c1 85%);"/>
                <WeatherIcon iconName="CLOUD" size="12em" glyphStyle="-fx-fill: linear-gradient(#70b4e5 0%, #247cbc 70%, #2c85c1 85%);"/>
                      <FontAwesomeIcon iconName="CIRCLE" size="24em" glyphStyle="-fx-fill: linear-gradient(#70b4e5 0%, #247cbc 70%, #2c85c1 85%);"/>
                      <FontAwesomeIcon iconName="BITBUCKET" size="12em" glyphStyle="-fx-fill: linear-gradient(#ffffff, #d2d2d2); -fx-effect: dropshadow( one-pass-box , rgba(0,0,0,0.8) , 4 , 0.0 , 1 , 1 );"/>
                <Insets bottom="20.0" top="20.0" />

Usage in SceneBuilder

Also layered combinations are supported: GlyphStack



Download Binaries: Download
Sources available at Bitbucket



MQTT.fx 0.0.14 released

As always you can download latest binaries at
Bugs and feature requests can be reported via the issue tracker.
Also the Update Feature of 0.0.13 should inform you, that there are updates available (See NNOTE 1 at bottom of this page)!

Reviewed Clipboard Messages

  • Order can now be changed by Drag-and-Drop
  • Can be published instantly by click on Button
  • Changes are now stored immediately


All new approach with topics and messages

  • Rendering revisited
  • Colors of topics can now be customized (messages are colored accordingly)
  • Colors of topics are persisted in configuration
  • Topics can now be unsubscribed by click on “-” (messaged will be removed accordingly)
  • Number of received messages per topic is shown
  • Messages also do show the wildcard topics to which they have matched
  • Only longer payloads are expandable now, one-liner are shown as subject
  • “Copy Payload” is now accessible without expanding the payload
  • Improved performance



Support for HTTPS proxy connection options
In respect to Dino Tsoumakis 😉
https proxy

Anything else?

  • Fixed an issue with unrecognized (but allowed) characters in topics

I was asked how to add new Scripts
I mentioned this before in a post (but this was 6 month ago ;-)).

New scripts can be easily made available for execution via the UI.
The app is scanning a folder named “scripts” located at the MQTT.fx working directory:

[USER_HOME]/Library/Application Support/MQTT-FX/scripts



If this folder does not exists it is created by MQTT.fx containing scripts.
Naming convention:

[INDEX] controls the order of the entry in the drop down menu
__ delimiter between index and name
[NAME the name of the menu entry (words are delimit by ‘_’)

E.g.: With these files in the “scripts” folder

the menu looks like this:
scripts menu

NOTE 1: In 0.0.13 the Update Feature has a bug!
The new install packages are loaded but yet not always renamed on Windows and Linux (this is fixed in 0.0.14). You will find the packages ending with postfix “.download”. You have to rename it manually.

NOTE 2: The format of the configuration has changed!
You may have to delete you current configuration and restart MQTT.fx. MQTT.fx will create a new default configuration for you!

SweetHomeHub: Home Control with Raspberry Pi and MQTT – Part 1

Since quite a long time I am working on my universal Raspberry Pi based Intertechno-Remote (see former posts 1 2 3 4):

intertechno remote

I tried different approaches to trigger/control my remote control service via a custom HTTPServer/-Handler and a simple Vert.x verticle.
Since MQTT v3.1.1 turns out as on of the de-facto standard protocols for the IoT I also implemented an MQTT client.

This MQTT client basically follows two design patterns:

1. One topic for each device
For each device a topic is defined. Its state can be controlled by publishing a message with payload “ON” or “OFF”.

  • the user must not know about the address code of the Intertechno device
  • changes of the address must not be published
  • the message is simply “ON” or “OFF to control the device


  • the user must know the topic for each device
  • the user can only control configured devices

2. One topic for a JSON message

  • very flexible to control the devices


  • the user must know about the syntax of the JSON and the coding of devices

Provide both options 😉

One topic for each device


My configuration is very simple
On start-up the Client is searching for sweethomehub-config.xml in the users home directory which is then unmarshalled from JAXB.
This configuration contains the codes and the topic for each device and the MQTT settings for the broker connection:

            <name>Light Front-Door</name>
            <name>Light Terrace</name>
            <name>Light Garden</name>
            <name>Light Living Room</name>

And there is one additional topic awaiting the JSON commands:

        "name": "Light Front-Door",
        "houseCode": "a",
        "groupId": "1",
        "deviceId": "1"
        "name": "Light Terrace",
        "houseCode": "a",
        "groupId": "1",
        "deviceId": "2"
        "name": "Light Living Room",
        "houseCode": "a",
        "groupId": "1",
        "deviceId": "3"

The central method to handle arrived messages:


The JsonDeviceCommandProcessor:


And the doSwitch methods:


MQTT Client running on the Raspberry Pi waiting for messages:

… and receiving command messages:


Testing the receiver with MQTT.fx


Complete code can be found at BitBucket.