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. Forums
  3. Gurux.DLMS.XmlClient Settings of Invocation Counter

Gurux.DLMS.XmlClient settings of invocation counter

Forum Rules

Before commenting read Forum rules

Don't comment the topic if you have a new question.

You can create a new topic selecting correct category from Gurux Forum and then create a new topic selecting "New Topic" from the top left.

By RSS , 6 May, 2020
Forums
Gurux.Net

Hi Mikko,

I am working with the Gurux.DLMS.XmlClient console project programmed in C #, I am trying to configure it as HLS GMAC AuthenticationEncryption.

Until now I have added the following lines of code to the Gurux.DLMS.XmlClient project to the Programs.cs file, to configure them through the windows console:

settings.client.Ciphering.BlockCipherKey = ASCIIEncoding.ASCII.GetBytes(it.Value);
settings.client.Ciphering.AuthenticationKey = ASCIIEncoding.ASCII.GetBytes(it.Value);
settings.client.Ciphering.DedicatedKey = ASCIIEncoding.ASCII.GetBytes(it.Value);
settings.client.Ciphering.InvocationCounter = uint.Parse(it.Value);
settings.client.Ciphering.Security = (Security)Enum.Parse(typeof(Security), it.Value);
settings.client.Ciphering.SecuritySuite = (Objects.Enums.SecuritySuite)Enum.Parse(typeof(Objects.Enums.SecuritySuite), it.Value);
settings.client.Ciphering.SystemTitle = ASCIIEncoding.ASCII.GetBytes(it.Value);

With these configurations the first data of the AARQ are sent well with the exception of the invocation counter which sends the bytes 0x43 0x44 0x45 0x46 instead of 0x00 0x00 0x00 0x01, which is how the GXDLMSDirector does.

To configure the InvocationCounter, I send from the console: -I 0

but still the invocation counter has a very large value instead of 0.

Could you help me to know what is missing in my configurations or if I am not configuring the client invocation counter well?

Regards!
Rafael Sánchez

Profile picture for user Kurumi

Kurumi

6 years 1 month ago

Hi,

Hi,

XML Client example is now improved. You can give those values as command line parameters. Something like:
-x test.xml -t Verbose -C AuthenticationEncryption -F 100 -T System_title -A Authentication_key -B Block_cipher_key -D Dedicated_key

Get the latest version from GitHub.

BR,

Mikko

  • Create new account
  • Reset your password

Hire Us!

Latest Releases

  • Tue, 06/09/2026 - 11:16
    gurux.dlms.java 4.0.95
  • Tue, 06/09/2026 - 10:03
    Gurux.DLMS.Python 1.0.199
  • Mon, 06/08/2026 - 13:39
    gurux.dlms.cpp 9.0.2606.0801
  • Mon, 06/01/2026 - 10:15
    gurux.dlms.cpp 9.0.2606.0101
  • Thu, 05/28/2026 - 16:06
    gurux.dlms.java 4.0.94

New forum topics

  • Error reading L&G Meter
  • Pass a TCP Client to GXNet
  • Australian EDMI Mk10D (Essential Energy area)
  • Strange mix of data notificiation vs get response
  • DLMS Connection
More

Who's new

  • Tuanhgg
  • Adel
  • charnon
  • Paddles
  • Miguel Ángel
RSS feed
Privacy FAQ GXDN Issues Contact
Follow Gurux on Twitter Follow Gurux on Linkedin