-
Notifications
You must be signed in to change notification settings - Fork 1
7. Format and Examples
Format (MQTT payload):
ZZAMSG#Targets#Template#Station#Track#Destination#Departure#Train#TrainType#Message#Spare1#Spare2#
- ZZAMSG: Identifier for relevant MQTT messages
- Targets: Identifier for displays e.g. D01 = Display01, D02=Display02, ..., can include more than one Display e.g. D01D02
- Template: Identifier for Template, T0 = Template 0, T1 = Template 1, ... T9, can include only one Template e.g. T0
Content Fields
- 0 - Station - Name of the station where the display is located
- 1 - Track - Track number
- 2 - Destination - Destination city
- 3 - Departure - Departure time
- 4 - Train - Train number
- 5 - TrainType - Train Type for Logo selection, e.g. ICE, IC, ...
- 6 - Message - Flexible message to display e.g. static in the middle of the display, as a ticker at the top, ...
- 7 - Spare1 - For future features, not in use at the moment
- 8 - Spare2 - For future features, not in use at the moment
Rocrail Dynamic Text Variables can be used. Some of them have been tested but by far not all.
Roc-MQTT-Display specific Command Variables
- NTP Time - {ntptime}
- NTP Date - {ntpdate}
- Rocrail Time - {rrtime}
- Rocrail Date - {rrdate}
All variables can also be used in scroll text.
Templates
Some standard templates are ready to use. They can be modified as you need them. For back to back displays there is a template for each side (A and B). Share your templates with the community. If you think you have configured a great template I'm happy to add it to the repository and wiki. Simply download it from the web interface of your controller and share it via GitHubs Issues function.
- T0 - Train Announcement - Side A
- T1 - Train Announcement - Side B
- T2 - Local Train - Side A
- T3 - Local Train - Side B
- T4 - Message Only, 1 Line - Side A
- T5 - Message Only, 1 Line - Side B
- T6 - Stationname, 1 Line - Side A
- T7 - tbd
- T8 - tbd
- T9 - tbd
Display | Description | MQTT message | |
---|---|---|---|
1. | Standard train announcement on Display 01 | ZZAMSG#D01#T0##1#Hamburg Hbf#15:12#ICE 251#ICE#### | |
2. | Standard train announcement on Display 01 with scroll message | ZZAMSG#D01#T0##1#Köln-Bonn#10:22#IC 53#IC#5min Verspätung### | |
3. | Standard train announcement on Display 01 and 02 with scroll message | ZZAMSG#D01D02#T0##2#Berlin Hauptbahnhof#11:45#ICE 597#ICE#Vorsicht an der Bahnsteigkante### | |
4. | Message only, in the middle | ZZAMSG#D01#T1##2#####Zugdurchfahrt### | |
5. | Use a Rocrail variable | ZZAMSG#D01#T0#Bhf01#1#####%lcid%### | |
6. | Show NTP Time, Track, Logo | ZZAMSG#D01#T4##1####DB#{ntptime}### | |
7. | Show Rocrail Time | ZZAMSG#D01#T4##1#####{rrtime}### | |
8. | Stationname | ZZAMSG#D01#T6#Bogenhausen######### | |
9. | Clear Display D01 and D02 | ZZAMSG#D01D02########### | |
10. | Local Train D01 with Logo | ZZAMSG#D01#T2##1#Sternschanze#10:22#U2#U#### | |
11. | Dynamic NTP time and Rocrail temperature in scroll message | ZZAMSG#D01#T0##1#Berlin Hauptbahnhof#23:05#ICE 597#ICE#Es ist {ntptime} %temp%°C### |
These are some examples how to integrate Roc-MQTT-Display with Rocrail. All other sources that can generate the required MQTT messages will work as well, e.g. Node-Red.
Copyright (c) 2020-2024 Christian Heinrichs. All rights reserved. |
---|