PLC Modbus TCP data to and from file

J

Thread Starter

James

Hello

I am just wanting to know if there is an application out there (command line based is pref) which you can specify a PLC IP address and the holding registers you want to read, and the number you want to read - and for it to output the contents to a txt file or similar.
I then want the ability to do the reverse and output the contents of the file back to the same PLC.

Basically a backup and restore application for set registers on a Modbus PLC - which an be triggered from somewhere like a SCADA for backup of data prior to planned maintenance or even periodically in case of hardware failure.

If there is anything that you know of, can you please let me know.

This will be talking to Schneider PLC's, specifically the M340 however it will be suitable for any modbus TCP based PLC.
 
R

Robert Willis

Unity Pro has this functionality built in however I am not aware of a command line method to trigger the function. Look for "Transfer Data from PLC to FILE and File to PLC" under the PLC menu.

The HMI should have the ability to create a "recipe" that should allow you to accomplish the task that you are looking for. Depending on the particular HMI being used they may call this functionality something else The HMI can then handle the trigger function for you.
 
C

curt wuollet

Off the shelf might be kinda hard to find, but with the example code on the Modbus site and a compiler you could write one fairly easily if you own a compiler. All you should need are the read and write register commands. You shouldn't need any format conversion if you aren't going to use the data, just store and serve it.

Regards
cww
 
I have a free/open source software command line program that doesn't read or write from files, but could probably be modified fairly easily to do this. I don't have the time to do this myself, but for anyone interested in working on it you can download it from:

http://sourceforge.net/projects/mblogic/

It's in the MBTools package. I use it for simple testing and performance measurement. The changes to do this sound fairly simple if you know a bit of Python.
 
Top