Connection manual and WiFi / MQTT and WiFi / HTTP commands for SuperClock
 
Orologio/SuperClock can be controlled via WiFi in HTTP standard and also in MQTT standard, so that most Home Assistant hubs can control / command it. 
This means that SuperClock is also a simple, ingenious and very trendy way to show big messages inside any automation or domotics. 
display mqtt home assistant 
Now let's see first the commands for HTTP and then those for MQTT ... 
 
WiFi and HTTP connection <<< 
From your device you can connect to the internal WiFi generated by SuperClock, or you can connect SuperClock to your home WiFi in Settings, as illustrated in the quick manual for SuperClock
 
WiFi / HTTP commands 
Through an HTTP GET request made to: http://wfeasy.com/c (you must be connected to the internal WiFi of SuperClock; or instead of wfeasy.com you can use the IP, if you have connected SuperClock to the your WiFi; the IP which is something like 192.168.1.4 - this can also be set within the router's configuration options, so it doesn't change; typically this is done in a menu like DHCP utilities or Advanced DHCP). 
One or more commands can be sent to SuperClock at the same time, in the classic format of GET requests (and then using & to insert multiple parameters and separate them, and using the classic URL-encode to manage non-alphanumeric characters). The available commands are below. 
Example: http://wfeasy.com/c?l=100 set brightness to100; http://wfeasy.com/c?s=ciao and shows the string "ciao" on the display; http://wfeasy.com/c?l=100&s=ciao set brightness to 100 and shows the string "ciao" on the display. 
Using the IP, it will be (for example) http://192.168.1.4/c?s=ciao and so on... 
All this can be done for example by connecting to the internal WiFi with a PC and writing these things on the browser bar (eg Safari, Chrome, Firefox, Explorer); obviously you can also do it with Mac, Raspberry or other devices ... 
 
Command pw= 
If the use of a password is enabled (it is enabled and defined through the internal WiFi), it must be added to any request, putting it in pw 
Examples: 
http://wfeasy.com/c?s=ciao&pw=a8d7f6k5 
displays the string "hello", but only if the password is a8d7f6k5 - if the pass is not correct, it does nothing. 
 
Command s= 
Shows the string on the display, scrolling if the length of the string is greater than the available characters. 
Examples: 
s=8765 
Visualizza 8765 
s=Hello guys! 
Shows Hello guys! doing continuous scrolling 
s=@Hello guys! 
Shows Hello guys! scrolling once 
 
Command x= 
Shows the string on the display, scrolling if the length of the string is greater than the available characters, once, then returns to showing what it was previously showing. The string is max 252 characters. 
Examples: 
x=Hello guys! 
Shows Hello guys! scrolling and then returns to what it was doing before 
 
Command t= 
Shows on the display a timer in seconds.hundredths, starting from the hundredth given in input. 
Examples: 
t=
Starts and Shows a timer starting at 00.00 
t=12 
Starts and Shows a timer starting at 00.12 
t=
Stop the timer at the time reached 
t=S0123 
Stop the timer by displaying 01.23 
 
Command k= 
Puts the display in clock mode, setting the time. 
Examples: 
k=1230 
It starts the clock at 12.30 and from now on Shows the clock. 
k=n 
From now on shows the clock, showing current system time. 
 
Command l= 
Set the brightness (or max brightness), usually from 0 to 100 
Examples: 
l=90 
Set the brightness (or max brightness) to 90. 
l=
Activate automatic brightness control. 
l=
Deactivate automatic brightness control. 
 
