Actisys IR & Modbus PLC adapter

Thad

Member
Join Date
Mar 2003
Posts
3
I just can't seem to figure out why my ACTiSYS 100 SL won't talk to a Modicon TSX Momentum plc using an iPaQ device. But i think it might be the adapter. We're using a 110xca20300 adapter to interface between the 9PIN on the IR and the RJ45 on the modicon. The iPaQ is sending the expected message to the PC via the IR (but minus the 110xca20300), and the PC is sending a successful test to the PLC using the same code, but the iPaq and the PLC can't seem to talk. HELP! any suggestions?
 
My suggestion? You have to do a little exposition, man !

You are trying to write similar programs on a PC running full-fledged Windows and on a Compaq iPAQ PDA device running the PocketPC 2002 operating system. Both programs communicate using Modbus serial protocol to a Modicon Momentum PLC.

Because the iPAQ device sports a spiffy wireless infrared IrDA port, you're trying to convert from IrDA to RS-232 using a device built just for that purpose, an Actisys 100S-L.

The Momentum controller doesn't have a standard RS-232 DB9 connector like the Actisys device does, so you're using a Modicon DB9/RJ45 adapter, part number 110xca20300 to plug them together.

Evidently the PC can communicate to the Modicon Momentum controller (though I couldn't tell if it's via IrDA or RS-232 from your posting) and the iPAQ can communicate to the PC via IrDA (is this built into the PC or are you using the Actisys for that purpose ?).... but the iPAQ cannot communicate with the Modicon Momentum controller via the Actisys converter and the Modicon wiring adapter.

My first instinct would be to try a null-modem adapter between the Actisys and the 110xca20300. If the Actisys is built to plug directly into a PC serial port (old telecom guys call this "DCE" configuration) and the 100XCA20300 is also built to plug directly into a PC serial port, then when you instead plug them into one another you're plugging Tx to Tx and Rx to Rx, instead of crossing the two. That's what a Null Modem adapter (get thee to the nearest Radio Shack !) will do for you.

If that doesn't do the trick, you're going to have to resort to an RS-232 breakout box to try to figure out the handshaking between the Actisys and the Modicon controller.

I found a good FAQ document on Modicon's site about pinouts of the Momentum controller and how they interface (or don't) with various RS-232 ports on PC's.

http://www.modicon.com/85256BC80062EFB7/all/DB64039AD0DB01FB85256C78005AEB3B!OpenDocument
 
Ken,

I think even with my minimal exposition, you've hit the nail on the head.

Also to clarify:

(is this built into the PC or are you using the Actisys for that purpose ?)....

We are using the Acitsys to communicate with the PC via the iPAQ - sending strings into hpyerterminal from the test program that resides on the iPAQ which should be talking with the PLC (the PC's hpyerterminal receives following string from iPAQ via IR into COM port using a female to female 9 pin adapter-- :01050063FF0098:01050064FF0097
:01050065FF0096)

