I have two meters SL7000 and Landis + Gyr, the SL7000 connect successfully, change the cable at the Landis + Gyr and this not conect, the error is:
Initializing Network connection.
Send SNRM request.7E A0 07 03 21 93 0F 01 7E
<- 10:31:32 a. m. 7E A0 07 03 21 93 0F 01 7E
<- 10:31:37 a. m. 7E A0 07 03 21 93 0F 01 7E
<- 10:31:42 a. m. 7E A0 07 03 21 93 0F 01 7E
Failed to receive reply from the device in given time.
The parameters are:
In the code:
- host = "192.168.1.250"
- port = "40001"
- iec="dlms"
for the two meters
- auth = DirectCast([Enum].Parse(GetType(Authentication), "Low"), Authentication)
Hello Kurimi thank's,
The error was in the configuration of the cable. It works now. But the problem now is that it only allows you to connect to the Landys meter model 2018 with user None:
Thank's Mikko, we use the next functions in code example .net
Public Sub InitializeConnection(man As GXManufacturer)
Manufacturer = man
UpdateManufactureSettings(man.Identification)
......
...
Public Sub UpdateManufactureSettings(id As String)
If Manufacturer IsNot Nothing AndAlso String.Compare(Manufacturer.Identification, id, True) <> 0 Then
Throw New Exception(String.Format("Manufacturer type does not match. Manufacturer is {0} and it should be {1}.", id, Manufacturer.Identification))
End If
If TypeOf Me.Media Is GXNet AndAlso Manufacturer.UseIEC47 Then
Client.InterfaceType = InterfaceType.WRAPPER
Else
Client.InterfaceType = InterfaceType.HDLC
End If
Client.UseLogicalNameReferencing = Manufacturer.UseLogicalNameReferencing
'If network media is used check is manufacturer supporting IEC 62056-47
Dim server As GXServerAddress = Manufacturer.GetServer(HDLCAddressing)
Client.ClientAddress = Manufacturer.GetAuthentication(Client.Authentication).ClientAddress
If Client.InterfaceType = InterfaceType.WRAPPER Then
If HDLCAddressing = HDLCAddressType.SerialNumber Then
Client.ServerAddress = GXDLMSClient.GetServerAddress(server.PhysicalAddress, server.Formula)
Else
Client.ServerAddress = server.PhysicalAddress
End If
Client.ServerAddress = InlineAssignHelper(Client.ClientAddress, 1)
Else
If HDLCAddressing = HDLCAddressType.SerialNumber Then
Client.ServerAddress = GXDLMSClient.GetServerAddress(server.PhysicalAddress, server.Formula)
Else
Client.ServerAddress = GXDLMSClient.GetServerAddress(server.LogicalAddress, server.PhysicalAddress)
End If
End If
End Sub
Hello Mikko very thanks, the conection is succesfull!, but I don't get values.
The code used is:
Dim it As GXDLMSProfileGeneric = New GXDLMSProfileGeneric("0.1.98.1.0.255")
Dim Data As Object = comm.Read(it, 3)
For Each it2 As Object In TryCast(Data, System.Collections.IList)
For Each c As GXKeyValuePair(Of GXDLMSObject, GXDLMSCaptureObject) In it.CaptureObjects
c.Key.GetValues()
Console.WriteLine(c.Key.LogicalName & " Description:" & c.Key.Description & " Valor: " & c.Value.DataIndex)
Next
Next
But c.Value.DataIndex does not show any value. :( :( :(
The Console.WriteLine show:
Console.WriteLine(c.Key.LogicalName & " Description:" & c.Key.Description & " Valor: " & c.Value.DataIndex)
---> 1.1.1.7.0.255 Description:Ch. 1 Sum Li Active power+ (QI+QIV) Inst. value Valor: 0
---> 1.1.3.7.0.255 Description:Ch. 1 Sum Li Reactive power+ (QI+QII) Inst. value Valor: 0
---> 1.1.14.3.0.255 Description:Ch. 1 Supply frequency Min. 1 Rate 0 (0 is total) Valor: 0
---> 1.1.13.3.0.255 Description:Ch. 1 Sum Li Power factor Min. 1 Rate 0 (0 is total) Valor: 0
Now you have read capture objects. That is like columns.
You need to read the buffer. It's attribute 2.
You can use ReadByRange or ReadByEntry methods to read values.
Hi,
Hi,
Data is correct and the meter should reply. What is a model of your L+G meter?
BR,
Mikko
Hello Kurimi thank's,
Hello Kurimi thank's,
The error was in the configuration of the cable. It works now. But the problem now is that it only allows you to connect to the Landys meter model 2018 with user None:
auth = DirectCast ([Enum] .Parse (GetType (Authentication), "None"), Authentication)
pw = "Nil"
With user Low does not allow, the password used is "00000000"
The error show:
Gurux.DLMS.GXDLMSException: 'Connection is permanently rejected. Authentication failure.'
Thanks for your help.
Hi,
Hi,
Have you changed the client address?
BR,
Mikko
Hi Kurumi, do you mean the ip
Hi Kurumi, do you mean the ip address? Thank's.
Hi Mikko, Excuse me, The
Hi Mikko, Excuse me, The following code does not work for me.
I try to read the code "1.0.99.10.2.255" in meter ACE6000 model 2015 with user Low.
Note: I download all codes in one conecction, but one code only not.
The code is:
Dim eop As Object = CByte(&H7E)
If comm.Client.InterfaceType = InterfaceType.WRAPPER AndAlso TypeOf media Is GXNet Then
eop = Nothing
End If
Dim p As New ReceiveParameters(Of Byte())()
p.Eop = eop
p.Count = 5
p.WaitTime = 5000
Dim PR As New GXDLMSObject ' GXDLMSProfileGeneric()
PR.LogicalName = "1.0.99.10.2.255"
media.Send(comm.Read(PR, 2), Nothing) '
The error is here: ERROR-> Gurux.DLMS.GXDLMSException: 'Access Error : Device reports scope of access violated.'
media.Receive(p)
Console.WriteLine("-> " + DateTime.Now.ToLongTimeString() + vbTab + GXCommon.ToHex(p.Reply, True))
Help me please.
Very Thank's.
Hi Jorge,
Hi Jorge,
No, client address is not IP address. You give client address when you create an instance of GXDLMSClient object.
BR,
Mikko
Thank's Mikko, we use the
Thank's Mikko, we use the next functions in code example .net
Public Sub InitializeConnection(man As GXManufacturer)
Manufacturer = man
UpdateManufactureSettings(man.Identification)
......
...
Public Sub UpdateManufactureSettings(id As String)
If Manufacturer IsNot Nothing AndAlso String.Compare(Manufacturer.Identification, id, True) <> 0 Then
Throw New Exception(String.Format("Manufacturer type does not match. Manufacturer is {0} and it should be {1}.", id, Manufacturer.Identification))
End If
If TypeOf Me.Media Is GXNet AndAlso Manufacturer.UseIEC47 Then
Client.InterfaceType = InterfaceType.WRAPPER
Else
Client.InterfaceType = InterfaceType.HDLC
End If
Client.UseLogicalNameReferencing = Manufacturer.UseLogicalNameReferencing
'If network media is used check is manufacturer supporting IEC 62056-47
Dim server As GXServerAddress = Manufacturer.GetServer(HDLCAddressing)
Client.ClientAddress = Manufacturer.GetAuthentication(Client.Authentication).ClientAddress
If Client.InterfaceType = InterfaceType.WRAPPER Then
If HDLCAddressing = HDLCAddressType.SerialNumber Then
Client.ServerAddress = GXDLMSClient.GetServerAddress(server.PhysicalAddress, server.Formula)
Else
Client.ServerAddress = server.PhysicalAddress
End If
Client.ServerAddress = InlineAssignHelper(Client.ClientAddress, 1)
Else
If HDLCAddressing = HDLCAddressType.SerialNumber Then
Client.ServerAddress = GXDLMSClient.GetServerAddress(server.PhysicalAddress, server.Formula)
Else
Client.ServerAddress = GXDLMSClient.GetServerAddress(server.LogicalAddress, server.PhysicalAddress)
End If
End If
End Sub
¿that is the address?
Thank's.
Hi Jorge ,
Hi Jorge ,
It's Client.ClientAddress. Download GXDLMSDirector and connect with that. In that way, you can see the correct client and server address.
BR,
Mikko
Hello Mikko very thanks, the
Hello Mikko very thanks, the conection is succesfull!, but I don't get values.
The code used is:
Dim it As GXDLMSProfileGeneric = New GXDLMSProfileGeneric("0.1.98.1.0.255")
Dim Data As Object = comm.Read(it, 3)
For Each it2 As Object In TryCast(Data, System.Collections.IList)
For Each c As GXKeyValuePair(Of GXDLMSObject, GXDLMSCaptureObject) In it.CaptureObjects
c.Key.GetValues()
Console.WriteLine(c.Key.LogicalName & " Description:" & c.Key.Description & " Valor: " & c.Value.DataIndex)
Next
Next
But c.Value.DataIndex does not show any value. :( :( :(
The Console.WriteLine show:
Console.WriteLine(c.Key.LogicalName & " Description:" & c.Key.Description & " Valor: " & c.Value.DataIndex)
---> 1.1.1.7.0.255 Description:Ch. 1 Sum Li Active power+ (QI+QIV) Inst. value Valor: 0
---> 1.1.3.7.0.255 Description:Ch. 1 Sum Li Reactive power+ (QI+QII) Inst. value Valor: 0
---> 1.1.14.3.0.255 Description:Ch. 1 Supply frequency Min. 1 Rate 0 (0 is total) Valor: 0
---> 1.1.13.3.0.255 Description:Ch. 1 Sum Li Power factor Min. 1 Rate 0 (0 is total) Valor: 0
Thank's for your time and help.
Hi Jorge ,
Hi Jorge ,
Now you have read capture objects. That is like columns.
You need to read the buffer. It's attribute 2.
You can use ReadByRange or ReadByEntry methods to read values.
BR,
Mikko