Skip to content

modbus-ventilation

Description

The modbus-ventilation block is used to integrate a ventilation unit controlled over Modbus RTU via RS485. The block periodically reads the device state and exposes it through the associated vlogic virtual device.

The first version supports the Systemair SAVE model. The value map for this model is built in, so the user does not configure register addresses or byte order.

The block has no inputs and no standard logic outputs. Values are read and written through the associated virtual device and the standard input and output blocks.

The first read from the device takes place after project initialization. Subsequent reads are performed cyclically, with the interval set by “Refresh interval [ms]”.

Configuration parameters

Parameter name Value
Name (name) Optional name displayed on the block in the editor. It is used as the default name of the associated virtual device.
Device model (deviceModel) Required selection of the ventilation unit model from a list populated when the form opens. In this version, the list contains Systemair SAVE. The selected model determines the allowed “RS485 configuration” settings.
Device address (deviceAddress) Required Modbus slave address. For Systemair SAVE, the allowed range is 1-247. The address must be unique among modbus-ventilation blocks using the same “RS485 configuration” selection.
Refresh interval [ms] (refreshInterval) Required time between consecutive read cycles in milliseconds. Allowed range: 1-3600000 ms.
Response timeout [ms] (responseTimeout) Required maximum time to wait for the device response in milliseconds. Allowed range: 10-60000 ms.
RS485 configuration (server) Required selection of a modbus-client configuration. In its editor, set “Baudrate”, “Parity”, and “Stop bits” according to the selected model's requirements below. RS485 settings must be consistent with the other Modbus blocks in the project.

For the Systemair SAVE model, the referenced RS485 configuration must meet the following requirements:

RS485 setting Requirement
Baudrate One of: 9600, 19200, 38400, 57600, 115200.
Parity None, Even, or Odd.
Stop bits Exactly 1 stop bit.

Write retries

The write retry limit is set by maxWriteAttempts in the selected modbus-client configuration in flows.json. This is a client setting, rather than a separate parameter of the modbus-ventilation block. It accepts an integer in the 0–65535 range or a string of digits, such as "3". It is independent of the read retry limit maxAttempts.

The value specifies the number of additional retries after the first attempt:

Retry limit Maximum number of attempts for one write
0 1
1 2
3 (default) 4
65535 65536

A missing field or an invalid value uses the default limit of 3 and does not by itself block the client configuration. Older flows without this field also use three additional write retries. Availability of the field in the editor form depends on deployment of support for this setting in the Node-RED nodes.

The shared limit is the highest maxWriteAttempts value across all modbus-client configurations in the current project. If all have 0, writes are not retried. With two clients set to 0 and 2, all writes can have two additional retries, including writes from the client set to zero. If there is no project or no client configuration, the limit is 3. Each new write receives its limit once; later configuration changes do not change the retries available to writes already waiting to be performed.

Retries cover property writes through the output block and the virtual device interface when confirmation times out, the device responds with an error, or the RS485 controller reports a communication error. Invalid data and local request preparation or send failures do not trigger further retries. Success ends the write immediately, without using the remaining attempts; retries do not guarantee success.

Other reads and writes, including those to other devices, wait until the current write succeeds or finally fails. A higher limit can therefore delay subsequent commands and data refresh. If confirmation is lost, the device may receive the same command again; execution exactly once is not guaranteed.

The ventilation unit state still comes from reads. Sending a command or receiving a write confirmation does not optimistically change the displayed value. The ventilation interface's own waiting time is not extended by this limit and, with a large number of retries, may expire before the write finishes.

Input handling

The modbus-ventilation block has no inputs and does not accept events from other blocks.

To read ventilation unit values, use the input block configured for a property of the associated virtual device. To change writable values, use the output block or the virtual device user interface.

Block outputs

The modbus-ventilation block does not expose standard logic outputs for further connections in the flow.

The ventilation unit state is exposed through the associated virtual device. For the Systemair SAVE model, the following properties are available:

Property Direction Description
relative_humidity RO Relative humidity in percent.
supply_fan_rpm RO Supply fan speed in rpm.
extract_fan_rpm RO Extract fan speed in rpm.
outdoor_air_temperature RO Outdoor air temperature in degrees Celsius.
supply_air_temperature RO Supply air temperature in degrees Celsius.
supply_air_temperature_setpoint RW Supply air temperature setpoint in degrees Celsius.
operation_mode RW Current ventilation unit operation mode.
manual_airflow_level RW Fan level in manual mode.

RO properties are read-only. RW properties can be read and written.

Values may be unknown. In the web interface, such a value is shown as null. In the mobile application, it is sent with the unknown status. In the input and output blocks, this means that the device is attached, but the current value of the property is not known at the moment.

If a function is not supported by the device model, the corresponding property is not exposed. For Systemair SAVE, all properties listed in the table are supported.

