Giter VIP home page Giter VIP logo

Comments (8)

mzillgith avatar mzillgith commented on August 15, 2024

Indeed there is a memory leak because of a missing destructor for ReportControlBlock and so the native resource is not released. Should be fixed now.

Anyway this is a really strange behavior of the device. The device should not disable the report control block and this kind of polling should not be required. Because the idea of reporting is to avoid the need for polling. Do you know why the device behaves like this?

If it is really required I would recommend to put the line
ReportControlBlock report = connection.GetReportControlBlock(address);
outside of the while loop. This way you would avoid creating a new instance of ReportControlBlock for every request. Or polling the RptEna attribute with ReadValue as you suggested would be an even more simple solution.

from libiec61850.

IgorMundstein avatar IgorMundstein commented on August 15, 2024

Indeed there is a memory leak because of a missing destructor for ReportControlBlock and so the native resource is not released. Should be fixed now.

Ok. I will test it.

Anyway this is a really strange behavior of the device. The device should not disable the report control block and this kind of polling should not be required. Because the idea of reporting is to avoid the need for polling. Do you know why the device behaves like this?

When some old devices has configuration changed by own software. The reports are disabled and this does not cause a disconnection. Consequently, I do not have a trigger telling me that the report is not signed. So, I have to check periodically to ensure integrity.

If it is really required I would recommend to put the line
ReportControlBlock report = connection.GetReportControlBlock(address);
outside of the while loop. This way you would avoid creating a new instance of ReportControlBlock for every request. Or polling the RptEna attribute with ReadValue as you suggested would be an even more simple solution.

I downloaded the latest version. However, I am no longer able to generate the C ++ dll. I did the same steps as earlier. I builded iec61850 project. There were no errors, but only iec61850.exp and iec61850.lib files were generated.

I tried to build all the projects and I did not succeed with iec61850-shared project.

image

I know that MmsValue_cloneToBuffer method has been modified, but what am I missing?

from libiec61850.

mzillgith avatar mzillgith commented on August 15, 2024

Thanks for the explanation. As I know the device should close connections when the configuration changes.

I have no problem building the projects in Visual Studio. Did you clone the latest from the v1.2 branch?

from libiec61850.

IgorMundstein avatar IgorMundstein commented on August 15, 2024

Thanks for the explanation. As I know the device should close connections when the configuration changes.

Yeah. This is the IED correct operation. However, there are always exceptions.

I have no problem building the projects in Visual Studio. Did you clone the latest from the v1.2 branch?

Yes I did. I always follow the same steps. The last builded version that I have is 1.1.2.0. I downloaded it on March 13. Something has changed since then.

from libiec61850.

mzillgith avatar mzillgith commented on August 15, 2024

Ok. As I said it worked for me.

I used commit da17f82 (latest in github)

I create a subfolder "build". In this folder I run
cmake -G "Visual Studio 15 2017" ..

Then I load the generated solution in Visual Studio and can build everything.

from libiec61850.

IgorMundstein avatar IgorMundstein commented on August 15, 2024

Hum. I use:
cmake -G "Visual Studio 14 2015 Win64"
Configuration: Release (x64)

I tried using Debug Configuration and it worked !

Have you changed something in Debug configuration and forgot to replicate in Release configuration?

from libiec61850.

mzillgith avatar mzillgith commented on August 15, 2024

I see. I have the same problem when using the "Release" configuration.
It is resolved when I remove the "inline" from the function signature of MemoryAllocator_getAlignedSize in simple_allocator.c
Yet I don't understand why this doesn't work because this is an internal function.

from libiec61850.

IgorMundstein avatar IgorMundstein commented on August 15, 2024

I see. It worked too for me when I removed the "inline".

Programming is a box of surprises. :)

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.