Please Note This forum exists for community support for the Mango product family and the Radix IoT Platform. Although Radix IoT employees participate in this forum from time to time, there is no guarantee of a response to anything posted here, nor can Radix IoT, LLC guarantee the accuracy of any information expressed or conveyed. Specific project questions from customers with active support contracts are asked to send requests to support@radixiot.com.

  • PropertyArrayIndex=null with SlaveDeviceTest

    9
    0 Votes
    9 Posts
    4k Views
    M
    It works! Many thanks! :mrgreen: :mrgreen: :mrgreen:
  • RemoteDevice getObjects method

    4
    0 Votes
    4 Posts
    3k Views
    G
    OK, thanks a lot, that's true, it would be heavy...
  • Non unique Object Names???

    7
    0 Votes
    7 Posts
    4k Views
    M
    Presumably yes, you can change the oid, although oids themselves are immutable.
  • Add a Recipient to a Notificationclass of the local Device

    4
    0 Votes
    4 Posts
    3k Views
    P
    Thank you. Your post helped me.
  • 0 Votes
    3 Posts
    4k Views
    J
    Hi kishorev, You seem to be using the bacnet4j api in a bit of a strange way. But I can see a few things that might help. First of all before you ask for the object list, you probably need to do a broadcast, simply so that the responding bacnet device knows you exist, otherwise I'm pretty sure it can't respond to you. You can do it with a broadcast: localDevice.sendBroadcast(47808, localDevice.getIAm()); Or you can send it a direct message, since you know who you are talking to: localDevice.sendUnconfirmed(remoteDevice.getAddress(), null, localDevice.getIAm()); Then then other problem is the way you are getting the object list, you are really using internal API methods, you are much better off using: List<ObjectIdentifier> oids = ((SequenceOf<ObjectIdentifier>) localDevice.sendReadPropertyAllowNull(remoteDevice, remoteDevice .getObjectIdentifier(), PropertyIdentifier.objectList)).getValues(); Where remoteDevice is an instance of a RemoteDevice, in your case: Address address = new Address(null,BACnetUtils.dottedStringToBytes("192.168.1.3"),47808); RemoteDevice remoteDevice = localDevice.findRemoteDevice(address, null, deviceId);
  • How to enroll to event/alarm notifications ?

    4
    0 Votes
    4 Posts
    3k Views
    P
    Hello Can you post any example to inspire other users?
  • Patch for UDP 7 segments bug

    12
    0 Votes
    12 Posts
    5k Views
    M
    Indeed. A fix has been checked in.
  • Create a BACnet object with fixed instance number

    7
    0 Votes
    7 Posts
    4k Views
    M
    Add this line: localDevice.addObject(o);
  • Differences between the Properties of diverse bacNetDevice Manufacturer

    2
    0 Votes
    2 Posts
    2k Views
    E
    Hello, You cant use the same code for different Manufactorers. So I want to set up a Properties File from which you can get the correct and neccessary values to control a device. so i have a map with key: String (manufacturer) value: Propertie so i got maybe a file called: ManufacturerA.properties : temperature_sensor= ??? open_window= ??? In another class i have some methods, for example: getTemperature(RemoteDevice d, String manufactorer) so i send a ReadPropertyRequest in this method using the value of the entry of temperature_sensor, so that i can get the ObjectIdentifier from it my question is: Do different manufacturers's devices only differ in ObjectIdentifier, or do they also differ in ObjectType or in a writePropertyRequest in PropertyIdentifier propertyIdentifier, UnsignedInteger propertyArrayIndex ( so i want to know what i have to write as value into the properties )
  • Slave and virtual device on same system

    7
    0 Votes
    7 Posts
    4k Views
    M
    Good to know.
  • Problem with Read Property Request

    18
    0 Votes
    18 Posts
    8k Views
    D
    :wink:
  • Basic Bacnet4j Question

    8
    0 Votes
    8 Posts
    6k Views
    D
    I finally got it to work... LocalDevice localDevice = new LocalDevice(1234, "10.0.0.255", "10.0.0.111"); localDevice.initialize(); localDevice.sendBroadcast(0xBAC0, new WhoIsRequest(null, null)); localDevice.getEventHandler().addListener((DeviceEventListener) new Listener()); I now successfully receive an "i am" from all the bacnet devices expected. In the many of the test examples the LocalDevice constructor used was: LocalDevice localDevice = new LocalDevice(1234, "10.0.0.255"); I was never able to get any of those examples to work using this form of the constructor. The javadoc offers no help so I have no idea what address it is trying to bind to when you don't specify an address. I would suggest the test examples use the other constructor. Will save newbies a lot of frustration. Dan
  • Read BACnet ObjectValues

    8
    0 Votes
    8 Posts
    5k Views
    D
    Hello, I am trying to figure out how to use bacnet4j and this thread is helpful however I am still stuck on the various IP addresses and ports used? Can you explain the difference between resource.getString("localDeviceIP"), resource.getString("deviceIP") and resource.getString("port")? Thanks in advance.
  • Exception from readProperties

    5
    0 Votes
    5 Posts
    3k Views
    M
    It would be interesting to know how and why the device is formatting its response differently than expected. But as the software is right now, no, it won't accept that response.
  • How to implement a virtual device

    4
    0 Votes
    4 Posts
    3k Views
    K
    Thank you for that answer, it will be a great help.
  • Java.net.SocketException: getifaddrs not supported

    2
    0 Votes
    2 Posts
    2k Views
    C
    Hi; I am trying Bacnet4j on linux. But when I created bacnet device The error occured. Message is below java.lang.RuntimeException: java.net.SocketException: getifaddrs not supported at com.serotonin.bacnet4j.LocalDevice.getAllLocalAddresses(LocalDevice.java:779) at com.serotonin.bacnet4j.service.unconfirmed.IAmRequest.handle(IAmRequest.java:71) at com.serotonin.bacnet4j.LocalDevice.handleUnconfirmedRequest(LocalDevice.java:733) at com.serotonin.bacnet4j.npdu.ip.IpMessageControl$IncomingMessageExecutor.runImpl(IpMessageControl.java:555) at com.serotonin.bacnet4j.npdu.ip.IpMessageControl$IncomingMessageExecutor.run(IpMessageControl.java:489) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.lang.Thread.run(Unknown Source) Caused by: java.net.SocketException: getifaddrs not supported at java.net.VMNetworkInterface.getVMInterfaces(Native Method) at java.net.NetworkInterface.getNetworkInterfaces(Unknown Source) at com.serotonin.bacnet4j.LocalDevice.getAllLocalAddresses(LocalDevice.java:768) ...7 more It seem the Operating system is not supported getifaddrs. But how can I do. Thank you!
  • Discover devices in the same network

    2
    0 Votes
    2 Posts
    3k Views
    J
    Hello! I am developing an application with BACnet4J library. First of all, I am able capable of reading properties from a device. However, I would like to discover devices connected in the same network. That is to say, I do not know IP/port from other BACnet devices, but I really know that they exist. I am playing with ObjectType.device and PropertyIdentifier. I have included in my code the following lines: lDevice.sendBroadcast(1476, null, new WhoIsRequest()); Thread.sleep(5000); for (RemoteDevice d : lDevice.getRemoteDevices()) { lDevice.getExtendedDeviceInformation(d); List<ObjectIdentifier> oids = ((SequenceOf<ObjectIdentifier>) lDevice.sendReadPropertyAllowNull(d, d.getObjectIdentifier(),PropertyIdentifier.objectList)).getValues(); PropertyReferences refs = new PropertyReferences(); for (ObjectIdentifier oid : oids) addPropertyReferences(refs, oid); PropertyValues pvs = lDevice.readProperties(d, refs); // pvs. System.out.println(pvs); System.out.println(d); } } Someone could help me, please. Thank you very much! Kind regards!
  • Alarm Acknowledgement

    2
    0 Votes
    2 Posts
    2k Views
    C
    Hi, I am working on this problem of letting users acknowledge Alarm events. So in BACnet4j, where is the Alarm Ack/UnAck status stored? And how should I go about doing this Acknowledgement ? Thanks a bunch.
  • Not understand how to know the objectType value

    8
    0 Votes
    8 Posts
    4k Views
    V
    @mlohbihler said: Use read property requests with the present value property identifier. I did as you said : public String getPresentValue(LocalDevice localDevice, ObjectIdentifier oid) throws Exception { ReadPropertyRequest rpr = new ReadPropertyRequest(oid, PropertyIdentifier.presentValue); ReadPropertyAck rpa = (ReadPropertyAck) localDevice.send(isa, null, 1476, Segmentation.segmentedReceive, rpr); SequenceOf&lt;ObjectIdentifier&gt; sOis = (SequenceOf&lt;ObjectIdentifier&gt;) rpa.getValue(); List&lt;ObjectIdentifier&gt; ois = new ArrayList&lt;ObjectIdentifier&gt;(); for (ObjectIdentifier oi : sOis) { System.out.println(&quot;--&gt; &quot; + oi.getObjectType().intValue()); } return rpa.getValue().toString(); } But it gives this follow error: java.lang.ClassCastException: com.serotonin.bacnet4j.type.primitive.Real cannot be cast to com.serotonin.bacnet4j.type.constructed.SequenceOf at brainset.bacnet4j.Supervisory.getPresentValue(Supervisory.java:123) What I'm trying to do is scan my device and know what kind of points I have, if is a analog output, analog input, etc. And store these points values in my List<...>.
  • COV for Analog Input

    5
    0 Votes
    5 Posts
    4k Views
    A
    It's just that the software will not accept a COV subscription request on its analogs. Thanks,