I am trying to cross compile DLMS ANSI C stack files using arm-arago-linux-gnueabi/gcc compiler.
When I create obj and lib directories in development folder and run make command I am getting error as
Error In
src/client.c : In function 'cl_getApplicationAssociationRequest':
error: 'dlmsVARIANT' has no member named 'byteArr' at line 245
Using lib file I am getting error
/home/user/Desktop/Mi/GuruxDLMS.c-master/development/lib/libgurux_dlms_c.a(dlms.o): In function `dlms_getHdlcData':
dlms.c:(.text+0x49f8): undefined reference to `svr_isTarget'
/home/user/Desktop/Mi/GuruxDLMS.c-master/development/lib/libgurux_dlms_c.a(dlms.o): In function `dlms_handledGloDedRequest':
dlms.c:(.text+0x6f24): undefined reference to `svr_isTarget'
dlms.c:(.text+0x6f70): undefined reference to `svr_connected'
/home/user/Desktop/Mi/GuruxDLMS.c-master/development/lib/libgurux_dlms_c.a(gxget.o): In function `getLNAccessRights':
gxget.c:(.text+0x1620): undefined reference to `svr_getAttributeAccess'
gxget.c:(.text+0x1798): undefined reference to `svr_getMethodAccess'
/home/user/Desktop/Mi/GuruxDLMS.c-master/development/lib/libgurux_dlms_c.a(gxget.o): In function `getSNAccessRights':
gxget.c:(.text+0x2db4): undefined reference to `svr_getAttributeAccess'
gxget.c:(.text+0x2efc): undefined reference to `svr_getMethodAccess'
It's interesting that those errors are not coming in our environment, but you can skip those errors
if you copy src and include forlders under development folder to GuruxDLMSServerExample2/dlms folder.
I am passing value to GLFLAGS as
-L/home/parth/Desktop/DLMS_32/GuruxDLMS.c-master/development/lib /home/parth/Desktop/DLMS_32/GuruxDLMS.c-master/GuruxDLMSClientExample/obj/communication.o /home/parth/Desktop/DLMS_32/GuruxDLMS.c-master/GuruxDLMSClientExample/obj/connection.o /home/parth/Desktop/DLMS_32/GuruxDLMS.c-master/GuruxDLMSClientExample/obj/getopt.o
Ok I will try.
one more query when my client program completes reading data my meter shows HDLC on its display for few seconds.
So i am not able to read from meter on continous basis I have to wait for that HDLC message to go off and then only i can reconnect through my client program.
Are you sending disconnect message? Some meters require also release. Send those and connection is closed. There is inactivity timeout after connection is releaset if you don't call those methods.
Hi,
Hi,
We are using several different compilers, but not gnueabi.
What compiler parameters you are using?
BR,
Mikko
From where I can get compiler
From where I can get compiler parameters ? I have only replaced arm-arago-linux-gnueabi/gcc in make file instead of gcc
Hi,
Hi,
You have changed your make file to:
CC = arm-linux-gnueabi-gcc
It works like expected in out test device (Ubunty 64 bit).
Can you run this:
arm-linux-gnueabi-gcc --version
What is your version number?
BR,
Mikko
arm-linux-gnueabi-gcc (Ubuntu
arm-linux-gnueabi-gcc (Ubuntu/Linaro 4.7.3-12ubuntuu1) 4.7.3
My system is ubuntu 32bit 14.04 LTS
Hi,
Hi,
Test linux is Ubuntu 16.04.6 LTS.
gcc is (Ubuntu/Linaro 5.4.0-6ubuntu1~16.04.9) 5.4.0 20160609
It works like expected. Have you ignore any functionality or is this version what you get from github?
BR,
Mikko
Thanks able to compile
Thanks able to compile successfully.
Hi, Good to hear. BR, Mikko
Hi,
Good to hear.
BR,
Mikko
Using lib file I am getting
Using lib file I am getting error
/home/user/Desktop/Mi/GuruxDLMS.c-master/development/lib/libgurux_dlms_c.a(dlms.o): In function `dlms_getHdlcData':
dlms.c:(.text+0x49f8): undefined reference to `svr_isTarget'
/home/user/Desktop/Mi/GuruxDLMS.c-master/development/lib/libgurux_dlms_c.a(dlms.o): In function `dlms_handledGloDedRequest':
dlms.c:(.text+0x6f24): undefined reference to `svr_isTarget'
dlms.c:(.text+0x6f70): undefined reference to `svr_connected'
/home/user/Desktop/Mi/GuruxDLMS.c-master/development/lib/libgurux_dlms_c.a(gxget.o): In function `getLNAccessRights':
gxget.c:(.text+0x1620): undefined reference to `svr_getAttributeAccess'
gxget.c:(.text+0x1798): undefined reference to `svr_getMethodAccess'
/home/user/Desktop/Mi/GuruxDLMS.c-master/development/lib/libgurux_dlms_c.a(gxget.o): In function `getSNAccessRights':
gxget.c:(.text+0x2db4): undefined reference to `svr_getAttributeAccess'
gxget.c:(.text+0x2efc): undefined reference to `svr_getMethodAccess'
Hi,
Hi,
It's interesting that those errors are not coming in our environment, but you can skip those errors
if you copy src and include forlders under development folder to GuruxDLMSServerExample2/dlms folder.
Then try to run make in GuruxDLMSServerExample2.
BR,
Mikko
Actually example program
Actually example program compiled successfully but when i link lib to my program it throws those error during compilation
I am passing value to GLFLAGS
I am passing value to GLFLAGS as
-L/home/parth/Desktop/DLMS_32/GuruxDLMS.c-master/development/lib /home/parth/Desktop/DLMS_32/GuruxDLMS.c-master/GuruxDLMSClientExample/obj/communication.o /home/parth/Desktop/DLMS_32/GuruxDLMS.c-master/GuruxDLMSClientExample/obj/connection.o /home/parth/Desktop/DLMS_32/GuruxDLMS.c-master/GuruxDLMSClientExample/obj/getopt.o
and LLIBS = -lgurux_dlms_c
Hi,
Hi,
Are you doing the client app?
add empty skeletons for missing methods. You can find them from server examples.
BR,
Mikko
Hi,
Hi,
You can also define DLMS_IGNORE_SERVER. In that way, server-side functionality is not included and size is smaller.
BR,
Mikko
where to defined DLMS_IGNORE
where to defined DLMS_IGNORE_SERVER
Hi,
Hi,
You can open gxignore.h file and un-comment it or then you can give it as compiler parameter.
-DDLMS_IGNORE_SERVER
BR,
Mikko
Ok I will try.
Ok I will try.
one more query when my client program completes reading data my meter shows HDLC on its display for few seconds.
So i am not able to read from meter on continous basis I have to wait for that HDLC message to go off and then only i can reconnect through my client program.
Hi,
Hi,
Are you sending disconnect message? Some meters require also release. Send those and connection is closed. There is inactivity timeout after connection is releaset if you don't call those methods.
BR,
Mikko