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. DLMS Server How To Set Server Logical Address, and Attach Object To Different Association

DLMS Server how to set server logical address, and attach object to different association

Profile picture for user jack 001
By jack 001 , 12 July, 2026
Forums
Gurux DLMS for ANSI C++

Hello, good day
I want to ask regarding DLMS server:
- how to set the server's logical address? I havent yet found the methods regarding that, i only found:

    unsigned char GetClientSAP();
    void SetClientSAP(unsigned char value);
 
    unsigned short GetServerSAP();
    void SetServerSAP(unsigned short value);

and in the header file (GXDLMSServerLN.h) i set it like this:

CGXDLMSServerLN(CGXDLMSAssociationLogicalName* ln,
        CGXDLMSIecHdlcSetup* hdlc) : CGXDLMSBase(ln, hdlc)
    {
        // CGXDLMSSecuritySetup* pSecurity = new CGXDLMSSecuritySetup("0.0.43.0.2.255");
        // CGXByteBuffer systemTitle;
   
        ln->SetClientSAP(10);
        ln->SetServerSAP(11);
        CGXByteBuffer password;
        password.AddString("00011123");
        ln->SetSecret(password);
    }

- after that, how to attach it to different association (with different authentication level)? last time i asked, you stated that there will be example about it. perhaps can you show some code sample on how to achieve that?

If the latter should be posted on different post, i'd happily crerate new post. thank you

 

Regards

jack

 

Profile picture for user Kurumi

Kurumi

3 months 3 weeks ago

Hi, The client address is…

Hi,

The client address is usually bound to the CGXDLMSAssociationLogicalName. The server address is checked on IsTarget.
https://www.gurux.fi/Gurux.DLMS.Server

You can check the ANSI C implementation here: https://github.com/Gurux/GuruxDLMS.c/blob/b14e6e0b5505d90a78d059f3bafd7…

Regards,
Mikko

Profile picture for user jack 001

jack 001

3 months 2 weeks ago

Hi, thank you for the reply,…

Hi, thank you for the reply, i will try implement it in c++

Regards
jack

  • 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