This script will parse your CSV and enter it into the ignition historian with your RTU timestamp.
#convert the csv into an ignition dataset
import csv
path = system.file.openFile("csv")
if path != None:
f = open(path,'rb')
reader = csv.reader(f)
csvlist = list(reader)
ds=[]
row = 0
for x in csvlist:
if row == 0:
headers = x
if row > 0:
ds.append(x)
row += 1
csvdataset = system.dataset.toDataSet(headers, ds)
#parse the dataset and enter the data into the historian
for row in range(csvdataset.rowCount):
tagname = csvdataset.getValueAt(row,'tag')
tagvalue = int(csvdataset.getValueAt(row, 'intvalue'))
tagtimestamp = system.date.fromMillis(long(csvdataset.getValueAt(row, 't_stamp')))
tagquality = 192
system.tag.storeTagHistory("ign_historical","default",[tagname],[tagvalue],[tagquality],[tagtimestamp])
Agreed. Whom can you trust?. Police(aka NSA) is the thief here. Threat is the feeder for security business like virus is the lifeline for anti-virus and so on. All Governments collect data. Weaker and corrupt Governments happily export their people and data to USA. Privacy is the biggest joke in social media. No more holy cows. Mark Zuckerberg must be ROFLing
Privacy and Data security is an excellent opportunity for Government authorities of slave nations to make some fast bucks. Data is for the people. When they are eagerly waiting with a broad smile to export their people to USA, what are they going to do with their private data?. Throw few more bones, they will sell 2 for 1. They will happily sell the remaining surplus useless population, dime a dozen, to big pharmaceutical giants for Bio research, develop drugs and Health care services for mankind
I suggest, ask your team to dig deeper and build your own driver for AB and SIEMENS. All PLC drivers communicate on the basis of request/response cycle. MODBUS is the mother of all PLC/RTU protocols. You can build your driver framework for MODBUS TCP and use it to build other drivers.
It runs on ARM architectures too. Iâm using it to send data from renewable plants to the Cloud and it works fine. The neat feature is not just it runs on Linux, but also the GUI is Web (HTTPS => bye, bye RDP).
Not as many protocols as Kepserver but enough for my projects.
I have developed with FreeOpcUa. It creates an OPC server endpoint and contains all the methods to create the folders, objects, and nodes. The challenge is to develop the driver for the target device (i.e. the plc), obtain the data from the device, then leverage the methods provides by FreeOpcUa to share the data with the serverâs clients. In my project, I created an OPC server with FreeOpcUa that converted restful APIs to OPC-UA resulting in the client skipping all the API calls and instead connecting to the OPC-UA server and subscribing to the tags for the data.