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.
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.
Hello,
I am currently trying to access the information on my CX 2000-9 smart meter by Sagemcom. I manage to make the request and get the basic ID info as well as the registers but have no luck getting data regarding the consumption. I have been using the GXDLMSDirector tool as well as using the python scripts. Below is the outputted XML file. What do I need to do to receive consumption data?
<?xml version="1.0" ?>
<Objects>
<GXDLMSClock>
<LN>0.0.1.0.0.255</LN>
<Description>Ch. 0 Clock object #1</Description>
<Time>07/12/2021 16:54:59</Time>
<TimeZone>0</TimeZone>
<Status>0</Status>
<Begin/>
<End/>
<Deviation>0</Deviation>
<Enabled>0</Enabled>
<ClockBase>0</ClockBase>
</GXDLMSClock>
<GXDLMSAssociationLogicalName>
<LN>0.0.40.0.0.255</LN>
<Description>Ch. 0 Current association</Description>
<ClientSAP>16</ClientSAP>
<ServerSAP>1</ServerSAP>
<ApplicationContextName>
<JointIsoCtt>0</JointIsoCtt>
<Country>0</Country>
<CountryName>0</CountryName>
<IdentifiedOrganization>5</IdentifiedOrganization>
<DlmsUA>8</DlmsUA>
<ApplicationContext>1</ApplicationContext>
<ContextId>1</ContextId>
</ApplicationContextName>
<XDLMSContextInfo>
<Conformance>14174208</Conformance>
<MaxReceivePduSize>236</MaxReceivePduSize>
<MaxSendPduSize>236</MaxSendPduSize>
<DlmsVersionNumber>6</DlmsVersionNumber>
<QualityOfService>0</QualityOfService>
<CypheringInfo>00 00 00 00 00 00</CypheringInfo>
</XDLMSContextInfo>
<AuthenticationMechanismName>
<JointIsoCtt>0</JointIsoCtt>
<Country>0</Country>
<CountryName>0</CountryName>
<IdentifiedOrganization>5</IdentifiedOrganization>
<DlmsUA>8</DlmsUA>
<AuthenticationMechanismName>2</AuthenticationMechanismName>
<MechanismId>0</MechanismId>
</AuthenticationMechanismName>
<Secret/>
<AssociationStatus>0</AssociationStatus>
<SecuritySetupReference/>
</GXDLMSAssociationLogicalName>
<GXDLMSAssociationLogicalName>
<LN>0.0.40.0.1.255</LN>
<Description>Ch. 0 Association #1</Description>
<ClientSAP>16</ClientSAP>
<ServerSAP>1</ServerSAP>
<ApplicationContextName>
<JointIsoCtt>0</JointIsoCtt>
<Country>0</Country>
<CountryName>0</CountryName>
<IdentifiedOrganization>5</IdentifiedOrganization>
<DlmsUA>8</DlmsUA>
<ApplicationContext>1</ApplicationContext>
<ContextId>1</ContextId>
</ApplicationContextName>
<XDLMSContextInfo>
<Conformance>14174208</Conformance>
<MaxReceivePduSize>236</MaxReceivePduSize>
<MaxSendPduSize>236</MaxSendPduSize>
<DlmsVersionNumber>6</DlmsVersionNumber>
<QualityOfService>0</QualityOfService>
<CypheringInfo>00 00 00 00 00 00</CypheringInfo>
</XDLMSContextInfo>
<AuthenticationMechanismName>
<JointIsoCtt>0</JointIsoCtt>
<Country>0</Country>
<CountryName>0</CountryName>
<IdentifiedOrganization>5</IdentifiedOrganization>
<DlmsUA>8</DlmsUA>
<AuthenticationMechanismName>2</AuthenticationMechanismName>
<MechanismId>0</MechanismId>
</AuthenticationMechanismName>
<Secret/>
<AssociationStatus>0</AssociationStatus>
<SecuritySetupReference/>
</GXDLMSAssociationLogicalName>
<GXDLMSSapAssignment>
<LN>0.0.41.0.0.255</LN>
<Description>Ch. 0 SAP Assignment</Description>
<SapAssignmentList>
<Item>
<SAP>1</SAP>
<LDN>SAG0166027256</LDN>
</Item>
</SapAssignmentList>
</GXDLMSSapAssignment>
<GXDLMSData>
<LN>0.0.42.0.0.255</LN>
<Description>Ch. 0 COSEM Logical device name</Description>
<Value Type="9" UIType="10">SAG0166027256</Value>
</GXDLMSData>
<GXDLMSSecuritySetup>
<LN>0.0.43.0.5.255</LN>
<Description>Ch. 0 Security setup #5</Description>
<SecurityPolicy>0</SecurityPolicy>
<SecuritySuite>0</SecuritySuite>
<ClientSystemTitle/>
<ServerSystemTitle/>
<Certificates/>
</GXDLMSSecuritySetup>
<GXDLMSData>
<LN>0.0.96.1.0.255</LN>
<Description>Ch. 0 Device ID 1, manufacturing number</Description>
<Value Type="9" UIType="10">0166027256</Value>
</GXDLMSData>
<GXDLMSData>
<LN>0.0.96.1.1.255</LN>
<Description>Ch. 0 Device ID #2</Description>
<Value Type="9" UIType="10"> IBY16</Value>
</GXDLMSData>
<GXDLMSData>
<LN>0.0.96.1.2.255</LN>
<Description>Ch. 0 Device ID #3</Description>
<Value Type="9" UIType="10">contador DLMS0108</Value>
</GXDLMSData>
<GXDLMSData>
<LN>0.0.96.1.3.255</LN>
<Description>Ch. 0 Device ID #4</Description>
<Value Type="9" UIType="10"> </Value>
</GXDLMSData>
<GXDLMSData>
<LN>0.0.96.1.4.255</LN>
<Description>Ch. 0 Device ID #5</Description>
<Value Type="9" UIType="10">SAG0166027256</Value>
</GXDLMSData>
<GXDLMSData>
<LN>0.0.96.1.5.255</LN>
<Description>Ch. 0 Device ID #6</Description>
<Value Type="9" UIType="10">SAGEMCOM </Value>
</GXDLMSData>
<GXDLMSData>
<LN>0.0.96.1.6.255</LN>
<Description>Ch. 0 Device ID #7</Description>
<Value Type="9" UIType="10">V0446</Value>
</GXDLMSData>
<GXDLMSData>
<LN>0.0.96.1.7.255</LN>
<Description>Ch. 0 Device ID #8</Description>
<Value Type="9" UIType="10">B</Value>
</GXDLMSData>
<GXDLMSData>
<LN>0.0.96.1.8.255</LN>
<Description>Ch. 0 Device ID #9</Description>
<Value Type="9" UIType="10">00.00.00.00</Value>
</GXDLMSData>
<GXDLMSData>
<LN>0.0.96.10.7.255</LN>
<Description>Ch. 0 Status register #7</Description>
<Value Type="17">0</Value>
</GXDLMSData>
<GXDLMSData>
<LN>0.0.96.10.8.255</LN>
<Description>Ch. 0 Status register #8</Description>
<Value Type="17">0</Value>
</GXDLMSData>
<GXDLMSData>
<LN>0.0.96.10.10.255</LN>
<Description>Ch. 0 Status register #10</Description>
<Value/>
</GXDLMSData>
<GXDLMSData>
<LN>0.0.96.10.11.255</LN>
<Description>Invalid</Description>
<Value/>
</GXDLMSData>
<GXDLMSData>
<LN>1.0.0.2.0.255</LN>
<Description>Ch. 0 Active firmware identifier</Description>
<Value Type="9">56 30 34 36 34</Value>
</GXDLMSData>
</Objects>
Hi,
Hi,
That information is not available for public authentication. Change authentication level to Low. You also need set a password and client address.
BR,
Mikko
Thank you for the fast reply,
Thank you for the fast reply,
How exactly do I go about finding the client address and the password? I am in Spain and the energy meter is provided by Iberdrola. I have been looking through their documentation and they say nothing about a password.
I am having the same issue.
I am having the same issue. Spoke to my energy distributor and they didn't know anything about a password for my meter.
Hi,
Hi,
Do you have authentication or block cipher keys? They are 16 bytes long keys that can be used to connect to the meter.
This is all the information that you can get with public access. You need to use a higher authentication level to get more data.
BR,
Mikko
Hi Mikko,
Hi Mikko,
I have received two keys using "-C Authenticate" tag seen below.
Authentication key: D0 D1 D2 D3 D4 D5 D6 D7 D8 D9 DA DB DC DD DE DF
Block cipher key: 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F
How exactly do I go about using this to connect to the meter?
Hi,
Hi,
Select "Secured Connection" Tab. Set System title to GXClient. You can use any value where is 8 chars.
Change Security to AuthenticationEncryption.
Set authentication and block cipher key.
Select "Device Settings" tab. Change Authentication to HighGMAC.
Change client address to 1. I don't know if this is the correct value, but you should find it from the documentation.
BR,
Mikko
Dear Mikko,
Dear Mikko,
Thank you for the fast replies.
I get an error "ServiceError Initiate Error exception. Initiate Other" with client address 1. However when I try with any other client address I get "Failed to receive reply from device in given time".
What does "ServiceError Initiate Error exception. Initiate Other" mean?
Dear Santopelufincho,
Dear Santopelufincho,
Try to change Security from AuthenticationEncryption to None. Keep authentication and block cipher keys. One of the settings is wrong. Do you have another application that you can use to read the meter? If I can get a trace from the bytes sent and received, I can get the correct meter settings.
BR,
Mikko
Hi Mikko,
Hi Mikko,
I have tried those settings and I get the same error "ServiceError Initiate Error exception. Initiate Other" when using the GXDLMSDirector. I have also tried using the command "python main.py -S COM10 -a None -C AuthenticationEncryption -T 4758436C69656E74 -A D0D1D2D3D4D5D6D7D8D9DADBDCDDDEDF -B 000102030405060708090A0B0C0D0E0F" on the Gurux.DLMS.Client.Example.python which has resulted in the file below:
gurux_net version: 1.0.17
gurux_serial version: 1.0.15
Authentication: Authentication.NONE
ClientAddress: 0x10
ServerAddress: 0x1
Standard: Standard.DLMS
Security: Security.AUTHENTICATION_ENCRYPTION
System title: 47 58 43 6C 69 65 6E 74
Authentication key: D0 D1 D2 D3 D4 D5 D6 D7 D8 D9 DA DB DC DD DE DF
Block cipher key: 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F
DisconnectRequest
As seen I get an automatic disconnect request. How can I go about getting a trace of the bytes sent?
Again, thank you very much for your time and patience.
Hi,
Hi,
You can get a trace if you add this:
-t Verbose.
It might be that your meter expects that the client system title is different. Check from the docs if there is anything from the client system title. Client system title is 8 bytes long value.
BR,
Mikko
Hi Kurumi,
Hi Kurumi,
I am no longer in the same location I was using the Sagemcom. However, I have retested on a Landis+Gyr. Using the same parameters it appeared to have given me the same message I initially got again without the consumption data. Using -t Verbose, I have gotten this message:
python main.py -S COM10 -o test.txt -C AuthenticationEncryption -B 000102030405060708090A0B0C0D0E0F -A D0D1D2D3D4D5D6D7D8D9DADBDCDDDEDF -t Verbose
gurux_dlms version: 1.0.104
gurux_net version: 1.0.17
gurux_serial version: 1.0.15
Authentication: Authentication.NONE
ClientAddress: 0x10
ServerAddress: 0x1
Standard: Standard.DLMS
Security: Security.AUTHENTICATION_ENCRYPTION
System title: 41 42 43 44 45 46 47 48
Authentication key: D0 D1 D2 D3 D4 D5 D6 D7 D8 D9 DA DB DC DD DE DF
Block cipher key: 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F
TX: 18:17:56 7E A0 07 03 21 93 0F 01 7E
RX: 18:17:56 7E A0 1E 21 03 73 C3 7A 81 80 12 05 01 80 06 01 80 07 04 00 00 00 01 08 04 00 00 00 01 53 3B 7E
TX: 18:17:56 7E A0 57 03 21 10 8A 62 E6 E6 00 60 49 A1 09 06 07 60 85 74 05 08 01 03 A6 0A 04 08 41 42 43 44 45 46 47 48 8A 02 07 80 8B 07 60 85 74 05 08 02 00 BE 23 04 21 21 1F 30 00 00 00 00 1F 58 4B 30 32 AF 28 57 07 70 C6 0D 7E 8F 63 E4 67 43 15 0D AF AA D4 23 33 0F 5E ED 7E
RX: 18:17:56 7E A0 31 21 03 30 F6 37 E6 E7 00 61 23 A1 09 06 07 60 85 74 05 08 01 03 A2 03 02 01 01 A3 05 A1 03 02 01 0E A4 0A 04 08 4C 47 5A 00 31 30 62 46 2C E2 7E
DisconnectRequest
TX: 18:17:56 7E A0 07 03 21 53 03 C7 7E
RX: 18:17:56 7E A0 1E 21 03 73 C3 7A 81 80 12 05 01 80 06 01 80 07 04 00 00 00 01 08 04 00 00 00 01 53 3B 7E
Hi,
Hi,
You try to connect without authentication and the meter expects it. Try to add -a HighGMAC. You can also try with other authentication levels if you have the password.
BR,
Mikko