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. While Accessing Electricity Meter Facing Authentication Issues.

While accessing Electricity meter facing authentication issues.

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 Malay , 9 July, 2019
Forums
Gurux.DLMS

Hi Mikko,

I am trying to read secure sprint 350 meters via an optical port using your open DLMS source code.

/* printf("Read Indian device using serial port connection.\r\n"); */
/* printf("GuruxDlmsSample -S COM1 -c 16 -s 1 -a Low -P [password]\r\n"); */

As per the above line from the source code I have provided the following input:

-S /dev/ttyUSB0 -c 16 -s 1 -a None

This are the console output but it was failed with 279 (DLMS_ERROR_CODE_AUTHENTICATION_FAILURE) at this function call: apdu_parsePDU(settings, reply, &result, &sd, &command) --->Called from cl_parseAAREResponse();

Note: For better understand I have added some print in the code:
====================> Console output Start <=====================
Reading all objects...

--------Inside : com_initializeConnection---------

1)SNRM request.
7EA0732193F17E

1)SNRM response
7EA020213737398818014522062207400018400016FEF7E

SNRM request passed

2)AARQ request.
7EA038321109749E6E60602AA196760857458118A27808B76085745820BE104E100065F1F4001E1DFFFF5A27E

2)AARQ response
7EA037213306C7CE6E706129A19676085745811A23211A35A1321DBE104E8065F1F4000102007F537E

------------com_initializeConnection:ret : 279
------------com_initializeConnection:Failed---------

====================> Console output End <=====================

I have also try to read using DLMSDirector Application were I got success:

==================> Application output start<======================

10:26:28 Initializing serial connection.
10:26:29 Send SNRM request.
7E A0 07 03 21 93 0F 01 7E
10:26:29
7E A0 20 21 03 73 73 98 81 80 14 05 02 02 00 06 02 02 00 07 04 00 00 00 01 08 04 00 00 00 01 6F EF 7E
10:26:29 Parsing UA reply succeeded.
10:26:29 Send AARQ request.
7E A0 2B 03 21 10 FB AF E6 E6 00 60 1D A1 09 06 07 60 85 74 05 08 01 01 BE 10 04 0E 01 00 00 00 06 5F 1F 04 00 00 1E 1D FF FF C5 E4 7E
10:26:29
7E A0 37 21 03 30 6C 7C E6 E7 00 61 29 A1 09 06 07 60 85 74 05 08 01 01 A2 03 02 01 00 A3 05 A1 03 02 01 00 BE 10 04 0E 08 00 06 5F 1F 04 00 00 00 10 02 00 00 07 1C EA 7E
10:26:29 Parsing AARE reply succeeded.
10:26:32 Read object type Clock index: 2
7E A0 19 03 21 32 6F D8 E6 E6 00 C0 01 C1 00 08 00 00 01 00 00 FF 02 00 60 1A 7E
10:26:32
7E A0 1E 21 03 52 48 4A E6 E7 00 C4 01 C1 00 09 0C 07 E3 07 05 05 0F 38 21 FF 80 00 00 A3 3D 7E
10:26:44 Disconnect request
10:26:44 Disconnect request
7E A0 07 03 21 53 03 C7 7E
10:26:44
7E A0 20 21 03 73 73 98 81 80 14 05 02 02 00 06 02 02 00 07 04 00 00 00 01 08 04 00 00 00 01 6F EF 7E

====================> Application output end <=====================

Please help me to trigger out the issue? Please compare these both logs and tell me what I am doing wrong?

Profile picture for user Kurumi

Kurumi

6 years 11 months ago

Hi,

Hi,

Can you post trace where leading zeroes are added? Now they are missing and hex string is not possible to read.
Change this:

7EA0732193F17E
to this:
7E A0 07 03 21 93 0F 01 7E

BR,
Mikko

Malay

6 years 11 months ago

Hi Mikko,

Hi Mikko,

This was not an issue, leading zeroes are missed while it was printing information on console. I have corrected print issue please have look and provide feedback as I am receiving same authentication failure.

====================> Console output Start <=====================
Reading all objects...

--------Inside : com_initializeConnection---------

1)SNRM request.
7E A0 07 03 21 93 0F 01 7E

1)SNRM response
7E A0 20 21 03 73 73 98 81 80 14 05 02 02 00 06 02 02 00 07 04 00 00 00 01 08 04 00 00 00 01 6F EF 7E

SNRM request passed

2)AARQ request.
7E A0 38 03 21 10 97 49 E6 E6 00 60 2A A1 09 06 07 60 85 74 05 08 01 01 8A 02 07 80 8B 07 60 85 74 05 08 02 00 BE 10 04 0E 01 00 00 00 06 5F 1F 04 00 00 1E 1D FF FF 5A 02 7E

2)AARQ response
7E A0 37 21 03 30 6C 7C E6 E7 00 61 29 A1 09 06 07 60 85 74 05 08 01 01 A2 03 02 01 01 A3 05 A1 03 02 01 0D BE 10 04 0E 08 00 06 5F 1F 04 00 00 00 10 02 00 00 07 0F 53 7E

------------com_initializeConnection:ret : 279
------------com_initializeConnection:Failed---------

====================> Console output End<=====================

Profile picture for user Kurumi

Kurumi

6 years 11 months ago

Hi Malay,

Hi Malay,

Without leading zeroes, it's not possible for me to read the data stream.

Get the latest version. We modify the lib and sent authentication level always, but it was causing problems with some of the meters. This is now rejected back.

BR,

Mikko

Malay

6 years 11 months ago

Hi Mikko,

Hi Mikko,

As you instructed I have used latest version and now I am able to read the data from meter with authentication level "None" but still I am only able to read just 3 types of objects data.

Please refer the attached screenshot of DLMSDirector "Objects.PNG" and answer the following query.

1) During the association view meter responding only 3 objects. How can I read all supported objects(OBIS code) from meter as I am reading via optical port?

2) Is authentication level required to read the data other than this 3 objects ? Please tell me so I can connect with my vendor to get the password.

3)Is there any restriction possible like you have to used at least "Low" level authentication to get the other data OR you have to read from RS232 port instead of Optical ?

*Note : Meter - Secure Sprint350, Communication - Optical port for local communications and optional RS232 (RJ-11 port) for remote communications.*

Thanks In advance.

Image
Profile picture for user Kurumi

Kurumi

6 years 11 months ago

Hi,

Hi,

You should change authentication from None to Low or High to read all objects.
You need to ask what authentication levels meter supports and password.

Security levels and possible restriction are depending on the manufacturer.

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