Supply air temperature setpoint

For the Systemair SAVE model, the supply_air_temperature_setpoint property has the range 12.0-30.0°C and the step 0.1°C.

A value outside the range is ignored and is not sent to the device. A value inside the range but not aligned to the step is rounded to the nearest 0.1°C step. Values exactly halfway between two steps are rounded up.

Writing a value does not optimistically change the local state. The new value becomes visible only after it is read back from the ventilation unit.

Operation mode

For the Systemair SAVE model, read operation modes may have the following values:

  • auto
  • manual
  • crowded
  • refresh
  • fireplace
  • away
  • holiday
  • cooker_hood
  • vacuum_cleaner
  • cdi1
  • cdi2
  • cdi3
  • pressure_guard

Writable values are:

  • auto
  • manual
  • crowded
  • refresh
  • fireplace
  • away
  • holiday

The other modes may be read from the device, but they are not set by the block in this version.

Manual airflow level

For the Systemair SAVE model, the manual_airflow_level property supports the following values:

  • low
  • normal
  • high

The off value is not supported in this version. If the device returns a level outside the supported list, the property changes to the unknown state.

Read error behavior

A single failed attempt of a Modbus read request does not remove the last valid value if retries are still available. The number of retries after the first attempt is configured through “Max attempts after error notification” in the modbus-client blocks and applies globally to the project. A final read failure after these retries are exhausted immediately makes the property being read unknown, without waiting for subsequent read cycles. Other properties retain their values.

With a global setting of 3 retries, a single request can have up to 4 attempts: the first attempt and three retries. After the fourth failure, the property being read immediately becomes unknown. A later successful read restores a valid value.

Invalid block configuration causes a configuration error and detaches the associated virtual device. A temporary communication problem with the ventilation unit does not detach the device if the block configuration is valid.

Errors returned by the block

The block can display the following error messages:

Error code Error description
Invalid name configuration. The “Name” parameter has an invalid type or format.
Invalid device model configuration. The “Device model” parameter is missing, empty, has an invalid type, or points to a model unsupported by the current block version.
Invalid device address configuration. The “Device address” parameter is missing, has an invalid type, or is outside the allowed range. For Systemair SAVE, the allowed range is 1-247.
Invalid refresh interval configuration. The “Refresh interval [ms]” parameter is missing, has an invalid type, or is outside the 1-3600000 ms range.
Invalid response timeout configuration. The “Response timeout [ms]” parameter is missing, has an invalid type, or is outside the 10-60000 ms range.
Missing RS485 configuration. The “RS485 configuration” parameter is missing, empty, or does not point to an existing modbus-client block.
Duplicated device address configuration. Another modbus-ventilation block uses the same “RS485 configuration” and “Device address” pair.
Invalid baudrate configuration. The common RS485 configuration does not contain a valid “Baudrate” value.
Baudrate configuration mismatch. The block uses an RS485 configuration inconsistent with other Modbus blocks in the project.
Systemair SAVE requires RS485 baudrate 9600, 19200, 38400, 57600 or 115200. The RS485 configuration uses “Baudrate” outside the list allowed for Systemair SAVE.
Invalid parity configuration. The common RS485 configuration does not contain a valid “Parity” value.
Parity configuration mismatch. The block uses “Parity” inconsistent with other Modbus blocks in the project.
Invalid stop bits configuration. The common RS485 configuration does not contain a valid “Stop bits” value.
Stop bits configuration mismatch. The block uses “Stop bits” inconsistent with other Modbus blocks in the project.
Invalid parity or stop bits configuration. The RS485 configuration combines “Parity” other than None with “Stop bits” set to 2, which is not allowed by the shared RS485 layer of the project.
Systemair SAVE requires RS485 stop bits 1. The RS485 configuration uses “Stop bits” other than 1.

Examples

  • With an effective write retry limit of 1, if the first attempt to set the supply air temperature setpoint to 21.5°C receives no response and the second receives a valid confirmation, the write succeeds. The new value becomes visible only after it is read back from the ventilation unit.
  • With the default effective limit of 3, if all four attempts of this write receive no response, the write ends with a final error. The displayed state still comes from reads, rather than the requested value.
  • To show the ventilation unit humidity in the logic project, configure the input block for the relative_humidity property of the associated modbus-ventilation device.
  • To set the supply air temperature setpoint to 21.5°C, send the numeric value 21.5 to the supply_air_temperature_setpoint property through the output block or the virtual device interface.
  • To switch the ventilation unit to refresh mode, set the operation_mode property to refresh.
  • If a supply air temperature read ends in failure after the globally configured retries are exhausted, the supply_air_temperature property immediately becomes unknown, without waiting for subsequent read cycles. The virtual device remains attached as long as the configuration is valid, and other properties retain their values. A later successful read restores a valid supply air temperature, even if it is the same as before the error.