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 4 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

  • 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
RSS feed
Privacy FAQ GXDN Issues Contact
Follow Gurux on Twitter Follow Gurux on Linkedin