Ask Me About Webinar: Data Center Assets - Modeling, Cooling, and CFD Simulation
Join our 30-minute expert session on July 10, 2025 (9:00 AM & 5:00 PM CET), to explore Digital Twins, cooling simulations, and IT infrastructure modeling. Learn how to boost resiliency and plan power capacity effectively. Register now to secure your spot!
HVAC and Pumping Forum
Support Forum for HVAC and pumping machines, Modicon M17x and EcoStruxure Machine Expert HVAC software for chillers, AHU, CRAC units for datacenters or process chillers applications - from design, implementation to troubleshooting and more, by Schneider Electric.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2025-08-08 09:57 AM
I have an M172P running as a Modbus RTU Master on RS485-2, connected to an RTU device, and SUCCESSFULLY reading data from the device.
Knowing the Modbus RTU Unit ID of the device, I can set it in the 'Modbus Address' field of the Modbus Device Node for the RS485-2 resource in the Resource tree, rebuild, download, and run. No problems here.
What I want to do is change the Unit ID (Modbus Address) at runtime, either on-the-fly, or at least during initialization (in the Init task) or at reboot (in the Boot task). For example: save the desired Modbus Address as an EEPROM parameter (ex. DEVICE_UNITID), then in the Init task, so something like:
sysMbMRtuNodeStatus[0].addr_1 := DEVICE_UNITID;
This throws an compiler error, presumably because sysMbMRtuNodeStatus is R/O, or addr_1 is R/O.
INIT(5) - error G0008: sysMbMRtuNodeStatus[0].addr_1 => Invalid access to variable
I will assume that doing the same operation in response to an HMI button would also not work
Is there any way to update the Modbus Address (Unit ID) that an Modbus RTU Device Node is using at runtime? Specifically, is there any way OTHER than doing MB RTU master requests from a program (where the modbus request function blocks could take an arbitrary Modbus Address (unit ID)) ?
Thanks!
Details:
Machine Expert HVAC 1.6.0
Target: M172P, BIOS 596.14
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2025-08-18 07:42 AM
Hi,
It is not possible to change the ID node at run time using modbus messages in Configuration.
But it is possible to change the ID node at run time using the modbus on event mode with FBs dedicated for modbus master communication.
In attachment a modbus module to present how to use both mode of modbus communication. Modbus on event is showed starting from slide 7.
BR
Marco Cervati
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2025-08-18 07:42 AM
Hi,
It is not possible to change the ID node at run time using modbus messages in Configuration.
But it is possible to change the ID node at run time using the modbus on event mode with FBs dedicated for modbus master communication.
In attachment a modbus module to present how to use both mode of modbus communication. Modbus on event is showed starting from slide 7.
BR
Marco Cervati
Link copied. Please paste this link to share this article on your social media post.
Create your free account or log in to subscribe to the board - and gain access to more than 10,000+ support articles along with insights from experts and peers.