How to temporarily disable acknowledgement for received ConfirmedCOVRequests?
I have a bit of a strange use case here. I'm developing an automated test system against a BACnet device. My test system is using Bacure (https://github.com/Frozenlock/bacure), a Clojure wrapper for BACnet4J, to interface with our device. (The device does NOT use BACnet4J, but my test system does.)
I'm trying to figure out how to implement in Bacure the ability to turn off acknowledgement when we (the BACnet4J local device) receive a ConfirmedCOVNotificationRequest. (I think that's correct...)
So basically, my test case is this:
- SubscribeCOV (Confirmed) on the remote device
- Change the value on the remote device to generate a COV notification
- Confirm COV is received on our local BACnet4J device
- Disable ACK on the local BACnet4J device
- Change the value on the remote device again to generate a COV notification
- The remote device will send multiple COV notifications (APDU retries + 1) because we never ACKed
Anyone have any hints?
I found a solution, although it's not ideal.
If you disable communications via LocalDevice.setCommunicationControl after having subscribed, you get the behavior I'm looking for. This seems a bit heavy-handed when all I want to do is turn off acknowledgment for a single service, but it will do for the time being until someone shows me a better way.