CODESYS - the IEC 61131-3 automation software

Welcome to the official CODESYS Forum by 3S-Smart Software Solutions GmbH | A member of the CODESYS Group
Deutsche Version English version russian version 
It is currently Wed Oct 23, 2019 11:04 am

All times are UTC+01:00




Post new topic  Reply to topic  [ 4 posts ] 
Author Message
PostPosted: Mon Mar 05, 2012 5:00 pm 
Offline

Joined: Wed Feb 22, 2012 2:29 pm
Posts: 7
Is is possible with Python to get detailed information of a property (of a function block) without exporting int in XML:
1. type INT or DINT
2. read-only, write-only, readwrite
3. commentary of property


Is it possible to import a property and its commentary via XML ?


Top
   
PostPosted: Mon Mar 05, 2012 5:29 pm 
Offline
Frequent User
Frequent User
User avatar

Joined: Fri Mar 18, 2011 4:12 pm
Posts: 266
Hi,

Lohr_DCIA-EHE1 wrote:
Is is possible with Python to get detailed information of a property (of a function block) without exporting int in XML:
1. type INT or DINT
2. read-only, write-only, readwrite
3. commentary of property


Currently, this is not yet possible.

Quote:
Is it possible to import a property and its commentary via XML ?


It should be possible to import and export everything the same way as you can import and export via the UI, using the "Project/Import PLCOpenXML" and "Project/Export PLCOpenXML" commands.

That said, it seems currently impossible to export a Property without the "parent" POU. But I'm not an expert on PLCOpenXML, and so cannot give a definitive answer on that.

HTH,
Markus

_________________
Check out the CODESYS store: http://store.codesys.com/

CODESYS® a trademark of 3S-Smart Software Solutions GmbH
Inspiring Automation Solutions


Top
   
PostPosted: Tue Mar 06, 2012 4:52 pm 
Offline

Joined: Wed Feb 22, 2012 2:29 pm
Posts: 7
Thank for your helpful answer

Our problem is that we generate a parameter csv-file from an access database and then want to import the parameters as properties of a FB via XML into a Codesys project. In this project parameters shall be modified, deleted or added. It shall be prevented, that unmodified properties will be overwritten, because that changes the signature.

In your reply to my first question yo said it is not possible to read the details of a property via script.

But is there a possiblity to control the signature of a property?

It would be easy for us to delete all the properties and than replace them with the new ones from the database, but keep the signatures of the unchanged properties.


Top
   
PostPosted: Tue Mar 06, 2012 5:07 pm 
Offline
Frequent User
Frequent User
User avatar

Joined: Fri Mar 18, 2011 4:12 pm
Posts: 266
Hi,

Currently, there are no POU-specific commands available to the scripts. So it is not possible to manipulate properties in any way except the "generic" ones which work for all objects: Import, export, rename, delete, ... Only Devices, Applications and Library Managers have a specific scripting API so far.

However, it should be relatively easy to implement this, at least for properties implemented in textual languages like ST. (I currently have no idea of how to create a simple scripting API for the manipulation of graphical programming languages.)

You could try to file this as a requirement via our support department, and then it will be implemented eventually. If you have an Automation Platform license, you could even write a ScriptDriver implementing this yourself.

Markus

_________________
Check out the CODESYS store: http://store.codesys.com/

CODESYS® a trademark of 3S-Smart Software Solutions GmbH
Inspiring Automation Solutions


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 4 posts ] 

All times are UTC+01:00


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Limited