advertisement
from the Control department...
How to connect a Modbus slave device to PC when its address is unknown
Computers in manufacturing; also hardware discussion. topic
Posted by Hafeezullah on 15 February, 2012 - 12:10 pm
I need to connect a Modbus RS485 Multifunction Instrument to PC, but unfortunately I don't have its user manual. My question is how I can make it talk to PC if I don't know its address or about its registers. The device is "Ziegler mfm 3440 Multifunction Instrument" which can measure up to 18 Electrical parameters like energy, power, voltage, current etc. I am new to Modbus, Please if someone reply me I shall be very thankful. waiting for replies......Thank you all


Posted by bob peterson on 15 February, 2012 - 2:25 pm
Have you considered downloading a manual for this instrument? or contacting whoever sold it to you?

--
Bob


Posted by Mark Levin on 16 February, 2012 - 2:26 am
Why you not tried to find the manual through search engine.


Posted by NST on 16 February, 2012 - 12:14 pm
You could use a free software tool (ModbusMat by example). It is having an "automatic search" option that will find for you the Modbus ID's on the network. After that you could add an interval of holding registers (1-40 by example) and you will see the voltage that you already know on which register is.

You must also use a Modbus Converter (rs485 to rs232) between the "instrument" and your PC. If your convertor is having rs232 interface you will also need an rs232 to usb adapter (in the case that your PC is not having serial port).

You must also check the baud rate of your connection.

If you have problems please let me know.

best regards,
Alin


Posted by Julie in Austin on 18 February, 2012 - 11:58 am
FTDI makes some nice wire-end terminated USB to RS485 adapters. They are about $30 in quantity 1 from Mouser and come in a number of reasonable lengths. I buy the 1.8 meter (6', more or less) variety, and that's the price I quoted.


Posted by meyyappan.an on 18 February, 2012 - 6:50 am
There is modbus test software available freely in internets. try with that. Your thread need to be little more expressive.


Posted by Hafeezullah on 22 February, 2012 - 10:04 am
> There is modbus test software available freely in internets. try with that. Your
> thread need to be little more expressive.

I have searched the manual on the internet its not available, I also contacted the company but they didn't respond. And the person who sold it don't have a manual.......Now I need to find its id and then try to read/write from/to its registers, the problem is I don't have a map of its registers. I am new to Modbus if someone can help me I should be very thankful. I read that there is Modbus function code that reports slave id, how to use this function?


Posted by Lynn August Linse on 23 February, 2012 - 10:23 am
You shouldn't need to know the registers to find the id, but will find it nearly impossible to use AFTER you find the Id. I'd suggest getting your money back if you have no manual for a Modbus device! Unlike DeviceNET or many other 'browsable' protocols, Modbus needs a manual to explain what you will see.

To do what you want, start with slave Id #1 at 9600 baud, No Parity. Try to poll register 4x00001 (so function 3 call, to read 1 word at offset 0). Message would be the 8 binary bytes 0x01 03 0000 0001 840A (last 2 bytes are the CRC16). If there is no response, try EVEN parity. if no response, try ODD parity. If no response, repeat all of this with 19200 baud, then 2400, 1200, 4800, 38K and so on.

If there is still no response, then begin again with slave #2. Cycle through all the possible baud rates, parity combinations and so on.

By hand, this could take you SEVERAL DAYS to try all baud rates, parity combinations and slave addresses 1 to 255. An automated tool could probably do this in a few hours.

The reason the device may ultimately be useless is a lot of devices 'maximize' resolution by using the full 0 to 65535 values. For example, a power meter may support 10 different sized current-transformers (CT) and use 10 different scaling factors based on the CT size. So if you have 12 Amps of current, you won't ever see the value 12 (or 12000) returned. You won't be able to 'reason' out which register is the Current register by watching the traffic. Plus you'd be expected to write the correct code for your CT into the meter to force the desired scaling.

I'd still suggest getting your money back.


Posted by fereshteh on 28 February, 2012 - 1:59 am
I have the same problem
please let me know if you find solution


Posted by Hafeez on 8 March, 2012 - 5:46 am
> I have the same problem
> please let me know if you find solution

I have changed my Device coz without the manual its useless....


Posted by Andrzej on 12 March, 2012 - 8:19 am
Hello,

At www.modbus.pl you can find the Modbus scanner application. It helps find the proper communication settings at Modbus network.

Regards,
Andrzej

Your use of this site is subject to the terms and conditions set forth under Legal Notices and the Privacy Policy. Please read those terms and conditions carefully. Subject to the rights expressly reserved to others under Legal Notices, the content of this site and the compilation thereof is © 1999-2013 Nerds in Control, LLC. All rights reserved.

Users of this site are benefiting from open source technologies, including PHP, MySQL and Apache. Be happy.


Fortune
We ARE as gods and might as well get good at it.
-- Whole Earth Catalog
Advertise here
Advertisement
our advertisers
Help keep our servers running...
Patronize our advertisers!
Visit our Post Archive