Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 
Reply

Read data from IED using MODBUS RS485

Hello,

 

I want to communicate with my energy analyzer using MODBUS RS485. I have JBUS/MODBUS COM module and USB-RS485 converter on it. 

 

Communication FRame is below.

 

frame.jpg

Slave adres : 0x05

Code(Read) : 3

Starting Address : C550

Data : 4 word 

 

My example code is 0503 C950 0001 03BA

 

But I got this when read data from it.

 

Adsız.jpg

 

 



Yasemin Barutçu
Electrical And Electronics Engineer
0 Kudos
Message 1 of 11
(3,224 Views)

Why don't you try the Modbus library? With just an image, it's impossible to tell whether you are specifying the write characters correctly. Do you have the constant set for hex display?

0 Kudos
Message 2 of 11
(3,217 Views)

...and if you used the ModBus library the CRC bytes would be in the right order.

0 Kudos
Message 3 of 11
(3,214 Views)

First I tried to use modbus library examples. I got this error code. Then I tried to use the other functions.

error.jpg

 

And about the Modbus CRC-16, on this site (http://www.lammertbies.nl/comm/info/crc-calculation.html) I calculated modbus 16 code is "0xDD47" using "0503C6500002".

But when I calculate this code "0503C6500002" on MB CRC-16 I get "

 

CRC2.jpg

 

I'm very new on this system, trying to understand. What am I doing wrong?


Yasemin Barutçu
Electrical And Electronics Engineer
0 Kudos
Message 4 of 11
(3,205 Views)

 

First read this thread

 

The data you use is changing. Now you use: 0503C6500002 The CRC is: F916

 

What is 'GI' My hexadecimal goes up to F. Maybe you have another number system ?!?  Smiley Frustrated

 

In the thread above you can also see how to use the loopback command. Use this to figure out if your connection is OK.

 

How did you connect your RS-485 device. Many errors are made with RS-485 connections.

0 Kudos
Message 5 of 11
(3,203 Views)

Ok I'll read this thread but about CRC-16, before I said, I calculated it in this site (http://www.lammertbies.nl/comm/info/crc-calculation.html) and got this

CRC.jpg

 

but you said it is "F916". :/

 

I'ım usign JBUS/MODBUS module and for connect to my PC I'm using UBS-RS485 converter.


Yasemin Barutçu
Electrical And Electronics Engineer
0 Kudos
Message 6 of 11
(3,201 Views)

Your connection:

 

Tell me how you connect your device. Which pin to which pin, do you use terminators, did you connect ground, 2 or 4 wire RS-485

 

About CRC:

 

There are many ways to calculate CRC all right for their purpose. I use the NI ModBus lib but mostly I use my own VI to communicate with ModBus devices. So if both CRC methods work fine for ModBus I think than that is the correct way.

 

Also try the loopback command from that thread.

0 Kudos
Message 7 of 11
(3,194 Views)

I'm using JBUS/MODBUS module on my IED. and after module I'm using USB/RS485 converter.


Yasemin Barutçu
Electrical And Electronics Engineer
0 Kudos
Message 8 of 11
(3,175 Views)
Highlighted

What is a IED ?

 

If it is like Wiki says ' improvised explosive device' I am out....

 

Do you have a manual of your device ?

 

How did you connect your RS-485 cable ?

 

 

 

0 Kudos
Message 9 of 11
(3,172 Views)

intellegent electronic device like drives, relays etc..

 

On JBUS module it has 3 part : A-, B+, GND

 

And on my  USB/RS485 converter its turkish but you could understand that there is nothing different. 3 part A, B, GND

 

http://www.denizelektronik.com/pdf/dELAb_USB_RS485_CONVERTER.pdf


Yasemin Barutçu
Electrical And Electronics Engineer
0 Kudos
Message 10 of 11
(3,170 Views)