Search
PLCIO Blog
 
11/2017 - Version 4.5.2
02/2017 - Version 4.5.1
12/2015 - Version 4.5.0
10/2014 - Version 4.4.1
01/2013 - Version 4.4.0
06/2011 - Web Site Update
02/2011 - Version 4.3.1
01/2011 - Version 4.3.0
06/2010 - Version 4.2.1
12/2009 - Version 4.2.0
01/2008 - Version 4.1.1
10/2007 - Using "testplc" for basic communications testing
08/2007 - Replacing A-B INTERCHANGE with PLCIO
08/2007 - Determining array size in a ControlLogix PLC
Using testplc to perform basic communications testing
The PLCIO library also ships with a variety of working sample programs that help in learning to use the library. One of these programs (testplc) provides a read/write interface to many different styles of PLC devices. As can be seen in the help page from the application, this simple program can write to four (or more) different devices. While you primarily use testplc only as a communications diagnostic, take care when you run it, as this application can overwrite PLC data without any confirmation.

The testplc usage page:



Usage: testplc [r|w] "module & hostname/port" "address" #bytes [values...]
Examples:
   Read 10 bytes from N7:0
     testplc r "abeth 192.168.0.2" "N7:0" 10

   Read 1 boolean bit from I3.5
     testplc r "step7 10.1.0.14" "I3.5" 1

   Write the word "200" to N7:10
     testplc w "cip 192.168.1.250" "N7:10" 2 200

   Write 5 words (200,201,202,203,204) starting at DB12.DW20
     testplc w "step5 /dev/ttyS0" "DB12.DW20" 10 200

Use * in front of the module name to turn on debugging output.

                                                        
 
© 2018 Commercial Timesharing, Inc. (CTI) All Rights Reserved      |     PLCIO is product of CTI      |     www.comtime.com     |     ph: 330.644.3059