Jim 'Slim' Mimlitz

Jim ‘Slim’ Mimlitz, SCADAmetrics

Over at control.com, a PLC engineer was working to troubleshoot the connection between two PLC’s.

Having done this way back when, I decided to post what I think was a pretty nifty solution.

(Besides, this could be useful for troubleshooting communications between any two pieces of computer equipment, including an EtherMeter.)

In my case, I had both a master and a slave PLC connected via RS-232 serial (null-modem) cable; and I planned to use my notebook computer’s two serial ports to “snoop” the data transmitted from each of these PLC’s.

I cut open the RS-232 cable and used alligator clips to “snoop” the TxD lines from both PLC’s plus the GND line. I did not break the connection, though.

On my notebook (snooper) COM1, I connected my RxD and GND to the Master PLC’s TxD and GND…. and on my notebook (snooper) COM2, I connected my RxD and GND to the Slave PLC’s TxD and GND.

COM1 would listen to (and log) data from the Master; and COM2 would listen to (and log) data from the Slave.

This eliminated the need to have my “snooper” software receive and re-transmit data.  I only needed to listen to, and log data from, each of my notebook’s COM ports.

The reason that this works is because a single RS-232 TxD line is capable of driving two RS-232 RxD lines.

My “snooper” program was written in C++ and compiled with MS VC++ 6.0

Here is a link to the “snooper” source code file…

https://scadametrics.com/src/snooper3.cpp

Jim 'Slim' Mimlitz

About Jim 'Slim' Mimlitz

Licensed Professional Electrical Engineer @ SCADAmetrics. Specialties: Connecting Flow Meters with SCADA, Telemetry, and Building Automation Systems. Electronic Circuit Design, Software Development.

Leave a Reply

Post Navigation