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.

Radix IoT Website Mango 3 Documentation Website Mango 4 Documentation Website

How to send response to ReadPropertyRequest


  • Hi,

    First of all thanks for BACnet4J. Nice BACnet Stack.

    I am developing code which simulates some BACnet device and I need to
    send reply to "[size=18]ReadPropertyReqest[/size]".
    Wherein Present Value of BACnet object mentioned.

    Does anyone know about it? If yes please help me.

    Regards,

    Dinesh


  • Hi,

    I think it should be "ReadPropertyAck". Because, from VTS I sent this request then I found following in Wireshark.

    No. Time Source Destination Protocol Length Info
    1435 498.012518 192.168.0.103 192.168.0.1 BACnet-APDU 67 Complex-ACK readProperty[ 1] analog-input,0 present-value

    Frame 1435: 67 bytes on wire (536 bits), 67 bytes captured (536 bits)
    Ethernet II, Src: CompalIn_b2:45:7e (00:26:22:b2:45:7e), Dst: Teracom_6b:4d:e0 (00:26:15:6b:4d:e0)
    Internet Protocol Version 4, Src: 192.168.0.103 (192.168.0.103), Dst: 192.168.0.1 (192.168.0.1)
    User Datagram Protocol, Src Port: bacnet (47808), Dst Port: bacnet (47808)
    BACnet Virtual Link Control
    Building Automation and Control Network NPDU
    Building Automation and Control Network APDU
    0011 .... = APDU Type: Complex-ACK (3)
    .... 0000 = PDU Flags: 0x00
    Invoke ID: 1
    Service Choice: readProperty (12)
    ObjectIdentifier: analog-input, 0
    Property Identifier: present-value (85)
    property Array Index (Unsigned) 1
    {[3]
    present-value: 23.000000 (Real)
    }[3]

    And it is quite similar as mentioned in one of the PDF of BACnet Standard which I found on Internet.

    But still I don't know how to send "ReadPropertyAck".
    If someone is knowing please help me.

    Thanks.


  • Hi,

    I got following.

        ReadPropertyRequest rprr = new ReadPropertyRequest(localDevice.getNextInstanceObjectIdentifier(ObjectType.analogInput), PropertyIdentifier.presentValue, null);
    
        ReadPropertyAck unRS = new ReadPropertyAck(localDevice.getNextInstanceObjectIdentifier(ObjectType.analogInput), PropertyIdentifier.presentValue, null, rprr);
    
        InetSocketAddress addr = new InetSocketAddress(InetAddress.getByName("192.168.0.255"), 47808);
        
        ComplexACK ack = new ComplexACK(true, true, by, by, by, unRS);
    

    Is it correct?

    If yes then how to send this Complex Request Ack?

    Please reply,

    Thanks in advance.


  • Hi,

    Greetings!

    I got the answer and I am too much happy about it.

    Because, I just run Slave device test program and then
    send the "ReadPropertyRequest" from the another PC using
    VTS. And then monitored acctivities going on in Wireshark.

    I found the reply as ComplexAck by Slave device test program.

    Thank you so much serotonin for developing such genius API.

    But, now I am moving ahead.
    That is I am implementing COV (Change of Value) functionality.

    So I want some help on the same.
    If anybody is knowing the same please let me know.

    Regards,

    Dinesh


  • This is very important information Dinesh..Good one.


  • Thanks Thomas for compliments.