Schneider Electric support forum to share knowledge about product selection, installation and troubleshooting for EcoStruxure Panel Server, PowerTag, Com'X, Link150…
Send a co-worker an invite to the portal.Just enter their email address and we'll connect them to register. After joining, they will belong to the same company.
You have entered an invalid email address. Please re-enter the email address.
This co-worker has already been invited to the Exchange portal. Please invite another co-worker.
Please enter email address
Send InviteCancel
Invitation Sent
Your invitation was sent.Thanks for sharing Exchange with your co-worker.
Link copied. Please paste this link to share this article on your social media post.
2013-08-2209:40 PM
Who's afraid of Python - Part II
In my last post about the Python script, I wrote about a very simple, two lines of Python script to be used in EO charts in order to remove the meter classification from the legend.
Unfortunately this feature was removed from the platform, at least for us, the mortals.
But learn Python is not a waste of your time at all, at least in our context here because of few reason:
Python is fun, free and simple
You can transform unsupported file formats and import this data to EO.
You can write a small script in EODC in order to industrialize the import process
This week I received our colleagues from UK and Greece in Grenoble to teach them how to commission a tenant. Among other tasks, of course there is the data import process. As you may know, UK massively uses the ERM platform to provide services in the country. And one of their source of meter data is a file that is sent from Invensys to their server. ERM handle the file automatically and generate meter data.
But how to consume such file in EO? The answer is simple, write an script in Python, test it, port it to EODC and install a new job.
So I decide to make an experiment to try to do this exercise. The final result was a tiny, readable, portable and efficient program. Check the source code in the attached file
The meter data file looks like our CMEP format, an meter identification, a initial data and several data points (12 in fact since the demand interval in UK is 30 minutes) and a flag for each measure (A=Actual, E=Estimated).
After running the script in my PC, it generates a Vizelia CSV file format. So, before was a file with horizontal information and now the same data but in a vertical shape.
2010-06-26T00:30:00,"34.6",METER_1507659320039
2010-06-26T01:00:00,"33.7",METER_1507659320039
At the end of the file I insert, for convenience, the number of data points and the meters that was found inside the file, so the application engineer can easily use such id’s in the commissioning tool to create them.
2013-06-19T23:30:00,"11.8",METER_1700051519478
2013-06-20T00:00:00,"11.7",METER_1700051519478
--- Done! --------- Cut Here ----------
345984 measurements found in 7 meters
--------- meter names ------------
METER_1507659320039
METER_1620001671458
METER_1300037714369
METER_1300053364728
METER_1300053364658
METER_1460001876631
METER_1700051519478
The next steps for this are:
Tweak the script to handle the input arguments as source file, output file name, etc. Today the input and output file name are hard coded. I’m inside the train heading to Paris, not in a mood now.
Ignore the last topic and port the code to be used inside EODC so we can industrialize the process.
Is there anyone out there willing to help? Just download Python to your machine and try it. If you need any help, just ask my help.