Command p= 
Set the scrolling speed in hundredths of a second (default 25; minimum 5; step 5) 
Examples: 
p=40 
Set the scrolling to 40 hundredths of a second. 
 
 
WiFi and MQTT connection <<< 
A WiFi connection is also required for MQTT, but in this case it is not enough to connect to the internal WiFi generated by SuperClock, but you must connect to a WiFi that has access to an MQTT Broker; for example you can connect SuperClock to your home WiFi; or you can connect SuperClock to a ControlHUB with the internal broker activated. 
This is done from the Settings, as illustrated in the quick manual for SuperClock
To configure SuperClock for MQTT instead, connect to SuperClock and go to the Settings menu (to connect, etc. see quick manual for SuperClock), and under the MQTT item you will enter: 
- the IP or name of the server where the MQTT Broker runs (note: if left blank, SuperClock will not use MQTT) 
- possibly username and password of the Broker, if needed 
SuperClock shows in the MQTT entry the name of the default topics used for the publication / out and to receive / cmd commands; it is possible if you need to specify a prefix (some free brokers require topics to start with for example yourusername/feeds/ or something like that), otherwise leave the "prefix" boxes blank. 
 
Then click Save and SuperClock will connect, and after a few seconds it will also start working in MQTT. If the connection is OK it will write OK after the word MQTT; and immediately on the same page the names of the Topics to be used to command SuperClock and to receive SuperClock messages are shown. 
For safety, we suggest using a Broker installed on your PC or other (you can download and install and run a Broker program such as Mosquitto even on a simple Windows PC), or ControlHUB with the built-in broker activated. 
 
Response / Publication Topic 
When it responds to commands, or when it means something, SuperClock publishes a message on the topic ck-o-name (where Name is the name you gave to the device a little further down in the Settings). 
You need to listen to this Topic in order to read what SuperClock says. 
The response / payload is a text, eg. date, time and temperature after the Command STATE was given; the other commands often give the return of the command as a response, to make it clear that it has been received. 
Upon power up, as soon as it is connected to MQTT, SuperClock publishes as if responding to STATE. 
 
Topic of Command / Listening 
SuperClock always listens on the topic ck-c-name (where Name is the name given to the SuperClock device a little further down in the Settings). To command it, the hub, the Assistant or anyone using MQTT message sending libraries, must publish a message / payload on this Command Topic: 
 
{"Show":"beautiful sentence!"}
Shows on the display beautiful sentence!, fixed or automatically making a continuous scrolling if the length of the string is greater than the characters available on the display.
{"One":"beautiful sentence!"}
Shows on the display beautiful sentence!, by scrolling once only; then go back to what it was showing previously
{"SetTime":"1230"}
switches to clock mode and starts at 12.30 (NOTE to be written without the dot)
TIME or {"TIME"}
switch to clock mode and show the current time on the screen (remember that in the settings it can be set so that it synchronizes with a pool of atomic clocks via the Internet)
{"Brightness":100}
set brightness to 100 (generally available values from 1 to 100)
{"Speed":20}
sets the scrolling speed in hundredths of a second
STATE or {"STATE"}
returns date and time
 
As known, for MQTT a local or remote system (accessible via the Internet) is required to act as a Broker
If you are doing an automation with SuperClock and WiFi, you can simplify and avoid this need by using simple HTTP / Web commands instead of MQTT, this is explained at the top of the page. 
For questions and suggestions post on the SuperClock forum... 
 
 
Orologio/SuperClock (Home) - forum SuperClock - contact us... 
 
 
Here are the quick manuals for some other products: 
- connection and control manual, WiFi HTTP and MQTT for DoorOpen/DoorSwitch 
- connection and control manual, WiFi HTTP and MQTT for QueueNumber and MultiQueue 
- connection and control manual, WiFi HTTP and MQTT for Orologio/SuperClock 
- connection and data manual, WiFi HTTP and MQTT for TXtemp, TXdata, TXsoil 
 
- connection and control manual, Serial RS232 for 8888-Display (ModBus WiFi HTTP MQTT) 
- connection and control manual, ModBus for 8888-Display (RS485 ModBus WiFi HTTP MQTT) 
- connection and control manual, WiFi/HTTP for 8888-Display (ModBus WiFi HTTP MQTT) 
- connection and control manual, WiFi/MQTT for 8888-Display (ModBus WiFi HTTP MQTT) 
 
- manual with data format for data sent by HTTP for RXTXeasy 
- manual with data format for data sent by HTTP for ModBusEasy 
 
Home page - WFeasy Hardware Solutions Home - Hardware by VisualVision 
VV Automazione Domotica MQTT 
(C) 2020 VisualVision