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. C# - Specify Max Payload Size and Window Size In SNMR Trace

C# - Specify Max payload size and Window size in SNMR trace

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 dfranco_ , 4 January, 2021
Forums
Gurux.DLMS

Hello and happy new year,

When sending the SNRM trace using GXDLMSDirector it works and the communication with the meter is perfect. But in the C# library, we are not able to send it with the following configuration:

* Max payload size in transmit = 228
* Max payload size in receive = 228
* Window size in transmit = 1
* Window size in receive = 1

So we end up sending this:

<HDLC len="12" >
<TargetAddress Value="32767" />
<SourceAddress Value="2" />
<!--SNRM frame.-->
<FrameType Value="93" />
<Snrm>
</Snrm>
</HDLC>

Instead of this:

<HDLC len="32" >
<TargetAddress Value="32767" />
<SourceAddress Value="2" />
<!--SNRM frame.-->
<FrameType Value="93" />
<PDU>
<Snrm>
<MaxInfoTX Value="228" />
<MaxInfoRX Value="228" />
<WindowSizeTX Value="1" />
<WindowSizeRX Value="1" />
</Snrm>
</PDU>
</HDLC>

We are defining the GXDLMSClient as, but it doesn't seem to be a way to define the max payload size values and the window size bytes don't build up in the trace:

client = new GXDLMSClient
{
InterfaceType = InterfaceType.HDLC, Authentication = Authentication.Low,
WindowSize = 0x01,
InvokeID = 0x01,
Password = password, ServerAddress = clientAddress, ServerAddressSize = 0x0004,
...
ProposedConformance = ...
};

Is it possible to define these parameters in the GXDLMSClient ?. Could you help us pointing us how to specify the max payload size values?

Respectfully,

Profile picture for user Kurumi

Kurumi

5 years 5 months ago

Hi,

Hi,

You can change those values from GXDLMSClient.HdlcSettings.

BR,
Mikko

dfranco_

5 years 4 months ago

In reply to Hi, by Kurumi

Thanks for your reply Mikko,

Thanks for your reply Mikko,

I managed to get a longer SNMR with MaxInfoTX, MaxInfoRX, WindowSizeTX and WindowSizeTX trace by forcing parameters but the parameters are not accessible to be changed.

Within the class GXDLMSClient of the the C# library we do find GXDLMSClient.HdlcSettings, also, we do have the class GXHdlcSettings, which contains the attributes MaxInfoTX, MaxInfoRX, WindowSizeTX and WindowSizeTX but it is not allowed to modify as you see, it has only the GET option:

public GXHdlcSettings HdlcSettings { get; }

And therefore we get default 128 value for MaxInfoRX and MaxInfoTX:

<HDLC len="32" >
<TargetAddress Value="32767" />
<SourceAddress Value="2" />
<!--SNRM frame.-->
<FrameType Value="93" />
<PDU>
<Snrm>
<MaxInfoTX Value="128" />
<MaxInfoRX Value="128" />
<WindowSizeTX Value="1" />
<WindowSizeRX Value="1" />
</Snrm>
</PDU>
</HDLC>

In the end is it not possible to modify MaxInfoRX and MaxInfoTX to the value of 228? Is it a feature that you may foresee coming in further versions?

Kind regards

Profile picture for user Kurumi

Kurumi

5 years 4 months ago

Hi Daniel,

Hi Daniel,

You can modify values like this:

GXDLMSClient client = new GXDLMSClient();
client.HdlcSettings.MaxInfoTX = 228;
client.HdlcSettings.MaxInfoRX = 228;

BR,
Mikko

dfranco_

5 years 4 months ago

Thank you very much Mikko.

Thank you very much Mikko. The SNMR worked fine.

  • 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