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. GXDLMSData

GXDLMSData

By alnardn , 12 October, 2023
Forums
Gurux.DLMS

Hello! I don't understand how to write to object. I tried to change value of hardware relay blocking switch (0.0.96.4.3.255). My goal was to turn off load relay blocker. There are code lines:
data = GXDLMSData("0.0.96.4.3.255")
data.setDataType(2, DataType.UINT8)
data.value = GXInt8(2)
reader.write(data, 2)
But nothing happens. Maybe it's not possible? Or I made something wrong?

Profile picture for user Kurumi

Kurumi

2 years 11 months ago

Hi, If you want to use a…

Hi,

If you want to use a relay, you need to use a disconnect control for that.
Something like this:

d = GXDLMSDisconnectControl("YOUR_OBIS_CODE")

#Disconnect
self.readDataBlock(d.remoteDisconnect(self.client), reply)
#Reconnect
self.readDataBlock(d.remoteReconnect(self.client), reply)

BR,
Mikko

alnardn

2 years 11 months ago

I meant another thing. Load…

I meant another thing. Load relay blocker isn't the same as disconnect control. It has different obis (0.0.96.4.3.255) and 3 states:
0 - relay is controlled by meter according to specified algorithms;
1 - relay is always open and there is no load;
2 - relay is always closed and load isn't interrupted.
In cases 1 and 2 meter can't controll relay. So my goal was to try to change it from code. Is it possible?

Profile picture for user Kurumi

Kurumi

2 years 11 months ago

Hi, If your meter supports…

Hi,

If your meter supports it, it's possible. You can try that easily with GXDLMSDirector. If you can modify the value, try to change it and then write it to the meter.

BR,
Mikko

alnardn

2 years 11 months ago

Thanks for responce! And…

Thanks for responce! And does it possible from code not using GXDLMSDirector?

Profile picture for user Kurumi

Kurumi

2 years 10 months ago

Hi, Yes, it's possible…

Hi,

Yes, it's possible. Check my previous post. It will do what you want to do.

https://www.gurux.fi/comment/26873#comment-26873

BR,
Mikko

  • Create new account
  • Reset your password

Hire Us!

Latest Releases

  • Wed, 08/26/2026 - 09:04
    Gurux.DLMS.Python 1.0.203
  • Mon, 08/17/2026 - 11:28
    Gurux.DLMS.Python 1.0.202
  • Mon, 08/17/2026 - 09:47
    gurux.dlms.cpp 9.0.2608.1701
  • Mon, 08/17/2026 - 09:25
    gurux.dlms.c 9.0.2608.1701
  • Mon, 07/27/2026 - 12:37
    gurux.dlms.cpp 9.0.2607.2701

New forum topics

  • Security vulnerability report — request for a private contact (GuruxDLMS.c / ANSI C)
  • Topic: Insufficient Memory Error When Reading Class 7 Profile Generic Objects
  • SN ReadResponse returns all-null values when response spans multiple HDLC frames
  • Gurux.Serial.Android 3.0.6 – CH340 (HL-340) USB-Serial Adapter Not Working,
  • Trying to talk to a L&G E360 meter (Using Python Gurux)
More
RSS feed
Privacy FAQ GXDN Issues Contact
Follow Gurux on Twitter Follow Gurux on Linkedin