2/14/2012 4:14 PM | |
Joined: 11/26/2008 Last visit: 2/17/2012 Posts: 2 Rating: (0) |
Hello everybody, I have a question. Are we able to access to a MODBUS RTU (RS485) device from a controller S7-1200 using the PROFINET interface via MODBUS TCP-RTU gateway? You can see the architecture attached. It would be a great idea to implement a library. Regards. AttachmentMODBUS.pdf (1393 Downloads) |
2/16/2012 12:25 PM | |
Joined: 1/17/2007 Last visit: 10/21/2024 Posts: 1547 Rating: (537)
|
If you do want to go this route, then you can use an external Modbus TCP to Modbus RTU convertor. The one I have used in the past is the XPress-DR-IAP device from Lantronix. This is very easy to setup and works well. You will need the IAP version as that is the only one that supports loadable drivers (you will need to load in the modbus driver firmware which is available free of charge from the Lantronix website). |
Programming today is the race between software engineers building bigger and better idiot proof programs, and the universe producing bigger and better idiots. |
|
2/16/2012 3:13 PM | |
Joined: 10/7/2005 Last visit: 11/7/2024 Posts: 3026 Rating: (1056)
|
The answer is In principal yes, but the question is what Modbus on TCP/IP driverblock you intend to use in the S7-1200? The one I know if is available free of charge at Data Communication via Modbus/TCP with S7-1200 (CE-X22). I haven't used this one myself yet though, you will need to be aware of the following: Modbus on TCP/IP adds the so called "MBAP header" (MODBUS Application Protocol header) to the standard original Modbus message frame (you can download the Modbus spec at www.modbus.orgfor more on this). This header contains a so called "Unit Identifier" value. This value exist solely for the purpose of containing theModbus Slave address for Modbus serial devices that are located behind a Modbus TCP to Serial gateway. You will as such need to beable to stipulate this"Unit Identifier" value when you send outout your Modbus TCP/IP message, otherwise the TCP to serial Gateway will not know what to do with the message (well,it could put it on the Modbus serial line, but without a Slave address in it, noneof the Modbus serial devices will want to have it). I unfortunately can NOT tell you if the above linked Siemens Modbus TCP/IP driverBlock does allow to nominate the "Unit Identifier" when assembling the Modbus message (whose value is irrelevant if you communciate in a "pure" Modbus TCP/IP enviroment, so it may have been omitted from the Blocks configuration functionality). Perhaps someone else has the answer to this, if not I suggest you contact Siemens directly and let us know the answer. I hope this helps |
Cheers |
|
Follow us on