Hi,
I have build latest Gurux.DLMS.c in Linux machine. I am currently using Gurux.dlms.client example for my development.
DLMS.c --- Meter (Interface:HDLC) - Working
DLMS.c --- Meter (Interface:Wrapper) - Not Working
Below are the logs for your reference.
------------------------------------------------- "DLMS.c --- Meter (Interface:HDLC)" -------------------------------------------------
testadmin@ci5lub061308:~/JIGAR_DLMS/v0/GuruxDLMSClientExample/bin$ sudo ./gurux.dlms.client.bin -S /dev/ttyUSB1 -r ln -c 16 -a None -C None -g 0.0.1.0.0.255:2 -t Verbose
InitializeConnection
TX: 7E A0 07 03 21 93 0F 01 7E
RX: 7E A0 1E 21 03 73 C3 7A 81 80 12 05 01 80 06 01 80 07 04 00 00 00 01 08 04 00 00 00 01 53 3B 7E
TX: 7E A0 2B 03 21 10 FB AF E6 E6 00 60 1D A1 09 06 07 60 85 74 05 08 01 01 BE 10 04 0E 01 00 00 00 06 5F 1F 04 00 40 1E 1D FF FF E7 25 7E
RX: 7E A0 37 21 03 30 6C 7C E6 E7 00 61 29 A1 09 06 07 60 85 74 05 08 01 01 A2 03 02 01 00 A3 05 A1 03 02 01 00 BE 10 04 0E 08 00 06 5F 1F 04 00 00 00 10 02 26 00 07 FE 3F 7E
GetAssociationView
TX: 7E A0 19 03 21 32 6F D8 E6 E6 00 C0 01 C1 00 0F 00 00 28 00 00 FF 02 00 91 53 7E
RX: 7E A8 89 21 03 52 86 A9 E6 E7 00 C4 01 C1 00 01 08 02 04 12 00 08 11 00 09 06 00 00 01 00 00 FF 02 02 01 09 02 03 0F 01 16 01 00 02 03 0F 02 16 01 00 02 03 0F 03 16 00 00 02 03 0F 04 16 00 00 02 03 0F 05 16 00 00 02 03 0F 06 16 00 00 02 03 0F 07 16 00 00 02 03 0F 08 16 00 00 02 03 0F 09 16 00 00 01 06 02 02 0F 01 16 00 02 02 0F 02 16 00 02 02 0F 03 16 00 02 02 0F 04 16 00 02 02 0F 05 16 00 02 02 0F 06 16 2E 2E 7E
TX: 7E A0 07 03 21 51 11 E4 7E
RX: 7E A8 89 21 03 54 B0 CC 00 02 04 12 00 0F 11 01 09 06 00 00 28 00 01 FF 02 02 01 09 02 03 0F 01 16 01 00 02 03 0F 02 16 01 00 02 03 0F 03 16 01 00 02 03 0F 04 16 01 00 02 03 0F 05 16 01 00 02 03 0F 06 16 01 00 02 03 0F 07 16 00 00 02 03 0F 08 16 01 00 02 03 0F 09 16 01 00 01 04 02 02 0F 01 16 00 02 02 0F 02 16 00 02 02 0F 03 16 00 02 02 0F 04 16 00 02 04 12 00 01 11 00 09 06 00 00 2A 00 00 FF 02 02 01 02 89 5C 7E
TX: 7E A0 07 03 21 71 13 C5 7E
RX: 7E A8 89 21 03 56 A2 EF 02 03 0F 01 16 01 00 02 03 0F 02 16 01 00 01 00 02 04 12 00 01 11 00 09 06 00 00 2B 01 02 FF 02 02 01 02 02 03 0F 01 16 01 00 02 03 0F 02 16 01 00 01 00 02 04 12 00 01 11 00 09 06 00 00 2B 01 03 FF 02 02 01 02 02 03 0F 01 16 01 00 02 03 0F 02 16 01 00 01 00 02 04 12 00 01 11 00 09 06 00 00 2B 01 04 FF 02 02 01 02 02 03 0F 01 16 01 00 02 03 0F 02 16 01 00 01 00 02 04 12 00 01 11 00 B1 13 7E
TX: 7E A0 07 03 21 91 1D 22 7E
RX: 7E A0 48 21 03 58 9E 7B 09 06 00 00 2B 01 05 FF 02 02 01 02 02 03 0F 01 16 01 00 02 03 0F 02 16 01 00 01 00 02 04 12 00 01 11 00 09 06 00 00 60 01 00 FF 02 02 01 02 02 03 0F 01 16 01 00 02 03 0F 02 16 01 00 01 00 2E F7 7E
-------- Reading Object Clock 0.0.1.0.0.255
TX: 7E A0 19 03 21 B4 51 39 E6 E6 00 C0 01 C1 00 08 00 00 01 00 00 FF 02 00 60 1A 7E
RX: 7E A0 1E 21 03 7A 02 E7 E6 E7 00 C4 01 C1 00 09 0C 07 E7 0C 1D FF 0F 1C 07 FF 01 4A FF 3B B7 7E
Index: 2 Value: 12/29/2023 15:28:07 UTC--05:-30
Index: 3 Value: 0
Index: 4 Value: 0
Index: 5 Value: 01/00/1900 00:00:00 UTC+00:00
Index: 6 Value: 01/00/1900 00:00:00 UTC+00:00
Index: 7 Value: 0
Index: 8 Value: 0
Index: 9 Value: 0
TX: 7E A0 11 03 21 D6 9D 9C E6 E6 00 62 03 80 01 00 BD 9B 7E
RX: 7E A0 11 21 03 9C C3 D7 E6 E7 00 63 03 80 01 00 2C 0F 7E
TX: 7E A0 07 03 21 53 03 C7 7E
RX: 7E A0 1E 21 03 73 C3 7A 81 80 12 05 01 80 06 01 80 07 04 00 00 00 01 08 04 00 00 00 01 53 3B 7E
All items are read.
testadmin@ci5lub061308:~/JIGAR_DLMS/v0/GuruxDLMSClientExample/bin$
------------------------------------------------- "DLMS.c --- Meter (Interface:Wrapper)" -------------------------------------------------
testadmin@ci5lub061308:~/JIGAR_DLMS/v0/GuruxDLMSClientExample/bin$ sudo ./gurux.dlms.client.bin -S /dev/ttyUSB0 -r ln -c 16 -a None -C None -g 0.0.1.0.0.255:2 -t Verbose -i WRAPPER
InitializeConnection
TX: 00 01 00 10 00 01 00 1F 60 1D A1 09 06 07 60 85 74 05 08 01 01 BE 10 04 0E 01 00 00 00 06 5F 1F 04 00 40 1E 1D FF FF
Data send failed. Try to resend 1/3
Data send failed. Try to resend 2/3
Data send failed. Try to resend 3/3
AARQRequest failed Data receive failed.
Data receive failed.
testadmin@ci5lub061308:~/JIGAR_DLMS/v0/GuruxDLMSClientExample/bin$
Can you please check from your end why this is not working in Wrapper Interface?
Thanks,
Jigar
Hi Jigar, WRAPPER is used…
Hi Jigar,
WRAPPER is used with TCP/IP connections and HDLC is used with serial port connections. The meter accepts only HDLC frames in serial port connection and it can't handle WRAPPER frames so they are skipped.
BR,
Mikko
Hi Mikko, We have checked…
Hi Mikko,
We have checked the same with connection with GXDLMSDirector, it's working properly.
GXDLMSDirector Tool --- Meter (Interface:Wrapper) - Working
But problem here is only with DLMS.c
DLMS.c --- Meter (Interface:Wrapper) - Not Working
DLMS.c should also work in same condition can we have such support in library?
Thanks,
Jigar
Hi Jigar, GXDLMSDirector is…
Hi Jigar,
GXDLMSDirector is using HDLC also for serial port connections even WRAPPER is selected.
This functionality was added because WRAPPER was causing a lot of problems with serial port connections.
BR,
Mikko
Hi Mikko, You mean to say…
Hi Mikko,
You mean to say that below configuration is not supported for serial port in DLMS.c right?
DLMS.c --- Meter (Interface:Wrapper) : Serial Port
Thanks,
Jigar
Hi Jigar, Your meter doesn't…
Hi Jigar,
Your meter doesn't use WRAPPER framing with the serial port. It's using HDLC framing and you need to use the same framing or the communication doesn't work.
ANSI C is sending WRAPPER frames as you have asked, but the meter can't handle them and the communication fails.
BR,
Mikko
Hi Jigar, Your meter doesn't…
Hi Mikko,
It seems that there is confusing in understanding my setup.
My meter is having two connection to communicate with meter and both are working as expected with GXDLMSDirector Tool.
Below is further clarification for my setup and ask
1. Optical Connection - works with HDLC frames
GXDLMSDirector Tool --- Meter (Interface:HDLC) - Working
DLMS.c --- Meter (Interface:HDLC) - Working
2. Serial Connection - works with Wrapper frames
GXDLMSDirector Tool --- Meter (Interface:Wrapper) - Working
DLMS.c --- Meter (Interface:Wrapper) - Not Working - Why?
Thus it seems that there is no problem in Meter but DLMS.c is not working for serial connection - Wrapper frames with meter.
It is unable to identify data from meter, here meter is sending data we have verified it on Saleae logic analyzer.
Thanks,
Jigar
Hi, The reason is that…
Hi,
The reason is that GXDLMSDirector doesn't use WRAPPER for serial port connections.
It is using HDLC for serial port connection even WRAPPER is selected.
Your use case is using HDLC even though you have selected the WRAPPER.
2. Serial Connection - works with Wrapper frames
GXDLMSDirector Tool --- Meter (Interface:Wrapper)
If you check the send and received bytes that will start with 0x7E that is HDLC framing, not WRAPPER.
BR,
Mikko