Please read the general section first!
The MattzoSignalController is designed to receive signal commands from Rocrail via the MQTT broker and set light signals to a specific signal state.
When Rocrail wants a signal to change state, it communicates this as a command via the MQTT broker. The MattzoController receives this command and evaluates, if the command is relevant for the specific controller (i.e. if the signal is connected to this controller).
The signal state is communicated from Rocrail by switching specific LEDs on and off. Example: a signal has a red and a green light. If the new signal state is “green”, Rocrail sends two commands: 1. red off, 2. green on.
Up to eight LEDs can be connected to the controller. If standard signals with only red and green LEDs are used, this means, that four signals can be attached to one controller.
The following diagram shows the wiring of the controller. As an example, four simple signals with one red and green LED each are connected to the controller.
An additional LED can be connected to pin D8. The LED indicates the connection status of the controller to WiFi and MQTT.
If you use Trixbrix signals, check out their special wiring. The middle wire (red) is the common plus terminal (anode) of the LEDs. It must be connected to 3V3 of the controller. The outer wires (black, yellow) are connected to pin D0-D7 of the controller and represent the minus terminal (cathode) of the two LEDs.
- I/O board with micro controller. We have used a NodeMCU Amica Modul V2 ESP8266 ESP-12F. Similar modules should work as well.
- LEDs in different colors (red, green, for railway experts also possibly yellow and white) if you build the signals yourself.
- Possibly some resistors to protect the LEDs from burning off. Resistors with 220 Ω are frequently used for this job. In doubt ask the vendor of your signals or LEDs or check the specifications.
- Basic stuff like bread board, wires etc.
The controller can be powered up with a simple USB charger over USB or some other power supply of similar voltage that is connected to the VIN and GND pins of the controller.
The controller itself can be easily powered up via USB.
In the wiring diagram, the signals are connected to the 3.3V terminal of the controller. If this is too much for the LED that you are using, add a resistor in sequence to them.
The signals light up brighter if the plus terminal of the signals is connected to VIN (between 4.5 and 5V if supplied via USB) rather than to the 3.3V pin of the controller. We have tried this successfully with TrixBrix signals without breaking them. You are free to try it yourself, but you do this on your own responsibility.
In general, we recommend to check with the vendor of the signals or LED for what voltage the LED is built.
For general setup instructions please refer to the “General” section.
To setup the signal in Rocrail, navigate to the interface tab of the signal definition. The MattzoControllerID must be entered as “Address” parameter, and the port of the LED as “Port”. This must be done for all signal states (usually only red and green).
The first port of the controller has the number “1” (not “0”).
ALL OTHER INFORMATION ON THIS PAGE CAN BE NEGLECTED AND HAS NO MEANING!