Sign in to follow this  
Followers 0
a.yearsley

Modbus comms via PointIO

5 posts in this topic

I have a CompactLogix (L43) PLC with Point IO remote rack (comms via DeviceNet). I want to talk Modbus (either RTU or ASCII) to a device near the remote rack. Has anyone ever tried communicating via Modbus (either RTU or ASCII) via a Point I/O serial comms card (1734-485ASC)? Is this even possible?

Share this post


Link to post
Share on other sites
Have not actually done it but at least theoretically, yes it works. AB has a complete library of code in their sample code web site for implementing Modbus/RTU. Shouldn't be any difficulty in doing it other than the usual Modbus frustrations (everyone seems to have a slightly different implementation).

Share this post


Link to post
Share on other sites
Good to know it's theoretically possible. Browsing through the sample code it looks like a bit of work handling all the data ... but obviously possible. One question - how would we access the serial data from the PointIO rather than from the on-board serial port?

Share this post


Link to post
Share on other sites
On board, obviously, you'd use the serial port commands. For the Point IO module, cruise on over to literature.rockwellautomation.com and look up the user manual as a first step. Usually Rockwell sends anything you buy with a 1-2 page "install manual", sometimes a bit longer for drives. If it is anything more complicated than a simple IO module, there will be a corresponding User Manual which is much longer and contains the information you are seeking, often including sample code. This is especially true with Rockwell's drives, and even their diagnostic IO cards have separate user manuals. The second manual that you really should have if you don't already have it is the Modbus manual itself. Head on over to modbus.org and download it for FREE. This is probably the #1 reason that Modbus is prevalent on EVERY PLC brand out there...that the protocol is very simple and that the documentation is completely free, unlike certain other protocols (DeviceNet, Profibus, OPC). If you read through the manual on this device, it is VERY sophisticated, much nicer than the serial port in the processor. There are several different ways you can arrange to receive/send data but the salient point is that eventually you end up with a string. For transmitting, you load the string into the module's memory and set the string length field. Then change (increment) the "transaction ID" field and off the transmission will go. Similar activity happens for receiving except in reverse. You can easily duplicate the IO interface. However, there's a second approach. The device also contains automatic recognition for start and end delimiters. By programming these, you can make the module automatically capture and pre-process your Modbus data for you so that you could rewrite the code to read/write the Modbus signals directly out of the ASCII module's buffer. This simplifies all the buffering logic that goes into the Modbus sample code (actually making it so simple that writing your own is probably easier) but increases your programming workload.

Share this post


Link to post
Share on other sites
Thanks for the info paulengr. Time for some further research. I may end up purchasing a modbus to devicenet gateway device instead, as there's only the 1x modbus slave we need to talk to. This should simplify matter in the PLC with only 1 comms network to deal with.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0