Skip to content

RTU Gateway Configurator

Mikayla edited this page Mar 30, 2024 · 14 revisions

RTU Gateway Configurator Tool

The RTU gateway configurator tool can be brought up any time from the terminal by running configure on an RTU gateway. It will automatically come up if there is no valid configuration present, as shown in the first screenshot below.

General Tips:

  • You can paste values into number/text fields
  • You can navigate around with tab and shift+tab (and arrow keys where applicable)
  • You can ctrl+a or double click number/text fields to select all
  • When configuring the system, fields will be pre-filled with any valid existing configuration data
  • You will be shown a summary of settings before any are saved

Table of Contents

  1. Main Menu
  2. Change Log
  3. View Gateway Configuration
  4. Import Legacy config.lua
  5. Configure System
    1. RTU Gateway Configuration Options
    2. Network Configuration
    3. Logging Configuration
    4. Color Options
      1. Color Accessibility
        1. Color Modes
      2. Jump to Color Options
    5. Apply the Configuration
  6. Peripheral Connections
  7. Redstone Connections
  8. Generated Settings File

Main Menu

Below are two examples of the main menu. If the configurator is started by the RTU gateway app itself due to a lack of configuration, the red warning text in the first example will be present. If a configuration is present, the view gateway configuration, peripheral connections, redstone connections, and color options buttons will be enabled (unlike in the first example).

If a legacy config.lua file is present, the import option will be shown as seen below.

image image

Change Log

There is an embedded configuration file change log that will show what fields have been changed, added, or removed. This will help you figure out why a previously valid configuration may no longer be valid.

image

View Gateway Configuration

Here you can view the current configuration of the RTU gateway itself. This does not include configurations of the peripherals connected.

image

Import Legacy config.lua

This option is only available if rtu/config.lua is found. Those settings will be attempted to be imported and then a summary will be shown before the settings are saved.

It is strongly encouraged to only do this while all your peripherals are connected. Otherwise, you will see the below warning.

image

If you choose to continue or you have all your devices connected, you will next see this screen summarizing the basic RTU gateway configurations.

image

Next is the import of peripheral configurations. If all devices are connected and existing configurations were valid, you should see a list of all your devices with the message 'validated':

image

If some are disconnected or existing configurations are invalid, you will see these messages:

image

Next you will import the redstone configurations. This will show the input/output direction with an arrow, the redstone port name, the side and color, and the assignment (unit 1, facility, etc).

image

If that all looks good, you should press apply and then you will see this screen.

image

Or this one if there was somehow a problem saving the settings.

image

Configure System

This option will walk you through configuring the RTU gateway. Fields will be pre-filled with existing configuration data if present, otherwise the defaults will be shown.

RTU Gateway Configuration Options

The first and only gateway specific setting is the volume to use with the connected speakers. It is recommended to leave this at 1.

image

Network Configuration

You will need to provide channel information next. These are the channels you have chosen per this page, or they may be the defaults. Defaults are perfectly fine on single player, though not recommended on multiplayer if any other people may be using this project.

Next, continuing network configuration, there are some more options. There is the connection timeout, which decides how many seconds to wait before assuming the supervisor is no longer available. If your server is very laggy, you may need to increase this, but be wary of the RTTs that the supervisor shows on its front panel screens.

Second, for a very basic level of security/utility there is the connection range, which prevents the PLC from receiving any network packets that are beyond this distance away. A value of 0 disables this feature, allowing packets from any distance. Note, cross-dimensional packets (such as nether to overworld) have a nil distance, so with this feature enabled they will always be ignored.

This may be changed in the future to block packets with nil distance if a max range is configured.

Finally for network configuration is a more solid security feature (solid enough for a block game). You can provide a passkey as a facility key (same for every device on your network) that will be used to perform an HMAC-MD5 message authentication hash on each packet. This verifies packets received are authentic and from one of your devices. It does NOT encrypt your data (that takes far too long), but there should be no need for it to do so. This feature prevents others from connecting to or even controlling your system.

Please DO NOT USE ONE OF YOUR REAL PASSWORDS. This key is stored in plaintext (human readable), so anyone who has access to that computer or the server's filesystem (like admins) can see it.

Logging Configuration

Before reaching the summary page, you will configure logging. This is likely to be unmodified, unless you want to store log files on a separate disk in-game for storage size reasons. That would allow for larger log files.

  • Log file modes are either "replace the log file each time the main RTU gateway program starts" (not recommended) or "append to the log file each time the main RTU gateway program starts" (recommended)
  • Log path should be a valid path to somewhere that a file can be created, otherwise the system will error on start
  • Debug messages are only really valuable for finding bugs of course, so if you have a problem and can send more detailed logs by reproducing the problem with debug messages enabled, that's ideal. If you are out to break the program, you might as well enable debug messages before you attempt to do so so the logs are already there. Do be aware this results in significantly larger log files, which may cause them to be recycled (cleared and restarted) more often if there are space problems.

