How to find out if a KNX device is able to send extended frames?

132 views Asked by At

I am currently working on adding auto-detection of KNX devices as part of the Apache PLC4X KNX drivers (Currently working on the Golang version). I have made great progress on inspection of KNX devices, but just encountered a situation where a device claims to have a Max APDU of 55 bytes, but when reading some memory, it only responds with Standard frames which can only carry 12 bytes of payload.

I would like to be able to detect in advance if the device is able to send more than 12 bytes. But I'm a bit unsure how to do that. The device descriptor is 0701 which indicates a BIM M112 device. Does this profile of devices have a fixed APDU size of 15? I have multiple devices with that same profile and they don't respond with a Max APDU (They return with a count of 0 implying "not available" or "not permitted") so I default to 15. This particular ABB device however responds with 55, but doesn't send more than 12 bytes (which is identical to having a Max APDU of 15).

Help greatly appreciated.

Chris

1

There are 1 answers

1
Klaus Gütter On BEST ANSWER

Unfortunately, there are some legacy devices out there which in principle support MaxApduLength > 15, but have restrictions on specific services like Memory services limited to 12 bytes.

There is no specific discovery other than trial and error.

In any case you will have to implement a fallback to 15 bytes as the value reported in PID_MAX_APDU_LENGTH might be totally wrong (I've seen such devices...). Also, there might be couplers between the interface and the target device further restricting the usable APDU length.