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. DLMS/COSEM Communication Issue With Electricity Meter

DLMS/COSEM Communication Issue with Electricity Meter

By kuba172 , 9 February, 2025
Forums
Gurux.DLMS

I'm experiencing issues with DLMS/COSEM communication when trying to read profile data from an electricity meter. While the initial connection is successful, reading profile data results in invalid HDLC frames.

Environment:
- Python with Gurux DLMS library
- TCP/IP connection to the meter
- Authentication Level: Low
- Using HDLC protocol

The connection parameters:
- IP: xx.xx.xx.xx
- Port: xxxx
- Client Address: xx
- Server Address: derived from meter serial number
- Password: ********

The issue:
1. Initial connection to the meter works fine
2. When trying to read profile data, I get HDLC frame errors:

The logs show "Invalid HDLC Frame: 0x3a Expected: 0x5a" errors, followed by "Data send failed".

I've tried:
1. Implementing a keep-alive mechanism
2. Setting appropriate timeouts
3. Reading capture objects before attempting to read profile data
4. Multiple reconnection attempts

The communication sequence:
1. Successfully establish connection
2. Get association view - successful
3. Try to read profile data - fails with HDLC frame errors
4. Subsequent retry attempts fail

Has anyone encountered similar issues? What could be causing these HDLC frame errors even though the initial connection is successful?

Any suggestions for:
1. Proper HDLC frame handling
2. Optimal DLMS/COSEM settings for profile data reading
3. Dealing with connection stability issues

My meters are Landis+Gyr E570 and E650

Thanks in advance for any help!

kuba172

1 year 5 months ago

Problem solved - threads and…

Problem solved - threads and locks should have been used appropriately for keep-alive functions.

  • Create new account
  • Reset your password

Hire Us!

Latest Releases

  • Mon, 07/27/2026 - 12:37
    gurux.dlms.cpp 9.0.2607.2701
  • Thu, 07/23/2026 - 16:19
    gurux.dlms.java 4.0.96
  • Thu, 07/09/2026 - 14:34
    Gurux.DLMS.Python 1.0.201
  • Fri, 06/26/2026 - 16:32
    Gurux.Service 3.0.2606.2601
  • Wed, 06/24/2026 - 08:36
    Gurux.DLMS.Python 1.0.200

New forum topics

  • gurux_dlms.GXDateTime.GXDateTime object Error in Python
  • T_APPL_DATA_LN_N1 subtest 3 fails on an LN-only server regardless of the response to a non-existing-object GET
  • Version mismatch between Gurux.DLMS 9.x and Gurux.Common/Gurux.Serial 8.x
  • Service not known error on gprs communication
  • Help Needed: Interfacing Saral 100 Energy Meter with Microcontroller via RS232
More
RSS feed
Privacy FAQ GXDN Issues Contact
Follow Gurux on Twitter Follow Gurux on Linkedin