Color Options

With color options, you can customize themes and color accessibility options. The RTU gateway has one theme option, which is for its front panel. Sandstone is the "light" theme (default), and Basalt is the "dark" theme.

image

Color Accessibility

Clicking "Accessibility" will bring up the color accessibility options. Here you will find a set of color modes intended to help with different types of colorblindness, plus options to change indicators to be black when off or change greens to be blues. The three colorblindness modes always set indicators to be black when off and green indicators to be blue, in addition to shifting the other colors used for indicators. For all modes, a preview of what the indicators will look like is shown. Note that exact colors vary by the theme you have selected since contrast needs to be maintained.

Non-standard color modes split up the NETWORK light on the front panel for clarity.

image

See this page for details on colorblindness modes.

Color Modes
  • Standard: Standard green/yellow/red shades with color tinted backgrounds.
  • Deuteranopia: Colorblindness mode targeted for Deuteranopia that uses modified blue/yellow/red shades with black backgrounds. This has the same blue shade as Protanopia, but red and yellow are different.
  • Protanopia: Colorblindness mode targeted for Protanopia that uses modified blue/yellow/red shades with black backgrounds. This has the same blue shade as Deuteranopia, but red and yellow are different.
  • Tritanopia: Colorblindness mode targeted for Tritanopia that uses modified blue/yellow/red shades with black backgrounds.
  • Blue for 'Good': Swaps blue in place of green in indicators. Uses standard shades for yellow and red, and maintains color tinted backgrounds.
  • Standard + Black: Same as Standard, except indicators have black backgrounds.
  • Blue + Black: Same as Blue for 'Good', except indicators have black backgrounds.

Jump to Color Options

If you jump to the color options from the main page, you will be able to apply the settings right away afterwards.

image

Once you apply, you will see this screen.

image

Or this one if there was somehow a problem saving the settings.

image

Apply the Configuration

Lastly, you will see an overview of all the configurations that are going to be applied. Auth keys are hidden in this view until you use the unhide button (this does not affect how they are stored).

Once you apply, you will see this screen.

Or this one if there was somehow a problem saving the settings.

Peripheral Connections

Here you can configure all the RTU peripherals you have. First, you will see a list of your currently configured devices. From here, you can edit an entry or delete an entry. Editing will bring up the same prompt as was used to initially create the peripheral entry.

Changes, BEFORE being applied, can be reverted with the Revert Changes button to the last peripherals configuration that was applied. Changes can be applied by using the Apply button.

If settings save successfully, you will see this first screen. If it fails, you will see this second screen.

Back to talking about that main menu. From there, you can add new peripherals with Add +. If peripherals are connected, supported, and not already configured, you will see them listed.

If you don't see your device, you can click I don't see my device! and you will see the below screen.

If you know your device identifier and its type, you can manually add it with Manual +. If you think it is connected but it isn't showing up, then you should re-check the connection instead of using this option. This is intended if you are going to hook up a device later but already know its ID.

After adding a device either from the connected device list or manually, you will see the associated form for that device type. All of these are listed below. For devices that need a reactor unit, you will be prompted for that (prefixed by unit #). For devices that need an index, you will be prompted for that as well (prefixed with the # symbol at the start of a configuration line). If a device can be either for the facility or for a unit, you will be able to select one or the other.

You can then confirm the input and will be sent back to the main peripheral configuration page.

Redstone Connections

Here you can configure all the RTU redstone connections you have. First, you will see a list of your currently configured inputs and outputs (I/O). From here, you can edit an entry or delete an entry. Editing will bring up the same prompt as was used to initially create the I/O entry.

Changes, BEFORE being applied, can be reverted with the Revert Changes button to the last redstone configuration that was applied. Changes can be applied by using the Apply button.

If settings save successfully, you will see this first screen. If it fails, you will see this second screen.

Back to talking about that main menu. From there, you can add new redstone entries with New +. On the creation page shown below, you can select the shortcut (in green) ALL_WASTE to create 4 new entries for each waste control output, one of the inputs denoted by [in] and colored yellow, or one of the outputs denoted by [out] and colored blue.

If you choose to use the ALL_WASTE shortcut, you will see the following screen. It indicates what action will be taken on creation, but I'll repeat that here. You can pick a side and select bundled, which will add 4 entries for that side under the colors red, orange, yellow, and lime. You can modify these later with EDIT on the main redstone configuration page shown previously. If you instead do not want to or cannot use bundled redstone, your side selection will be ignored and 4 entries with default sides left, back, right, and front.

Additionally, you need to set which reactor unit ID this waste processing is for.

Below is an example of an input, F_SCRAM, being configured as a bundled input from the top with the color magenta. Since this is a facility input, the Unit ID field is not present. If it was a unit input, then a Unit ID field would be present. This is shown in the second example below, R_ACTIVE, configured as an output to the bottom side.

image image

Generated Settings File

Clone this wiki locally