Technical FAQs

Ask a Question

Can we change the Unit ID for Modbus TCP equipment in Runtime in Magelis HMI.

Yes, it is possible to change the Unit ID for Modbus TCP equipment configuration during Runtimer for Magelis HMI Tagrets using setProperty Methods.

This menthod of changing the Unit ID has been introduced in Vijeo Designer V6.2 onwards you cannot use this feature in previous as the parameter for changing Unit ID has not been implemented in previous version.

The script that is to be used to change the Unit ID is as follows:

int unitAddress = 255;          \\ to change the Unit ID 255

ModbusEquipment01.openConfig();

ModbusEquipment01.setProperty("Con_UnitNumber", unitAddress);

ModbusEquipment01.commitConfig();

You can use the above script assigned on any button and as the button is pressed new Unit ID will take into account.

 

Was this helpful?
What can we do to improve the information ?