Giter VIP home page Giter VIP logo

Comments (7)

gralin avatar gralin commented on September 26, 2024

Hi @ReiminkB, can you post the part where you call ReadPropertyRequest and tell me what kind of object and property you want to read from?

from bacnet.

gralin avatar gralin commented on September 26, 2024

Closing due to lack of feedback

from bacnet.

ReiminkB avatar ReiminkB commented on September 26, 2024

from bacnet.

gralin avatar gralin commented on September 26, 2024

@ReiminkB thanks for the feedback. Could you please try the latest beta (1.0.19) and see if you get a more human friendly message? Abort code 4 means that segmentations is not supported. Your device has too many objects and you can't read them due to lack of segmentation support (read more about it here). You need to read one object at a time using indexes.

Try this (I just typed it here so no guarantee it works but you will get the idea):

var propertyId = BacnetPropertyIds.PROP_OBJECT_LIST;
client.ReadPropertyRequest(device.Ip, objectId, propertyId, out value_list, arrayIndex: 0);
var objectCount = value_list.First().As<int>();

for (uint i = 1; i <= objectCount; i++)
{
    client.ReadPropertyRequest(device.Ip, objectId, propertyId, out value_list, arrayIndex: i);
    object_list.AddLast(value_list.First().As<BacnetObjectId>());
}

from bacnet.

ReiminkB avatar ReiminkB commented on September 26, 2024

@gralin thanks for the answer. I replace 1.0.13 for 1.0.19-beta and got indeed the message: "Abort from device, reason: SEGMENTATION_NOT_SUPPORTED"

Thanks for the useful information from that link.

I adjusted my code by reading the properties one by one, as you suggested, when trying to read the complete list fails.

I tested the code and now it works for that device as well.

Thanks!

from bacnet.

gralin avatar gralin commented on September 26, 2024

@ReiminkB I'm glad it works for you! If you find this lib useful please give it a star 😇 I'm planning a rewrite of the API so it's more user friendly, so stick around for v2 in near future.

from bacnet.

TheKPAXian avatar TheKPAXian commented on September 26, 2024

So, is there no way to read more than one object at a time, let's say, read in chunks of 10 objects?

from bacnet.

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.