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. I Can't Compile The Client Code In Microchip Controller

I can't compile the Client code in Microchip controller

By Sanketp , 26 April, 2024
Forums
Gurux.Serial

Hi,
I am using Microchip PIC32MX350F256L controller for implementing the code. I try with Hardcoded data as per below and Got data successfully in the buffer from the Energy meter using serial communication
"Send SNRM request.
TX: 7E A0 07 03 41 93 5A 64 7E
RX: 7E A0 1E 41 03 73 8E 7F 81 80 12 05 01 80 06 01 80 07 04 00 00 00 01 08 04 00 00 00 01 53 3B 7E

Send AARQ request.
TX: 7E A0 4C 03 41 10 6B 04 E6 E6 00 60 3E A1 09 06 07 60 85 74 05 08 01 01 8A 02 07 80 8B 07 60 85 74 05 08 02 01 AC 12 80 10 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 BE 10 04 0E 01 00 00 00 06 5F 1F 04 00 62 1E 5D FF FF 64 C7 7E
RX: 7E A0 37 41 03 30 21 79 E6 E7 00 61 29 A1 09 06 07 60 85 74 05 08 01 01 A2 03 02 01 00 A3 05 A1 03 02 01 00 BE 10 04 0E 08 00 06 5F 1F 04 00 00 10 14 00 C8 00 07 92 70 7E
"

So I am trying to add a library of "GuruxDLMS.c" in our code but there are so many generated errors so I need help to find which macro used for proper output using this library for the controller in serial mode?

Profile picture for user Kurumi

Kurumi

2 years 3 months ago

Hi, You need to add the…

Hi,

You need to add the development folder to your project.

DLMS is quite a complicated protocol. You need all the files in that folder.

Then you need to establish connection to the meter as shown in this example

https://github.com/Gurux/GuruxDLMS.c/blob/master/Arduino_IDE/client/cli…

You need also modify readDLMSPacket so it can send and receive with your UART.

BR,
Mikko

  • Create new account
  • Reset your password

Hire Us!

Latest Releases

  • Thu, 07/23/2026 - 16:19
    gurux.dlms.java 4.0.96
  • Thu, 07/09/2026 - 14:34
    Gurux.DLMS.Python 1.0.201
  • Fri, 06/26/2026 - 16:32
    Gurux.Service 3.0.2606.2601
  • Wed, 06/24/2026 - 08:36
    Gurux.DLMS.Python 1.0.200
  • Mon, 06/15/2026 - 08:52
    gurux.dlms.c 9.0.2606.1501

New forum topics

  • Service not known error on gprs communication
  • Service not known error on gprs communication
  • Help Needed: Interfacing Saral 100 Energy Meter with Microcontroller via RS232
  • Connecting Meter to Agent via serial
  • Reading block profile with Compact array
More
RSS feed
Privacy FAQ GXDN Issues Contact
Follow Gurux on Twitter Follow Gurux on Linkedin