1

I have here a unit of King Pigeon S275 Remote Terminal Unit.. this RTU has communication modules for GSM, GPRS and TCP/IP (via RJ45 connection) I can also communicate with this RTU by connecting it to my computer via USB .

The Manual I uploaded in this link... https://www.mediafire.com/?gnfzfz5l7pess1p

This RTU can be configured using a configurator Software that is included in the purchase. By using that configurator software, you can also see the data/readings of all sensors connected to it, you can also see the status of all Digital Input/contacts connected to the RTU...

I have been researching about MODBUS the past days and I would like to create my own MODBUS program so that the S275 RTU can also send the sensors' data, or all the I/O data to my own program....

However ... I still do not know where I can start ... Can I make this Modbus Program 1. using VB? 2. using PHP?

What other parameters do I need to know ? and tutorials for making this modbus software...

I also uploaded here the S275's; 1. GPRS Custom Protocol 2. MODBUS TCP Handshake Communication Protocol 3. Register Address

https://www.mediafire.com/?khnfu53a4p12nrd

Thanks

4 Answers4

0

PHP and ModBus sounds challenging. You want to control a serial port via PHP.

The easiest way is to get/purchase a library for ModBus/RTU. Otherwise you have to implement the whole protocol by yourself from http://www.modbus.org/specs.php

0

You can use nmodbus API to add how reference in your VB or C# project. There you have the manual. Supports serial ASCII, serial RTU, serial over USB ASCII, serial over USB RTU, TCP, and UDP protocols.

joreldraw
  • 1,736
  • 1
  • 14
  • 28
0

These kinds of RTU’s are pretty inexpensive which means your greatest cost will be the time you will spend developing and debugging a driver. With that in mind I would first check if the RTU comes with its own OPC Server. Implementing an OPC client in C# or vb.net is very straight forward with plenty of code example out there. Some examples can be found here: https://opcfoundation.org/developer-tools/developer-kits-unified-architecture/-net-stack-and-sample-applications/

If the RTU does not come with its own OPC server then, you can purchase a Modbus OPC Server from $900 to $2000 which will still be much more cost effective than writing and debugging your own driver and tends to be easier to setup. It will also significantly reduce the time to deliver your solution to your end customer which will be important if keep to project schedule is critical. I would check out, https://www.kepware.com/ and http://www.matrikonopc.com/

The other advantage of OPC is that it is a standardized interface which means should the RTU be replaced with a different model that supports a different protocol you would only have to purchase a new OPC server without the need to update your source code.

If the RTU does not have an OPC server or spending up to $2000 also not an option then there is plenty of open source implementations of the Modbus protocol, however implementation tends to be a bit more complex.

Edmond Quinton
  • 1,709
  • 9
  • 10
0

No problem, I used PHPModBus in several projects and it works like a charm!

This library supports Modbus TCP and UDP.

Try it, it is quite easy and straightforward.

WeSee
  • 3,158
  • 2
  • 30
  • 58