BAC0 icon indicating copy to clipboard operation
BAC0 copied to clipboard

Retrieve objectlist from a device that does not support segmentation

Open leanfm opened this issue 7 months ago • 1 comments

First of all, enjoyed your work a lot!!!

I am trying to explore some old MSTP devices which does not support segmentation. I tried many times but the BAC0.device just cannot connect. When I try to read the object list using the following, I always got the error:

await bacnet.read(f'{device_address} device {device_id} objectList')

  • ERROR | BAC0.scripts.Lite | Lite | BAC0.core.io.Read | Error : segmentation-not-supported

Or

await bacnet.readMultiple(f'{device_address} device {device_id} objectList')

  • ERROR | exception: segmentation-not-supported

But I can use readMultiple to get a small number of properties from this device so it is connected. My guess is the objectList is too long (I do know that there are 72 objects) for the read method to return. Is there any other way I can use to discover the objects in this device? Thank you very much.

leanfm avatar May 07 '25 17:05 leanfm

This can probably help your : https://github.com/ChristianTremblay/BAC0/blob/main/BAC0/core/devices/mixins/read_mixin.py#L165

reading the first element of objectList will give you the number of objects, then you can iterate the result using read and providing the array

ChristianTremblay avatar May 14 '25 18:05 ChristianTremblay

This issue had no activity for a long period of time. If this issue is still required, please update the status or else, it will be closed. Please note that an issue can be reopened if required.

github-actions[bot] avatar Jul 14 '25 02:07 github-actions[bot]