I am trying to connect with a meter using HLS GMAC. I update the frame counter, then I send SNRM request and parse response, then the same with AARQ request.
Finally, I try to send application association request with the following code:
reply.clear();
var associationRequest = client.getApplicationAssociationRequest();
for (byte[] it : associationRequest) {
readDLMSPacket(it, reply);
}
client.parseApplicationAssociationResponse(reply.getData());
I get an exception from readDLMSPacket stating "Device reports a unmatched type".
My application association request is the following:
-- Removed for privacy purposes --
What am I doing wrong?
I would appreciate any help, thank you.
Thanks for your response. I am quite sure both of my keys are correct, because I can connect to the meter using dedicated manufacturer's software and passing the same keys.
I also tried connecting with your GXDLMSDirector and the result is the same: "Device reports unmatched type".
Then one of your settings is different from what the meter expects. There are lots of parameters in DLMS and if one is different the communication fails.
DLMS error codes don't tell much but check first the used authentication level.
If you can add a hex trace from the manufacturer message I can check that the used ciphering service is the same. There are multiple ways to transport the ciphered PDU and meters usually support only part of them.
As far as I'm concerned the authentication level should be HIGH_GMAC with authenticated encryption. The log from manufacturer's software if the following:
The meter manufacturers' application is sending a challenge where authentication and encryption are marked and that is not correct because there is only an authentication tag.
300000014A44026FF690F23E71655A9E42
When Gurux application sends the challenge as it should be the meter returns UnmatchedType error. I believe that this is because the first byte is 0x10 and not 0x30.
100000014E57FF55736BB904AFFE6B6295
You need to ask the meter manufacturer if there is a firmware update available for the meter where this is fixed.
Hi,
Hi,
I believe that your block cipher or authentication key is different than the meter is using. Check that first.
BR,
Mikko
HI Mikko,
HI Mikko,
Thanks for your response. I am quite sure both of my keys are correct, because I can connect to the meter using dedicated manufacturer's software and passing the same keys.
I also tried connecting with your GXDLMSDirector and the result is the same: "Device reports unmatched type".
Regards,
Bartosz
Hi,
Hi,
Then one of your settings is different from what the meter expects. There are lots of parameters in DLMS and if one is different the communication fails.
DLMS error codes don't tell much but check first the used authentication level.
If you can add a hex trace from the manufacturer message I can check that the used ciphering service is the same. There are multiple ways to transport the ciphered PDU and meters usually support only part of them.
BR,
Mikko
Hi,
Hi,
As far as I'm concerned the authentication level should be HIGH_GMAC with authenticated encryption. The log from manufacturer's software if the following:
-- Removed for privacy purposes --
If this is useful, I also send my log:
-- Removed for privacy purposes --
Thanks for your help.
Regards,
Bartosz
Hi Bartosz,
Hi Bartosz,
The meter manufacturers' application is sending a challenge where authentication and encryption are marked and that is not correct because there is only an authentication tag.
300000014A44026FF690F23E71655A9E42
When Gurux application sends the challenge as it should be the meter returns UnmatchedType error. I believe that this is because the first byte is 0x10 and not 0x30.
100000014E57FF55736BB904AFFE6B6295
You need to ask the meter manufacturer if there is a firmware update available for the meter where this is fixed.
BR,
Mikko
Hi Mikko,
Hi Mikko,
Thank you very much for help, I'll contact the manufacturer.
I had to remove the logs from forum for the privacy purposes.
Best regards,
Bartosz