Hi Irfan,
You can use SAP PCo(Plant Connectivity), that can connect to OSISoft PI and ECC for a 2 way communication.
You can create a destination the corresponds to SAP ECC systems and an agent with Port type as SAP NW RFC Server.
Also, you can create OPC UA/DA/HDA type of agents to connect to OPC compliant shop floor systems like Scada, matrikon, etc.
Hope this helps.
Thanks,
Swaroop