SmartLine - joe7575/techpack GitHub Wiki

SmartLine Blocks

Table of Contents

The following SmartLine blocks are functional identical to the Tubelib blocks with the same names, the only different is the block housing. (see addons2)

SmartLine Button/Switch


You can switch on/off other blocks by means of the Button/Switch. To switch the block on/off, the number of the block has to be entered into the Button form. (Don't forget the leading zeros!) This block can be configured as button or as switch. For the button configuration, times between 2 to 16 seconds are possible. You can control several blocks by means of one button. In this case all numbers with blanks in between have to be entered.

SmartLine Button/Switch [smartline:button]

States:

  • none

Features:

  • sends "on"/"off" events
  • Programmer support (store node numbers)

Supported Commands:

  • none

SmartLine Repeater


The Repeater is a multiplier block, sending received commands to all connected blocks. The list of destination block numbers has to be configured, but can easily programmed by means of the Programmer.

SmartLine Repeater [smartline:repeater]

States:

  • none

Features:

  • Programmer support (store node numbers)

Supported Commands:

  • none

SmartLine State Collector


In contrast to the Repeater, the Collector is a block collecting states from other blocks. The list of block numbers has to be configured, but can easily programmed by means of the Programmer. The Collector reads one block state each second. After reading all states, the result will be used as own state and can be read by means of a Controller. In addition, a state severity level can be configured. If this level is reached or exceeded, the Collector sends an "on" event to a configured block (e.g. a Controller).

SmartLine State Collector [smartline:collector]

States:

  • "running", "stopped", "standby", "blocked", "fault", "defect"

Features:

  • sends "on"/"off" events
  • Programmer support (store node numbers)

Supported Commands:

  • "state": read the state of the block
    • via SmartLine Controller: state
    • via SaferLua Controller: $get_status(num)

SmartLine Timer


The Timer is for a daytime controlled sending of commands e.g. to turn street lights on/off. The timer checks the time every few seconds. If the block was just loaded, the timer will check the last 4 hours for commands.

SmartLine Timer [smartline:timer]

States:

Features:

  • sends "on"/"off" events

Supported Commands:

  • "control": turn the device/block "on" or "off"
    • via SmartLine Controller: switch
    • via SaferLua Controller: $send_cmnd(num, text)

SmartLine Sequencer


The Sequencer block allows to define sequences of on/off commands with time delays in between. For this purpose, a sequence of up to 8 steps can be programmed, each with destination block numbers, on/off command, and time gap to the next step in seconds. The Sequencer can run endless or only once and can be switches on/off by other blocks.

SmartLine Sequencer [smartline:sequencer]

States:

Features:

  • sends "on"/"off" events

Supported Commands:

  • "control": turn the device/block "on" or "off"
    • via SmartLine Controller: switch
    • via SaferLua Controller: $send_cmnd(num, text)

SmartLine Player Detector


The Player Detector sends a "on" command to all connected blocks, when a player is nearby (4 blocks radius). The player name can be requested by means of a "name" request command (see [SmartLine Controller). The Player Detector can be programmed with player names (with blanks in between). In this case only the "known" players trigger the command.

SmartLine Player Detector [smartline:playerdetector]

States:

  • returns the name of the player

Features:

  • sends an "on" message, if a player is nearby (4 nodes radius)
  • Programmer support (store node numbers)

Supported Commands:

  • "detector_state": read the state of the playerdetector
    • via SmartLine Controller: playerdetector
    • via SaferLua Controller: $playerdetector(num)

SmartLine Signal Tower


A Signal Tower is used to indicate machine or controller states optically. The Signal Tower has green, amber, and red lamps, which can be switched on by means of the corresponding commands "green", "amber", "red", and "off". In addition the Signal Tower supports to request the block state, which is "green", "amber", "red", or "off". (To control the Signal Tower, see [SmartLine Controller).

SmartLine Signal Tower [smartline:signaltower]

States:

  • "green", "amber", "red", "off"

Features:

  • none

Supported Commands:

  • "tower": set the signaltower color
    • via SmartLine Controller: signaltower
    • via SaferLua Controller: $send_cmnd(num, text)
  • "state": read the state of the block
    • via SmartLine Controller: state
    • via SaferLua Controller: $get_status(num)

SmartLine Display


The Display is used for text outputs from the Controller. Is supports commands to clear the screen, position related output and scroll mode. The display has 9 text rows (1..9). If you output to row 0, the display 'infotext' is written instead. (To control the Display, see SmartLine Controller).

SmartLine Display [smartline:display]

States:

Features:

  • none

Supported Commands:

  • "display": output text to the display
    • via SmartLine Controller: display
    • via SaferLua Controller: $display(num, row, text,...)
  • "cl_screen": clear the display
    • via SmartLine Controller: cleardisplay
    • via SaferLua Controller: $clear_screen("1234")

SmartLine Controller


The most complex block of SmartLine is the SmartLine Controller, a 'computer' to control and monitor Tubelib based machines. You don't need any programming skills, it is more like a configuration based on rules with conditions and actions.

Examples for conditions are:

  • the Player Detector detects a player
  • a button is pressed
  • a block state is fault, blocked, standby,...
  • a timer is expired

Examples for actions are:

  • turn on/off tubelib blocks, like lamps, door blocks, machines
  • send chat messages to the owner
  • output a text message to the display

(see SmartLine Controller)

SmartLine Controller [smartline:controller2]

States:

  • "running", "stopped"

Features:

  • none

Supported Commands:

  • "control": turn the device/block "on" or "off"
    • via SmartLine Controller: switch
    • via SaferLua Controller: $send_cmnd(num, text)
  • "state": read the state of the block
    • via SmartLine Controller: state
    • via SaferLua Controller: $get_status(num)

⚠️ **GitHub.com Fallback** ⚠️