Skip to content

JurajKubelka/MQTTChat

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

34 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MQTTChat

Build Status Test Status

Build status

A MQTT messaging library for Pharo. It is build on top of MQTT library where you can find more information about MQTT in Pharo.

Installation

Evaluate the following code in Playground:

Metacello new
    baseline: #MQTTChat;
    repository: 'github://JurajKubelka/MQTTChat/repository';
    load.

Example

Using IoT Eclipse server

To play with it, you can connect to the IoT Eclipse server. To use a prepared example, execute the following code:

MQTTChat exampleAliceAndPedroIoTEclipse.
“And at any moment Bob can connect to the existing chat.”
MQTTChat exampleBobIOTEclipse.

Using local MQTT server

Similarly, there are examples for a local MQTT server, e.g., mosquitto:

MQTTChat exampleAliceAndPedroLocal.
“And at any moment Bob can connect to the existing chat.”
MQTTChat exampleBobLocal.

Screenshots

The UI is very simple. If you close a window, the chat client is automatically disconnected from the server. The client is automatically reconnected on a network failure. You can open Transcript in order to see log of network activities.

Chats of Alice and Pedro