Hello,
I am in the process of testing a DLMS device that is in development in company. I have decided to try going through the conformance tests, and have ran into an issue when trying to pass the first one.
I downloaded the source code of Gurux DLMS Director to debug the application and try to find out why, but so far to no avail. The application does not accept the RR frame sent by the device.
The program reaches
client.GetData(GXByteBuffer reply, GXReplyData data, GXReplyData notify)
function with the "reply" buffer having the value of {7E A0 07 23 03 11 AD B5 7E}, which is correctly recognised by the online translator. The addresses are correct (device is 0x01, application is 0x11). Is this an issue with the application, or maybe with the device?
Hi, What test do you try to…
Hi,
What test do you try to run? Without that information, it's not possible to say what might cause this.
BR,
Mikko
Hi Kurumi, It's the HDLC #1…
Hi Kurumi,
It's the HDLC #1 initialise test, the one that checks if the device enters NRM correctly and responds to an RR message from the application.
Wish you a nice day,
Klimmie
Hi, The meter should return…
Hi,
The meter should return DisconnectMode frame if the connection is not established.
Now you return RR.
BR,
Mikko
Hi Kurumi, Looking at the…
Hi Kurumi,
Looking at the code that's not the expected reply. Sorry for the chaotic first message, I was a bit frustrated because I do not understand the application's behaviour.
I was looking through the function responsible for the HDLC #1 test T_HDLC_FRAME_P1 (https://github.com/Gurux/GXDLMSDirector/blob/c940ecbe1d6793563d16eacc04…)
The expected scenario (If I understand the code correctly) is:
1. Application is sending the DISC frame
2. Device responds with either UA frame or the DM frame
3. Application sends the SNRM frame
4. Device enters NRM and responds with UA
5. Application sends the RR frame
6. Device responds with an RR frame with both the frames send and frames received set to 0
7. Application sends the DISC frame
8. Device enters Disconnect Mode and responds with UA or DM
The test fails during step 6 (https://github.com/Gurux/GXDLMSDirector/blob/c940ecbe1d6793563d16eacc04…) because even though the device responds with an RR frame {7E A0 07 23 03 11 AD B5 7E}, the application does not accept the response.
I have debugged through the application and it reaches the client.GetData function that (as far as I understand) parses the bytes received, with the string of bytes {7E A0 07 23 03 11 AD B5 7E} received via the COM port, but the function ignores the bytes received and times out
I am sorry for the trouble and I wish you a nice day,
Klimmie