Skip to content

output

Description

The output block is used to pass values from the project logic to the selected property of the chosen device. It can be used, among other things, to control a relay output, brightness, blind position, or another device property that accepts values from the flow.

The block has one regular input and two outputs. It does not require the use of inputs labeled using the tag block.

In addition to sending values to the device, the block also provides:

  • the current value returned by the selected device property
  • information about whether the device is currently attached

Configuration parameters

Parameter name Value
Device identifier (device_id) Required parameter. It specifies the device to which values should be sent.
Device property name (device_property_name) Required parameter. It specifies the device property controlled by the block, for example an output, brightness, or another supported value.
Filter duplicated values (filter_duplicated_values) Required boolean parameter with the value true or false. When set to true, the block does not send to the device a value identical to the last known value of that property. When set to false, the same value may be sent again.
Remember last value (remember_last_value) Required boolean parameter with the value true or false. When set to true, the last value received while the device is detached or while the project has not finished stabilization is remembered and may be sent later. When set to false, such values are ignored.

Input handling

The block accepts ordinary input events delivered to its only input. It does not require any tag connections.

The block does not change the type of the received value. It passes to the device exactly the value that it received at the input. Compatibility of the value type and range with the selected device property must be ensured in the project configuration.

Detailed operating rules:

  • if the project has not finished stabilization yet or the device is detached, the block does not send the value to the device immediately
  • in that case, with remember_last_value = true, only the last received value is remembered
  • in that case, with remember_last_value = false, the received value is ignored
  • when the device becomes attached again and the project is already stabilized, the remembered value will be sent to the device only once
  • if a value identical to the last known value of the device property arrives at the input and filter_duplicated_values = true, the block does not send it again
  • if the same value arrives at the input and filter_duplicated_values = false, the block sends the same value to the device again

Ignored cases:

  • values received while the device is detached or before project stabilization, if remember_last_value = false
  • values identical to the last known device value, if filter_duplicated_values = true

Block outputs

The block has two outputs:

Output number and name Output description
1: Value returned by the device This output carries the current value returned by the selected device property. If the device provides a custom description of its value, the block also shows it in the description below the block.
2: Attachment status This output carries the logical value true when the device is attached and false when the device is detached.

The description visible below the block reflects the current state:

  • detached when the device is detached
  • the textual representation of the current device value when it is available
  • unknown when the device is attached but the current value cannot be represented as text

If several output blocks refer to the same device, the description may include a numeric prefix, for example 3(2): detached. Such a prefix indicates how many output blocks are associated with the same device and how many of them refer to exactly the same property.

Errors visible to the user

The block can display the following error messages:

Error code Error description
Missing device_id configuration. The device identifier was not provided or the parameter has an invalid value.
Missing device_property_name configuration. The device property name was not provided or the parameter has an invalid value.
Missing filter_duplicated_values configuration. The filter_duplicated_values parameter was not provided or could not be read as a boolean value.
Missing remember_last_value configuration. The remember_last_value parameter was not provided or could not be read as a boolean value.
Init failed. The block failed to initialize correctly and cannot operate.

The detached state means there is currently no connection to the device. It is not a block configuration error.

Examples

  • If remember_last_value = true, the device is detached, and the values 10, 20, 30 arrive at the input one after another, then after the device is attached again only the last value 30 will be sent.
  • If remember_last_value = false and the device is detached, the value delivered to the input will be ignored.
  • If the device property already has the value true, and true arrives at the input again while filter_duplicated_values = true, the block will not send that value again.
  • If the device property already has the value true, and true arrives at the input again while filter_duplicated_values = false, the block will send the same value again.
  • When the device becomes detached, output 2 will carry false and the description below the block will change to detached.