SCADA Integration with SAP using SAP PI – Part 3 –Interface
In my previous blogs, we saw Systems Integration and how they communicate in exchanging Tag values using a testing tool. Let me discuss about the Interface with actual systems involved. I mean Sap ERP TSW, SAP PI, OPC Gateway Systems, and SCADA Servers (OPC Server). Based on the two previous blogs I hope you got an idea on systems involved.
If you look in to the Business Case, Interface was demanding communicate with Decentralised SCADA servers. They were 10 instances of SCADA Servers in the Landscape, primarily provided by INVENSYS and TELVENT. All the instances will contain same Tags and Values based on the periodic synchronization of the instances. Our requirement was to fetch the values for specific tags based on the availability of the instances. There were some primary instances which will be given priority and rest of them as redundant instances.
In ERP TSW module this Read Interface has to be executed at a scheduled time every day to get the Tag values and store it in Z Tables. These values are utilized by the module to finalise Allocations, based on which Ticket Creation, Delivery Creation and Billing Creation happens [Refer IMG 1.1: Business Process] in my first blog of this series.
So to fetch the tag values in ERP all the Tags relevant to the SCADA server instances are stored in Z Table and used to create a proxy request for Read operation with the relevant tags.
Onward Journey -->
- In ERP - TSW module a background program which executes every day at scheduled time sends a client proxy request containing SCADA TAG’s to SAP PI.
- In SAP PI Read Interface is executed which receives client proxy request and transforms message using operation mapping.
- Resultant of this mapping will be mapped as an Operation – Message called ReadSoapIn of Web Service provided by OPC GATEWAYs.
- Using conditional routing in Read Interface, SAP PI sends to ReadSoapIn operation to available OPC GATEWAY using a SOAP request.
- In OPC GATEWAY a corresponding Web Service will receive SAP PI’s ReadSoapIn request, and sends the request to OPC SERVER in SCADA using .NET program and COM/DCOM technology.
<-- Return Journey
- OPC SERVER processes the request and reads the values related to the requested TAG’s, and sends response back to OPC GATEWAY.
- OPC GATEWAY will send the response using Operation – Message ReadSoapOut to SAP PI.
- SAP PI receives the response using ReadSoapOut Message, this message gets transformed to ERP client proxy response.
- ERP client proxy program update relevant table with TAG Values for all OPCSERVERS available.
TAG Values in table will be used for finalizing allocations, ticket creation, delivery and billing.
Now will see abstract of objects which are needed in SAP PI.
Sender and Receiver Message Structures with Mappings in PI:
In ERP a program controls the flow of Interface, to which Gateway and to which SCADA (OPC Server) request is sent. Based on the source field value the receiver OPC Gateway is determined, and Web Service specifically running for particular OPC Server will be triggered in OPC Gateway based on the request XML.
Receiver Communication Channel:
XML - Request:
XML – Response
I hope this blog series helped you in understanding SCADA systems integration with SAP.