Hi,
I am using C++ Server code for communicating to GxDLMSDirector using Logicalname server (i.e 4061).
I am able to complete basic commincation from server to client .
Now I need to add load profile object ("1.0.99.1.0.255") for sending multiple OBIS code .
But code for profile load object (CGXProfileGenericObject ) is commented inside GDLMSBase.cpp .
Please guide me to add the same.
Thank you for update .
Even in the updated code profilegeneric object implementation in still commented.
We need to know how to use profile generic object functionality .
Hi, We got an error while compiling the updated server C++ code as below:
GXDLMSBase.cpp:491:37: error: no matching function for call to ‘std::vector<CGXDLMSVariant>::push_back(CGXDateTime)’
row.push_back(CGXDateTime::Now());
Kindly let us know how to resolve this.
Thank you.
hi , this change fixed the compilation error .
After running Server we are trying to read data from client, but it is giving error that getObject failed (ON GXDLMSDirrector).
ON client code:
GURUX_DLMS_CLIENT.out: /home/swapnilc/PROJECT_DCU/GuruWorkspace/GURUX_DLMS_CLIENT/development/src/GXHelpers.cpp:1235: static int GXHelpers::GetData(CGXByteBuffer&, CGXDataInfo&, CGXDLMSVariant&): Assertion `0' failed.
Aborted (core dumped)
Hi,
I am getting errors while building library it self ...one of the error message is mentioned below:
In member function ‘int CGXDLMSClient::Read(CGXDLMSObject*, int, std::vector<CGXByteBuffer>&)’:
src/GXDLMSClient.cpp:866:92: error: no matching function for call to ‘CGXDLMSClient::Read(CGXDLMSVariant, DLMS_OBJECT_TYPE, int&, NULL, std::vector<CGXByteBuffer>&)’
return Read(pObject->GetName(), pObject->GetObjectType(), attributeOrdinal, NULL, reply);
Hi,
Thanks you for the update.
We ran the server side code and tried getting the data on Director.
for Profile GenericClass it is throwing a message box saying "Acess Error: Device reports a hardware fault".
Kindly let us know what does this mean.
We would like to know if we have to update the version of director installed on our machine aswell, if needed.
Hi ,
I have given manufacturer as Gurux inside GXDLMSdirector and I am only checking with dirrector itself and not with any hardware meter(we will be using our own hardware meters in future) .
Also I have downloaded updated code and working on it .but not able to set values inside capture object buffer .
Can you help me out with setting the object value inside capture buffer ??And how to add multiple objects to capture buffer??
We downloaded latest copy of Gurux.DLMS.cpp and trying to communicate with Gurux DLMS Director. we get all object except profilegeneric.
when we trying to read profilegeneric object from Gurux DLMS Director we are getting error as "Acess Error: Device reports a hardware fault". and socket get disconnected.
Please can you tell us how to resolve this issue.
Thanks for update .It resolved the hardware fault issue .
Can i know how to capture() functionality should be implemented for updating profile generic data ?I have gone through the java as well as c# implementation for same but not compeletly clear about function yet .
Hi,
Hi,
We checked the profile generic class in C++.
and implemneted the following line of code in init() of GXDLMSBase.cpp file.
CGXDLMSProfileGeneric* pPG = new CGXDLMSProfileGeneric("1.0.99.1.0.255");
pPG->SetCapturePeriod(60);
pPG->SetProfileEntries(100);
pPG->SetSortMethod(GX_SORT_METHOD_FIFO);
pPG->SetSortObject(pClock);
pPG->AddCaptureObject(pClock,2,0);
GetItems().push_back(pPG);
But we could not read the profile generic class in GXDLMSDirector.
Kindly let us know if any step is missing to get the Profile Generic data.
Thank you.
Awaiting your reply.
Not getting CGXProfileGenericObject class definition inside
Hi,
We are just finishing our server side tests with new API. New version is available on this week.
Awaiting for latest code
Awaiting for latest code release .
New version
Hi,
New version is released. We found one issue yesterday and it took longer than expected to fix it.
Get sources here:
https://github.com/Gurux/Gurux.DLMS.cpp
BR,
Mikko
Thank you for update .
Thank you for update .
Even in the updated code profilegeneric object implementation in still commented.
We need to know how to use profile generic object functionality .
Hi ,
Hi ,
I was trying to compile the source code for DLMS server but getting the error .Library and client code is build successfully.
Server example
Hi,
Get new version from GitHub. I was too fast when I updated new version to GitHub and server code for Linux was not commited to our repository.
BR,
Mikko
Profile Generic
Hi,
I updated new example just now where we add profile generic for server example.
Get latest version from GitHub.
BR,
Mikko
Compilation error
Hi, We got an error while compiling the updated server C++ code as below:
GXDLMSBase.cpp:491:37: error: no matching function for call to ‘std::vector<CGXDLMSVariant>::push_back(CGXDateTime)’
row.push_back(CGXDateTime::Now());
Kindly let us know how to resolve this.
Thank you.
Compilation error
Hi,
I updated example. Get new version.
BR,
Mikko
Get Object failed error on client side
hi , this change fixed the compilation error .
After running Server we are trying to read data from client, but it is giving error that getObject failed (ON GXDLMSDirrector).
ON client code:
GURUX_DLMS_CLIENT.out: /home/swapnilc/PROJECT_DCU/GuruWorkspace/GURUX_DLMS_CLIENT/development/src/GXHelpers.cpp:1235: static int GXHelpers::GetData(CGXByteBuffer&, CGXDataInfo&, CGXDLMSVariant&): Assertion `0' failed.
Aborted (core dumped)
cpp Server issue
Hi,
Do you got simiilar isssue with updated code ?? Kindly let me know as I am not able to send any object data with this modified code.
Thank you.
cpp Server issue
Dear Swapnil,
we are resolving this.
cpp Server issue
Dear Swapnil,
We have fixed this. Get latest version.
library building failed inside development folder
Hi,
I am getting errors while building library it self ...one of the error message is mentioned below:
In member function ‘int CGXDLMSClient::Read(CGXDLMSObject*, int, std::vector<CGXByteBuffer>&)’:
src/GXDLMSClient.cpp:866:92: error: no matching function for call to ‘CGXDLMSClient::Read(CGXDLMSVariant, DLMS_OBJECT_TYPE, int&, NULL, std::vector<CGXByteBuffer>&)’
return Read(pObject->GetName(), pObject->GetObjectType(), attributeOrdinal, NULL, reply);
Thank you .
Segmentation falt
Hi ,
Tried to run updated code ,but getting segmentation fault .
Segmentation falt
Hi,
Can you tell what compiler and Linux distro you are using?
BR,
Mikko
Compiler and Linux Distro
Hi,
The compiler we are using is Windriver GNU C++ and the Linux Distro is Ubuntu 14.04 LTS.
Thnaks,
Swapnil.
Compiler and Linux Distro
Hi,
and you are using TCP/IP or serial port connection?
BR,
Mikko
TCP/IP
We are using TCP/IP communication .
Linux issue
Hi,
We was finally able to duplicate this error today. We fixed it and new client example is available on GitHub.
BR,
Mikko
Director error for profileGeneric object
Hi,
Thanks you for the update.
We ran the server side code and tried getting the data on Director.
for Profile GenericClass it is throwing a message box saying "Acess Error: Device reports a hardware fault".
Kindly let us know what does this mean.
We would like to know if we have to update the version of director installed on our machine aswell, if needed.
Thank you.
Swapnil.
Director error for profileGeneric object
Hi,
What meter you are using (Manufacturer and model)?
BR,
Mikko
Profile Generic capture object settings
Hi ,
I have given manufacturer as Gurux inside GXDLMSdirector and I am only checking with dirrector itself and not with any hardware meter(we will be using our own hardware meters in future) .
Also I have downloaded updated code and working on it .but not able to set values inside capture object buffer .
Can you help me out with setting the object value inside capture buffer ??And how to add multiple objects to capture buffer??
Thank you .
Profile Generic capture object settings
Hi,
We downloaded latest copy of Gurux.DLMS.cpp and trying to communicate with Gurux DLMS Director. we get all object except profilegeneric.
when we trying to read profilegeneric object from Gurux DLMS Director we are getting error as "Acess Error: Device reports a hardware fault". and socket get disconnected.
Please can you tell us how to resolve this issue.
Regards,
Rahul K.
Profile Generic capture object settings
Hi,
I test this and it worked. What kind of data you have added to profile generic?
BR,
Mikko
Profile Generic data
Hi,
I am using same code of your's as below and I haven't added any data from my side yet .
//Add profile generic (historical data) object.
CGXDLMSProfileGeneric* profileGeneric = new CGXDLMSProfileGeneric("1.0.99.1.0.255");
profileGeneric->SetCapturePeriod(60);
profileGeneric->SetProfileEntries(100);
profileGeneric->SetSortMethod(DLMS_SORT_METHOD_FIFO);
profileGeneric->SetSortObject(pClock);
CGXDLMSCaptureObject * capture = new CGXDLMSCaptureObject(2, 0);
profileGeneric->GetCaptureObjects().push_back(std::pair<CGXDLMSObject*, CGXDLMSCaptureObject*>(pClock, capture));
capture = new CGXDLMSCaptureObject(2, 0);
profileGeneric->GetCaptureObjects().push_back(std::pair<CGXDLMSObject*, CGXDLMSCaptureObject*>(pRegister, capture));
GetItems().push_back(profileGeneric);
std::vector<CGXDLMSVariant> row;
CGXDateTime tmp = CGXDateTime::Now();
row.push_back(tmp);
row.push_back(10);
profileGeneric->GetBuffer().push_back(row);
Where should I look for my error mentione before!!!?
Thanks ,
Swapnil
Profile Generic data
Hi Swapnil,
You was right. We fixed this. Get new version from GitHub.
We was using different settings what you are.
BR,
Mikko
Thanks for update .It
Thanks for update .It resolved the hardware fault issue .
Can i know how to capture() functionality should be implemented for updating profile generic data ?I have gone through the java as well as c# implementation for same but not compeletly clear about function yet .
Thanks ,
Swapnil