Skip to main content
Home
for DLMS smart meters
Open source solutions for DLMS smart metering

Main navigation

  • Home
  • Products
  • About us
  • Open Source
  • Community
  • Forum
  • Downloads
User account menu
  • Log in

Breadcrumb

  1. Home
  2. Node
  3. Creating Next Frame Request From Last Hex Response Is Not Working(receiverReady)

Creating Next Frame request from last hex response is not working(receiverReady)

By sethi.nitin9@g… , 11 December, 2023
Forums
Gurux DLMS for Java

Hi Kurumi,

I have tried checking and generating next request from previous frame if data is there, but it is not working as per expectation and throwing Invalid GLO Command exception.

isMoreData Exits is giving true but when I'm generating request it is throwing error:

Below is the code I have used:

this.hexData = "000100010030021BCC82021730000002C92F57250F2EF8065442022FD2EFDB07BBB5B2A53807079CCCC8C79950991FFA9E7AA819082E176282983D3D0AAFF114C18AB44C78C05EE885AAC4315ECC1F7588BEC19A9CEDD5AAE5D46B8A05D4EA88D89CA2ABC5504074018882D464CD9FBDA934B9C93D1C535AB25B630F606D8A96F1B3BF35D4D61D01A7982D9FBF861222BB3AEA5A98EED2334F67E9750ADD90D786907996EB7EEDB1997BFF68CD2761217F9AA8FE860F249BA73EAAFA6C632690999F924EE31AA202E96A4ED10836B51A60214DB0ABA9D632E258791E97FB04EE86A414177A7D1A135600D28C2A7DC7BE5F18223039F250DD6E622E56A94B25CE37F31BCD1D1D4914762E829B89D80660779734C5B9BFB35BF5DA831AF326ED796C46387FAFC29CBC31C6B289DC5D57BEEF92E3C9D228DF641E368B55B95C6E161FBB29CA2E64CCC0335ED10930922B6997372AAD366D1244BDD24343E642C1B617046102747DD9A83F73A6C018746EADEBD7F089231296AD8F5A30FEB8576AEF659AF73843AD7029E9038F98489495E79F7E55BC8474CC0A20459DF7FF82E5BA407DF7B111C37BDFCAFD31C7888477D1F24660C42A1B6223A15185F95003A8777FCB84DFB25711517A37BBDB90E5D249040AA5F70F99F44651BEC8718E5DCCD4601A8A52544F187AED40B2FB1A5DAA2D0EC57EA5B8CB0DF33EDD9A3043391C1463322EADEC14F88B00EAA7F9804E944F589F16D3C72FADADA1D03B38519CAF8F604AB7";

GXDLMSSecureClient client = new GXDLMSSecureClient();
client.setServerAddress(1);
client.setClientAddress(48);
client.getCiphering().setInvocationCounter(12544);
client.setAuthentication(Authentication.HIGH);
client.setUseLogicalNameReferencing(true);
client.getCiphering().setSecurity(Security.AUTHENTICATION_ENCRYPTION);
client.setInterfaceType(InterfaceType.WRAPPER);
client.getCiphering().setSystemTitle("HPL20215".getBytes("ASCII"));
client.setServerSystemTitle(GXCommon.hexToBytes("48504C00003D57F7"));
client.getCiphering().setBlockCipherKey("1234ABCD1234ABCD".getBytes("ASCII"));
client.getCiphering().setAuthenticationKey("1234ABCD1234ABCD".getBytes("ASCII"));
client.setPassword("bbbbbbbbbbbbbbbb".getBytes("ASCII"));

GXReplyData reply = new GXReplyData();
byte data[] = GXCommon.hexToBytes(this.hexData);
client.getData(data, reply);
boolean isMoreData = reply.isMoreData();
System.out.println("Is More Data Available: "+isMoreData);

byte nextBlock[] = client.receiverReady(reply);
System.out.println("Next Frame: "+ GXCommon.bytesToHex(nextBlock));

Error:
java.lang.RuntimeException: Invalid GLO command.
at com.global.meter.gurux.dlms.GXDLMSClient.receiverReady(GXDLMSClient.java:3049)

Profile picture for user Kurumi

Kurumi

2 years 10 months ago

Hi, You try to send meter…

Hi,

You try to send meter GetResponse using the client. That is not how it's designed.
What do you want to do?

BR,
Mikko

sethi.nitin9@g…

2 years 10 months ago

I want to read the next…

I want to read the next datablock from meter as all data is not fit to a single block.

As I have checked more data is coming true, but next frame is not generating successfully. I need to send that request using rest api.

Please guide me for this.

Profile picture for user Kurumi

Kurumi

2 years 10 months ago

Hi, The framework generates…

Hi,

The framework generates the needed reply automatically. You haven't shown what kind of read request you have generated and where the reply is coming from.

Ciphering is not just sending bytes. There is an invocation counter that needs to be updated after each request.

BR,
Mikko

  • Create new account
  • Reset your password

Hire Us!

Latest Releases

  • Tue, 10/13/2026 - 12:00
    gurux.dlms.java 4.0.97
  • Tue, 09/22/2026 - 14:02
    Gurux.DLMS.Net 9.0.2609.2201
  • Mon, 09/21/2026 - 10:18
    Gurux.DLMS.Net 9.0.2609.2101
  • Wed, 08/26/2026 - 09:04
    Gurux.DLMS.Python 1.0.203
  • Mon, 08/17/2026 - 11:28
    Gurux.DLMS.Python 1.0.202

New forum topics

  • Need RJ45 pin configuration for Saral 300 and Saral 305 Secure meters
  • Query Regarding Class 63 Status Mapping Support in Gurux DLMS Python
  • Inhemeter
  • DLMS Server - Profile Generic - can't add too many items to profile generic capture object - how to set maximum profile entries
  • HDLC Frames sequencing
More
RSS feed
Privacy FAQ GXDN Issues Contact
Follow Gurux on Twitter Follow Gurux on Linkedin