Giter VIP home page Giter VIP logo

Comments (17)

darkjhesus avatar darkjhesus commented on August 15, 2024

Could you share the python library, I have problems trying to compile in python 3.6. When I impot the module I get the next error: ImportError: DLL load failed: No se puede encontrar el módulo especificado

Could you help me?

from libiec61850.

libusr avatar libusr commented on August 15, 2024

I have a version for Python 3.7, feel free to use it.
Note that with this build the original problem regarding the utilization of the control operation remains unsolved.
20190826_libiec61850_py37.zip

from libiec61850.

darkjhesus avatar darkjhesus commented on August 15, 2024

Dear libusr, What is the OS thaht you use with python, Windows 32 64 bits or Linux?

from libiec61850.

libusr avatar libusr commented on August 15, 2024

I'm running it on Win10, 64 bit.

from libiec61850.

darkjhesus avatar darkjhesus commented on August 15, 2024

Maybe do you have some example to read comtrade files from IED??

from libiec61850.

libusr avatar libusr commented on August 15, 2024

Sorry, no example for this function yet.
But I would also be interessted in the solution. Please share

from libiec61850.

darkjhesus avatar darkjhesus commented on August 15, 2024

I am trying to develope some code to do this but I don't know how to use the function iec61850.LinkedList_destroyDeep.
Maybe have you ever work with this function?

from libiec61850.

libusr avatar libusr commented on August 15, 2024

I'm only familiar with the *.LinkedList_destroy function, which is part of the Python client example. No need for destroyDeep in my use cases.

from libiec61850.

darkjhesus avatar darkjhesus commented on August 15, 2024

Dear, I implement another method and it is succefull, but I am getting the next data:
'\udcd0\udcf2\udcee\x0f\udcb9\n'
'p\udcf0\udcee\x0f%\udc93'
'p\udcf3\udcee\x0f\udc89\n'

These values are one in each iteration.

The code implemented is:
folList = iec61850.IedConnection_getFileDirectory(con,'')
direcEntry = iec61850.LinkedList_getNext(folList[0])
while(direcEntry != None):
aux1 = direcEntry.data

I would like to know how could I convert this data to string.?
Sin título

from libiec61850.

slemadin avatar slemadin commented on August 15, 2024

It seems that we are working on the same thing. I used your code and file-tool.c to make something that should work but I still have a problem:

	rootdir = iec61850.IedConnection_getFileDirectory(con,'')
	iec61850.LinkedList_printStringList(rootdir[0])
	direcEntry = iec61850.LinkedList_create()
	direcEntry = iec61850.LinkedList_getNext(rootdir[0])
	while direcEntry:
		#FileDirectoryEntry entry = (FileDirectoryEntry) direcEntry.data
		print(iec61850.FileDirectoryEntry_getFileName(direcEntry.data))
		direcEntry = iec61850.LinkedList_getNext(direcEntry)

The commented line is the one that should be translated to python (right now it is just c/p from C). I don't seem to be able to create FileDirectoryEntry because no such function is available in iec61850.py, and the FileDirectoryEntry_create(fileName, fileSize, lastModified) requres arguments that I can't give because they are what I want to get in the first place. Documentation says it's deprecated and will be removed from API.

Any ideas?

from libiec61850.

darkjhesus avatar darkjhesus commented on August 15, 2024

I couldn't solve the problem showed above, I finally had to use the C# library.

from libiec61850.

darkjhesus avatar darkjhesus commented on August 15, 2024

You could write to my mail [email protected]

from libiec61850.

ogunozfidan avatar ogunozfidan commented on August 15, 2024

It seems that we are working on the same thing. I used your code and file-tool.c to make something that should work but I still have a problem:

	rootdir = iec61850.IedConnection_getFileDirectory(con,'')
	iec61850.LinkedList_printStringList(rootdir[0])
	direcEntry = iec61850.LinkedList_create()
	direcEntry = iec61850.LinkedList_getNext(rootdir[0])
	while direcEntry:
		#FileDirectoryEntry entry = (FileDirectoryEntry) direcEntry.data
		print(iec61850.FileDirectoryEntry_getFileName(direcEntry.data))
		direcEntry = iec61850.LinkedList_getNext(direcEntry)

The commented line is the one that should be translated to python (right now it is just c/p from C). I don't seem to be able to create FileDirectoryEntry because no such function is available in iec61850.py, and the FileDirectoryEntry_create(fileName, fileSize, lastModified) requres arguments that I can't give because they are what I want to get in the first place. Documentation says it's deprecated and will be removed from API.

Any ideas?

Hello, I'm having the same trouble. I need to create a FileDirectoryEntry object but the is no class defined in the Python library. When I check if it is defined in the C library. It says it will be removed.

Have you been able to solve the issue?

typedef struct sFileDirectoryEntry* FileDirectoryEntry;
/**

from libiec61850.

slemadin avatar slemadin commented on August 15, 2024

I modified C code from one of the examples to fit my needs and ran compiled .exe from Python.

from libiec61850.

ogunozfidan avatar ogunozfidan commented on August 15, 2024

Could you give me some details when you're available. I'm pretty new at this. Thank you.

from libiec61850.

Herve3 avatar Herve3 commented on August 15, 2024

To solve this probleme I added:

FileDirectoryEntry toFileDirectoryEntry(void *data){
      return (FileDirectoryEntry) data;
 }

and

FileDirectoryEntry toFileDirectoryEntry(void *);

in iec61850.i and then recompile the library

with this modification this python code is running:

[rootDirectory, error] = iec61850.IedConnection_getFileDirectory(con, "")
directoryEntry = iec61850.LinkedList_getNext(rootDirectory)
while directoryEntry:
	entry = iec61850.toFileDirectoryEntry(directoryEntry.data)
	file_name=iec61850.FileDirectoryEntry_getFileName(entry)
	print(file_name)
	directoryEntry = iec61850.LinkedList_getNext(directoryEntry)

from libiec61850.

jeslorena avatar jeslorena commented on August 15, 2024

How can I utilize the control operation with Python?
Help me please

from libiec61850.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.