How to read and write some registers of a client machine over ModBus TCP/IP on Simulink.
4 次查看(过去 30 天)
显示 更早的评论
Hi, my name is Daniel, and I’m trying to read and write some vales from some MODBUS TCP registers from a converter with simulink blocks.
I have achieved it using Matlab functions and with the "Interpreted Matlab function" block, through the write and read functions. But this works quite slow.
Is there a way where I can read and write to certain registers from simulink using MODBUS?
I have tried several Matlab blocks, but I am not able to read or write the desired registers (i.e. dir. 17000, 16856 ..)
Thank you very much in advance.
All the best.
Daniel
0 个评论
回答(1 个)
Shiva Kalyan Diwakaruni
2021-5-6
Hi,
In the Modbus TCP/IP Slave Read block, the slave device reads data from its registers. notify the slave to read data from a specific discrete input register, specify the discrete input register address in this parameter. For example, for the slave to read data from the discrete input register with the address 80, enter 80.
Dependencies
To enable this parameter, set Function to Read Discrete Input.
Check the paramter section in below links to know more
Hope it helps.
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Modeling 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!