Comfort  Automation/ Security System Forums Home
Home Search search Menu menu Not logged in - Login | Register

UCM/Modbus Master - Number of Registers
 Moderated by: slychiu
 New Topic   Reply   Printer Friendly 
 Rate Topic 
AuthorPost
 Posted: Sunday Sep 25th, 2022 02:47 am
   PM  Quote  Reply 
1st Post
slychiu
Administrator


Joined: Saturday Apr 29th, 2006
Location: Singapore
Posts: 5511
Status: 
Offline

  back to top

Using UCM/Modbus 7.167 and Comfigurator 3.13.7 and above, each modbus entry in Modbus to Comfort can have Number of Registers from 1 to 16, as shown below


This means that multiple modbus slave registers can be polled in one command. For example in the above screenshot example on the 1st line, Modbus address 0 Discrete Input  and mapped to Flag 21.  No of Registers = 5 means that  5 sequential Modbus registers are mapped to 5 sequential Flags.
eg
  1. Modbus address 0 -> Flag 21
  2. Modbus address 1 > Flag 22
  3. Modbus address 2 > Flag 23
  4. Modbus Address 3 > Flag 24
  5. Modbus Adress 4 > Flag 25
These modbus addresses must be the same type eg Discrete Inputs
This allows the Modbus Master to poll the slave very fast and reduces the number of Modbus to Comfort Table entries. The above example required 5 entries before, but nopw only requires 1 entry in Modbus to Comfort



 Posted: Saturday Dec 17th, 2022 10:29 am
   PM  Quote  Reply 
2nd Post
Elyas Riahi
Member
 

Joined: Saturday Dec 17th, 2022
Location:  
Posts: 4
Status: 
Offline

  back to top

Dear Friend,Many thanks for your new feature support,
When we select No of registers more than 1 on modbus element addition,Does Configure use   function codes 0x10 and 0x16 for read and write multiple registers on master mode?BR



 Posted: Sunday Dec 18th, 2022 01:02 am
   PM  Quote  Reply 
3rd Post
slychiu
Administrator


Joined: Saturday Apr 29th, 2006
Location: Singapore
Posts: 5511
Status: 
Offline

  back to top

Only READ Multiple registers is supported, not WRITE multiple registers. Read Multiple registers for Coils, Holding Registers, Discrete Inputs, Input Registers is useful as it allows the Modbus Master to Poll the items in the Modbus to Comfort table.

Write Multiple registers is not useful as registrs dont all change at the same time. When any registyer mapped to comfort in the Modbus to Comfort table changes there is an immediate Write to Modbus for the Single Register. I  hope that answers your question.



 Posted: Sunday Dec 18th, 2022 04:52 am
   PM  Quote  Reply 
4th Post
Elyas Riahi
Member
 

Joined: Saturday Dec 17th, 2022
Location:  
Posts: 4
Status: 
Offline

  back to top

Thanks Dear for your reply,
But i have a problem ,
One of our device not support write single holding register write function code,
It only support write multiple holding register function code,,
Have you any solve?



 Posted: Sunday Dec 18th, 2022 05:24 am
   PM  Quote  Reply 
5th Post
slychiu
Administrator


Joined: Saturday Apr 29th, 2006
Location: Singapore
Posts: 5511
Status: 
Offline

  back to top

It is s not likely that any modbus slave device will support Write multiple register but not Write single register. Do you have the instruction manual of that device?



 Posted: Sunday Dec 18th, 2022 05:29 am
   PM  Quote  Reply 
6th Post
Elyas Riahi
Member
 

Joined: Saturday Dec 17th, 2022
Location:  
Posts: 4
Status: 
Offline

  back to top

Yea, i see
But this device just support write multiple registers,i tested it several times with 0x06
Not work,it only work with (0x10) or 16 decimal



 Posted: Sunday Dec 18th, 2022 05:34 am
   PM  Quote  Reply 
7th Post
slychiu
Administrator


Joined: Saturday Apr 29th, 2006
Location: Singapore
Posts: 5511
Status: 
Offline

  back to top

That is a problem for that device. All modbus devices should work with write single registers. They do not have to work with write multiple registers. The device will not be able to work with many other modbus masters. Do you have the instruction manual? 



 Posted: Sunday Dec 18th, 2022 08:52 am
   PM  Quote  Reply 
8th Post
Elyas Riahi
Member
 

Joined: Saturday Dec 17th, 2022
Location:  
Posts: 4
Status: 
Offline

  back to top

No. i have not.I tested this device with modbus poll too,this work only with multiple register write function(16)



 Posted: Monday Dec 19th, 2022 12:31 am
   PM  Quote  Reply 
9th Post
slychiu
Administrator


Joined: Saturday Apr 29th, 2006
Location: Singapore
Posts: 5511
Status: 
Offline

  back to top

That device you are using does not seem to be a proper modbus Slave. All slaves should work with a master which sends write 1 register which is a standard Modbus command. I suggest you contact the other menufacturer, or use another Modbus ndevice



 Current time is 08:44 am
Top




UltraBB 1.172 Copyright © 2007-2014 Data 1 Systems