Our customer requires to expose PI data through Modbus Slave (server) to a Modbus Master (client)?
Do you have existing C# code templates for that implementation?
You can interface the PI Data Archive to a Modbus server via the PI Interface for Modbus - read & write. PI Interface for Modbus Ethernet PLC (ModbusE) wICU Control 22.214.171.124 is released
Thank you Rhys but our case is the opposite situation. We wont to "wrap" the PI as slave (PLC for example) not as a master. The PI will contain tha data taht will be read from the modbus master application.
Found this library: nmodbus - A C# implementation of the Modbus protocol. - Google Project Hosting
connect that to the AFSDK and your're done! Although easier said than done...
Found out it moved to GitHub. So use this link: NModbus4/NModbus4 · GitHub
You are much better off having an off the shelf slave (from the application supplier?) and have a PI Interface feed data to the slave.
What is the Modbus master application?
Agree that anything off-the-shelf should have preference over somthing custom-built, it does matter when the Modbus Master needs to decide when to read data from PI, instead of PI deciding when data to write. But that's only a technical argument which is unlikely to hold up in many cases.
So here we go with the usual question: Varban: could you explain the use-case to us? Then we might be able to find a better approach to the problem.
Thank you guys. I only know that - The Pi will collect data from Modbus TCP master (the master will write data to the Pi). That is a initial research. I have hoped that ready for use OSIsoft solution exists but if need I will implement custom one. I will inform you when I have additional information.
Retrieving data ...