The PC to PLC test uses the RJ45 to 9pin connector (110xca20300)which plugs directly into the PC com port, and returns the same string (i've attached a .txt file of the return string.)

The iPAQ to Actisys IR to PLC test uses the 110cxa20300 9pin adapter, and doesn't do anything.
Here is the pin out of that adapter:
RJ45 9-pin D-shell
DTR 1 1
TXD 3---2 RXD
RXD 4---3 TXD
DSR 2--|-4 DTR
GND 5--|-5 GND
_______|-6 DSR
________________
CTS 7-| |- 7 RTS
RTS 6-| |- 8 CTS
___________9 RI

cable8 shield---cable of connector


We're searching for a null modem connector right now, and if that fails, we'll make one.

NULL 9pin?

1,6-->4
2 -->3
3 -->2
4 -->1,6
5 -->5
7 -->8
8 -->7


Thanks for your reply, and i'll let you know if this works.
 
Modbus ASCII Protocol-wise, everything looks good. Your iPAQ is requesting to force Modbus address 99, then 100, then 101 high, using a Modbus function code 05. The attachment on your last post seems to show the Momentum controller replying in the affirmative by echoing the command to force Modbus coil 101 high.

What makes me curious now is that I think your Actisys -> PC connection shouldn't work. The Actisys 100S-L user guide says it's a "DTE" type device, and so is the serial port on a typical computer. Therefore you should need a 'null-modem' cable or adapter betweeen the Actisys and the standard PC in order for the PC to receive data from the Actisys device. (check that DB9S/DB9S adapter carefully !)

Your Modicon 100xca20300 cable is already a null-modem type cable. It's DB9 Socket (female) plug should fit directly into the DB9 Pin (male) plug on the Actisys device.

[attachment]

momentum_cable.gif
 
So, there may be something wrong with the handshaking settings on the Actisys or on the Modicon devices. I would recommend turning hardware handshaking OFF for testing purposes.

Are you using the jumpers inside the Actisys 100S-L to configure it's handshaking, or are you using the serial EEPROM ?

What are the handshaking settings for the Momentum controller ?

Was Hyperterminal on your PC set for Hardware Handshaking when you had it correctly receiving strings from the iPAQ via the Actisys ?
 
OK - that female to female 9 pin connector that is used to connect the IR to the PC (which returns the succesful hyperterminal string)is pinned as follows:

2--3
3--2
4--6
5--5
6--4
7--8
8--7

So, now that i've checked it "carefully" [i.e. broke it in half...] i see that it is a null, correct? I suppose that explains why the iPAQ can talk to the PC via the IR device.

BUT... still no communication between the iPAQ and PLC. And i tried a null modem connector in between the 110xca... and the IR device. No luck.

As far as settings go for the Actisys, we're using EEPROM. COM 1, 9600bps, Ignore DSR (NO), Ignore CTS (NO). To access other settings, it appears that one would need to crack the IR device in half. Maybe that's next.

Handshaking for the Momentum controller? No idea. Where can we view that data?

Hyperterminal settings on PC: BPS 9600, Data bits 8, Parity None, Stop bits 1, Flow control None. These settings produce a successful result (string viewable in hpyerterminal) from the iPAQ.

So, what now? Project due tomorrow, and still no cominique.
 
Handshaking and 7 vs. 8 data bits

Thad, I do applaud your willingness to crack, split, and otherwise dismantle equipment to find out how it works.

Two things jump out at me as being possible issues; DSR/DTR handshaking, and the number of Data Bits in your system settings.

By default, RS-232 Modbus Channel 1 on a Momentum CPU uses Modbus RTU protocol with 8 data bits, no parity, and one stop bit.

The protocol strings you posted are clearly Modbus ASCII protocol; the initial colon, the ASCII representation of the bytes, and the CR/LF conclusion frame are unmistakable. Modbus ASCII protocol uses 7 data bits, even parity, and one stop bit.

So I assume that either your PLC programmer(s) changed the Momentum's channel configuration to Modbus ASCII, or you have a protocol conflict.

Your statement (and protocol trace) that the PC was able to communicate with the Momentum controller via the Modicon cable is the contradictory piece of that puzzle.

What was the software running on the PC when it communicated with the Momentum controller ? How did you trap those strings ?

The affirmative reply to a Function 05 command code in Modbus ASCII protocol is identical to the command request itself. Therefore a protocol trace that doesn't identify the direction of each string can't be conclusively said to represent functional communications instead of a loop-back or echo.

I know you are developing communications drivers, but don't you also have the programming software to configure and program the controller ? You should be able to check the configuration of the Modbus port on this controller using the programming software.

[attachment]

ascii_mode_m1.gif
 
Last edited:
Handshaking

In the interest of full disclosure, Thad, I should tell you that I'm working strictly from user manuals I've downloaded from Modicon. I work for one of their major competitors and do not have any first-hand experience with Momentum controllers. I invite any Momentum experts especially those experienced in serial communications, to jump in at any time.

Here's something from the Momentum M1 user's manual that caught my eye:

Auto-Logout Feature
If a programming panel is logged into the CPU via the RS232 serial port and its cable gets disconnected, the CPU automatically logs out the port. This auto-logout feature is designed to prevent a lock-up situation that could prevent other host stations from logging in on other ports.

This implies to me that the Momentum controller always uses DSR/DTR handshaking to detect that a programming cable is connected to the RS-232 port. The connection from Momentum pin 2 (DSR) to the DB9P pins 4 and 6 (DSR and DTR) also shows that the Momentum expects to see a reply to DSR being set high.

If your Actisys is set to ignore DSR, then maybe that's one of the things preventing communications from working correctly. See what effect changing the DSR (aka Connection Control) has on your communications. I think it's probably a combination of handshaking settings and ASCII framing that is mis-matched between the Momentum controller and your iPAQ.
 
Ken, way to go helping out with a competitor's PLC. Excellent thoughts and suggestions. :)

Thad,
It seems your information is coming in as ASCII code. The Momentum default Modbus setting is for RTU (9600, E, 8, 1 stop). So I agree with Ken, you need to confirm the Momentum port set up parameters.

Momentum only looks for handshaking during programming (DSR high and a jumper between RTS and CTS, DTR is not supported), which is done internally to your 110XCA20300 adapter on the RJ45 side. The adapter also sets up the DB9 side for use with Modicon's programming software (DTR-DSR and RTS-CTS). You may need to remove the handshaking from the adapter if your Actisys does not need it.
 

Similar Topics

Hello Everyone, I am using a raC_Opr_NetModbusTCPClient AOI module, as below,. So, I need some assistance to restrict in reducing the poling...
Replies
2
Views
146
I want to communicate my Q series PLC with Factory IO using GX works 2 software, I want to use modbus as server and the ips are as follows plc...
Replies
0
Views
102
Hi folks, I have a Controllogix in communication with a zigbee coordinator using Logix AIO for modbus tcp. This zigbee coordinator have 3 slaves...
Replies
10
Views
375
Hi, I'm setting up a modbus master on an S7-300. It seems to work in OB1 but not when I use it in OB35. Does anyone have any ideas why? Could...
Replies
10
Views
141
Hi Everyone, i was hoping for a little help with this module. i have data that needs to be read from a different plc through the Modbus plus...
Replies
11
Views
309
Back
Top Bottom