I am trying to receive push messages. I am getting exception while receiving data. Below are the logs.
logs:
Starting to listen Push messages in port 4059
Press X to close and Enter to send a Push message.
Client Connected.
on trace 18:19:44 INFO Client connected.
on trace 18:19:49 RECEIVED 00 01 00 01 00 40 00 55 DB 08 4C 45 49 30 30 31 32 31 4A 20 00 00 00 00 5C EF F5 62 84 C5 C6 29 86 D2 3C CD B6 9F 32 DE C1 57 DA 58 05 13 10 D2 B9 4C 96 09 C9 34 96 82 29 E1 E2 66 E2 AF 42 53 D3 17 13 D3 95 52 3D 1C 6A B2 5E 22 D8 56 F7 29 1B 11 80 D3 B8 4B C6 81 26 A9 D6 DC BD 00
data received
Data length is 85and there are 86 bytes.
java.lang.NullPointerException
null
at gurux.dlms.GXDLMS.getTcpData(GXDLMS.java:2027)
at gurux.dlms.GXDLMS.getData(GXDLMS.java:3682)
at gurux.dlms.GXDLMSClient.getData(GXDLMSClient.java:2191)
at gurux.dlms.GXDLMSClient.getData(GXDLMSClient.java:2172)
at le.dlms.client.GXDLMSPushListener.onReceived(GXDLMSPushListener.java:141)
at gurux.net.GXNet.notifyReceived(GXNet.java:349)
at gurux.net.ReceiveThread.handleReceivedData(ReceiveThread.java:184)
at gurux.net.ReceiveThread.handleTCP(ReceiveThread.java:215)
at gurux.net.ReceiveThread.run(ReceiveThread.java:232)
The message is encrypted and I don't know the authentication or encryption keys so I can't check the bytes, but meter sends one byte too many. There should be 85 bytes, but there are 86. Ask your meter manufacturer to fix this.
It is fixed now. No extra byte is received. But this exception is still occurring.
data received
java.lang.NullPointerException
null
at gurux.dlms.GXDLMS.getTcpData(GXDLMS.java:2027)
at gurux.dlms.GXDLMS.getData(GXDLMS.java:3682)
at gurux.dlms.GXDLMSClient.getData(GXDLMSClient.java:2191)
at gurux.dlms.GXDLMSClient.getData(GXDLMSClient.java:2172)
at le.dlms.client.GXDLMSPushListener.onReceived(GXDLMSPushListener.java:141)
at gurux.net.GXNet.notifyReceived(GXNet.java:349)
at gurux.net.ReceiveThread.handleReceivedData(ReceiveThread.java:184)
at gurux.net.ReceiveThread.handleTCP(ReceiveThread.java:215)
at gurux.net.ReceiveThread.run(ReceiveThread.java:232)
Data was corrected from meter side. But still i am getting below exception.
encryption key is LogicEasternIndL
system title is LEI00121
RECEIVED 00 01 00 01 00 40 00 55 DB 08 4C 45 49 30 30 31 32 31 4A 20 00 00 00 00 D6 45 4D A4 2A 1E A3 9F CE F7 09 19 4A 41 75 16 96 0A 12 EF FA 6E E9 77 73 EA BE B6 3B AC 7B F8 AD E7 8A CD A7 24 B6 F1 B2 1B 02 C6 85 88 3E 3E 8C 26 A2 B7 C9 10 03 6E 7A 79 ED 31 4E CB C7 7C 23 71 B4 53 89
data received
java.lang.NullPointerException
null
at gurux.dlms.GXDLMS.getTcpData(GXDLMS.java:2027)
at gurux.dlms.GXDLMS.getData(GXDLMS.java:3682)
at gurux.dlms.GXDLMSClient.getData(GXDLMSClient.java:2191)
at gurux.dlms.GXDLMSClient.getData(GXDLMSClient.java:2172)
at le.dlms.client.GXDLMSPushListener.onReceived(GXDLMSPushListener.java:141)
at gurux.net.GXNet.notifyReceived(GXNet.java:349)
at gurux.net.ReceiveThread.handleReceivedData(ReceiveThread.java:184)
at gurux.net.ReceiveThread.handleTCP(ReceiveThread.java:215)
at gurux.net.ReceiveThread.run(ReceiveThread.java:232)
I want to know the format of Push data that i should receive from client and what parameters are must for complete and correct Push data. So that dlms code can successfully parse all push data. Can you help me with this?
Hi,
Hi,
The message is encrypted and I don't know the authentication or encryption keys so I can't check the bytes, but meter sends one byte too many. There should be 85 bytes, but there are 86. Ask your meter manufacturer to fix this.
BR,
Mikko
It is fixed now. No extra
It is fixed now. No extra byte is received. But this exception is still occurring.
data received
java.lang.NullPointerException
null
at gurux.dlms.GXDLMS.getTcpData(GXDLMS.java:2027)
at gurux.dlms.GXDLMS.getData(GXDLMS.java:3682)
at gurux.dlms.GXDLMSClient.getData(GXDLMSClient.java:2191)
at gurux.dlms.GXDLMSClient.getData(GXDLMSClient.java:2172)
at le.dlms.client.GXDLMSPushListener.onReceived(GXDLMSPushListener.java:141)
at gurux.net.GXNet.notifyReceived(GXNet.java:349)
at gurux.net.ReceiveThread.handleReceivedData(ReceiveThread.java:184)
at gurux.net.ReceiveThread.handleTCP(ReceiveThread.java:215)
at gurux.net.ReceiveThread.run(ReceiveThread.java:232)
encryption key is
encryption key is LogicEasternIndL
RECEIVED 00 01 00 01 00 40 00 55 DB 08 4C 45 49 30 30 31 32 31 4A 20 00 00 00 00 5C EF F5 62 84 C5 C6 29 86 D2 3C CD B6 9F 32 DE C1 57 DA 58 05 13 10 D2 B9 4C 96 09 C9 34 96 82 29 E1 E2 66 E2 AF 42 53 D3 17 13 D3 95 52 3D 1C 6A B2 5E 22 D8 56 F7 29 1B 11 80 D3 B8 4B C6 81 26 A9 D6 DC BD
Hi,
Hi,
Encrypted data is wrong. I was not able to decrypt it. Check the keys and system title.
BR,
Mikko
Data was corrected from meter
Data was corrected from meter side. But still i am getting below exception.
encryption key is LogicEasternIndL
system title is LEI00121
RECEIVED 00 01 00 01 00 40 00 55 DB 08 4C 45 49 30 30 31 32 31 4A 20 00 00 00 00 D6 45 4D A4 2A 1E A3 9F CE F7 09 19 4A 41 75 16 96 0A 12 EF FA 6E E9 77 73 EA BE B6 3B AC 7B F8 AD E7 8A CD A7 24 B6 F1 B2 1B 02 C6 85 88 3E 3E 8C 26 A2 B7 C9 10 03 6E 7A 79 ED 31 4E CB C7 7C 23 71 B4 53 89
data received
java.lang.NullPointerException
null
at gurux.dlms.GXDLMS.getTcpData(GXDLMS.java:2027)
at gurux.dlms.GXDLMS.getData(GXDLMS.java:3682)
at gurux.dlms.GXDLMSClient.getData(GXDLMSClient.java:2191)
at gurux.dlms.GXDLMSClient.getData(GXDLMSClient.java:2172)
at le.dlms.client.GXDLMSPushListener.onReceived(GXDLMSPushListener.java:141)
at gurux.net.GXNet.notifyReceived(GXNet.java:349)
at gurux.net.ReceiveThread.handleReceivedData(ReceiveThread.java:184)
at gurux.net.ReceiveThread.handleTCP(ReceiveThread.java:215)
at gurux.net.ReceiveThread.run(ReceiveThread.java:232)
Hi,
Hi,
I can now decrypt the data. Problem is that the content of data is not correct.
BR,
Mikko
could you tell what is
could you tell what is incorrect in data?
Hi,
Hi,
This is decrypted data. I don't know what kind of data you are sending, but check that invoke Id is UInt32. I belive it's not.
0F D0 00 00 01 0C 0A 31 38 FF 07 E3 08 05 FF 20 20 05 02 04 0A 06 31 30 30 31 32 31 09 06 00 04 19 09 00 FF 09 0C 0A 2A 1E FF 07 E3 08 05 FF 20 01 00
04 81 80 00 00 00 00 00 00 00 00 00 00 22 00 00 00 00 00
BR,
Mikko
Okay, Thanks.
Okay, Thanks.
I have confirmed that meter is not sending any invoke id.
Hi,
Hi,
I want to know the format of Push data that i should receive from client and what parameters are must for complete and correct Push data. So that dlms code can successfully parse all push data. Can you help me with this?
Thanks
Hi,
Hi,
Content of push messages can be almost anything. User can usually define what is sent. It can be reports, errors, etc.
Structure of push message is described in Green Book. You can get it there.
BR,
Mikko