Engee documentation

Arduino-modbusWrite

Writing values to the internal Modbus register card of the server.

blockType: CFunction

Path in the library:

/Interfaces/Targets/Arduino/Arduino-modbusWrite

Description

To work with the block, install/update the support package. equipment.

Block Arduino-modbusWrite writes values to the internal Modbus register card of the server.

To use this unit, you must first configure the Modbus parameters of the server and the data link. To configure them, use the block Arduino-modbusSetup.

Ports

Input

# conn — connection descriptor
true | false

Details

Waiting to exit the block Arduino-modbusSetup.

Data types

Bool

Complex numbers support

No

# data — data
scalar

Details

A recordable bit (Coil) or 2 bytes (Register).

Data types

Bool, UInt16

Complex numbers support

No

Parameters

Main group

# Функция: — Modbus recording function
Write Coil | Write Discrete Input | Write Holding register | Write Input register

Details

Modbus recording function.

Values

Write Coil | Write Discrete Input | Write Holding register | Write Input register

Default value

Write Coil

Program usage name

m_function_name

Tunable

No

Evaluatable

Yes

# Адрес: — the address for writing a bit or register to the Modbus server’s internal register card

Details

The address for writing a bit or register to the Modbus server’s internal register card.

The address space is divided into 4 groups:

  • 00009999 for Write Coil;

  • 1000019999 for Write Discrete Input;

  • 3000039999 for Write Holding register;

  • 4000049999 for Write Input register.

Default value

30000

Program usage name

m_address

Tunable

No

Evaluatable

Yes

# Шаг расчёта: — the period from which the block will be called

Details

The period for which this block will be called.

Default value

-1

Program usage name

sample_time

Tunable

No

Evaluatable

Yes