![]() |
|
UCM/Modbus as Slave - Printable Version +- Comfort Automation/ Security System Forums (https://www.comfortforums.com) +-- Forum: Third Party (interfacing to Comfort) (https://www.comfortforums.com/forum-5.html) +--- Forum: UCM/Modbus (https://www.comfortforums.com/forum-133.html) +--- Thread: UCM/Modbus as Slave (/thread-4669.html) |
- slychiu - 03-30-2017 In UCM/Modbus Properties, set Modbus Master/Slave as Slave. Modbus Slave ID in this mode is the Modbus ID of the UCM/Modbus. The other Tabs Modbus > Comfort and Alarm> Modbus are not applicable in this mode. In this mode, third party devices and software are able to control Comfort by sending commands and getting responses. UCM/Modbus is a Slave and the Modbus device is Master. In Comfigurator, the Modbus Master/Slave is set to Server/Slave. The Modbus ID field applies to the UCM/Modbus Modbus ID as a Slave. The following Modbus functions are supported Function Code Function Parameters 1 Read Coils Read from starting address, no of addresses 2 Read Discrete Inputs Read from starting address, no of addresses 3 Read Holding Registers Read from starting address, no of addresses 4 Read Input Registers Read from starting address, no of addresses 5 Write Single Coil Write from Address, Value 6 Write Holding Register Write from Address, Value Write Multiple Coils and Write Multiple Holding Registers are not supported When Modbus Slave is selected, the screen below should be seen in the Modbus Server Tab This is a convenient lookup reference table which shows the Modbus Addresses in Decimal and Hexadecimal format of all the Comfort events and registers that are exposed to Modbus. ![]() Each of the items above is a Category that can be expanded by selecting the item Zones/Inputs Comfort Zones/Inputs are mapped to Modbus discrete Inputs ![]() Outputs Comfort Outputs are mapped to Modbus Coils ![]() Flags Comfort Flags are mapped to Modbus Discrete Inputs ![]() Bypass Inputs Bypass Inputs are mapped to Modbus Coils. ![]() Counters Comfort Counters are mapped to Modbus Holding Registers ![]() ![]() Sensors Comfort sensors are mapped to Modbus Holding Regsters ![]() Security/Keypad commands Key arm security and Autoarm security commands to Comfort are mapped to Holding Registers ![]() - slychiu - 03-30-2017 Notes for Modbus/TCP Slave Mode For Modbus/TCP, the Modbus Master is also referred to as Client, and the Slave as Server. A Modbus/TCP Slave has an IP address and Port. The Modbus/TCP Master (which is the other device communicating with the UCM/Modbus) should set the Target IP and Port to the UCM/Modbus. For Modbus/TCP, the Modbus Master is also referred to as Client, and the Slave as Server. A Modbus/TCP Slave has an IP address and Port. The Modbus/TCP Master (which is the other device communicating with the UCM/Modbus) should set the Target IP and Port to the UCM/Modbus. If Modbus/TCP is used for the Server/Slave, the Properties page shall show a link to Comfort Server Manager The Comfort Server Manager screenshots below show Modbus Slave (10.0.0.188), along with other ETH03 which may be in the same network (which can be ignored). Note that the Modbus ETH03 should show Universal firmware 1.16 For the UCM/Modbus Slave, select the ETH03 on the left pane. Look at the IP address parameters on the right pane. ![]() DHCP checkbox ââ¬â This determines if the IP address for UCM/Modbus is to be assigned automatically by the DHCP server. For Transport Protocol, select ââ¬ÅTCPââ¬Â. For Routing Mode, select ââ¬ÅServerââ¬Â. In Port 1, select the port number of the UCM/Modbus Server/Slave. For the other modbus device which acts as the Master (client), enter the IP Address and Port number of the Slave (Server), in this example, 10.0.0.188 Port 1005. This will allow the external Modbus Master to talk to the Modbus Slave via the IP address and Port. Note that the Modbus Master must also comply to the Modbus/TCP standard in order to work with UCM/Modbus as Slave. - slychiu - 12-11-2017 QModbusMaster is an excellent software tool for testing UCM/Modbus in Slave Mode Download from https://sourceforge.net/projects/qmodmaster/ This can work in RTU (RS485) and TCP Mode to complement UCM/Modbbus in RS485 and TCP Mode ![]() There is also a related tool for simulating Modbus Slave https://sourceforge.net/projects/pymodslave/ This can be used for testing UCM/Modbus in Master Mode. It also works in RTU (RS485 ) and TCP mode |