The Cassandra Project banner
plb_dump
by Kevin Millar <kmillar@ihug.co.nz>

#---------------------------------------------------------------------+
#  Copyright (c) 2000 Kevin Millar. All Rights Reserved.              |
#                                                                     |
#                  http://thecassandraproject.org/                    |
#                                                                     |
#  This is free software; you can redistribute it and/or modify it    |
#  under the terms of the GNU General Public License as published by  |
#  the Free Software Foundation; either version 2 of the License, or  |
#  (at your option) any later version.                                |
#                                                                     |
#  This software is distributed in the hope that it will be useful,   |
#  but WITHOUT ANY WARRANTY; without even the implied warranty of     |
#  merchantability or fitness for a particular purpose. See the GNU   |
#  General Public License (http://www.fsf.org/copyleft/gpl.htm)for    |
#  more details.                                                      |
#                                                                     |
#  To obtain the GNU General Public License, write to:                |
#                                                                     |
#      Free Software Foundation, Inc.                                 |
#      59 Temple Place - Suite 330                                    |
#      Boston, MA  02111-1307                                         |
#      USA                                                            |
#---------------------------------------------------------------------+

This utility reads the ladder logic definition file for an I/A PLB block, and prints the contents of the file to the standard output device. The output can include a list of the labels used (or all labels in the block), the ladder logic of the block, a cross-reference list of the labels used and timer/counter preset and reset values.

The ladder logic definition files are binary files stored in the compound directory, named after the block and with a .p extension. Typcially, the compound directories are located under the Control Configurator directory. By default, the utility will assume the compound directories are located in the directory /opt/fox/ciocfg/. This is the standard location for stations hosted by a 51-Series processor.

To start the program use the following syntax:

           plb_dump  [options] CMPND BLOCK

           default options are -l -r -x

Options:

-help
prints the help pages.

Output Options:

-l[a]
prints the labels (and types) of the TechIDs used within the PLB block. The additional 'a' option will force the utility to output the labels for ALL of the TechIDs. The inputs to the PLB block (contacts and flags) are shown as normally open contacts.

-t[a]
prints a list of the preset and reset values defined for the timers and counters. The additional 'a' option will force the utility to output the labels for ALL of the timers and counters.

-r
prints ladder logic rungs.

-x
print cross-reference listing of the labels used within the ladder logic. Each TechID used is output with its label and a list of rungs that the TechID appears in. If the rung outputs to the TechID, the rung number is marked with a '*'.

Location Option:

-d base_dir
define the name of base directory. By default the utility assumes the compound directories are located in the directory /opt/fox/ciocfg/. This option will allow the utility to load the ladder logic definition files from other locations.

An example of this would be able to access the files from a SaveAll floppy. If the SaveAll floppy is mounted on the directory /f0, use the option "-d /f0" to access the ladder logic files. Use the option "-d ." when the compound directories are located in the current directory.

Format Options:

-p length
set page length (in lines). The default length is 60 lines. For a continuous output, use a length of 0.

-w width
set page width (in characters). The default width is 84 characters. If a narrower width is selected then the timer and counter preset and reset values cannot be printed beside the timer or counter in the ladder logic rungs.

If none of the output options are specified, the utility will output the labels, the ladder logic rungs and cross reference listings.

Version

Version 1.2 - May 1999

Download

Source code and compiled executable are included: plb_dump.tar.Z (47 KB), plb_dump.tar.gz (29 KB), plb_dump.zip (31 KB)

Author

Kevin Millar <kmillar@ihug.co.nz>
Systems/Software Engineer
W. Arthur Fisher Ltd.


Copyright 2000 The Cassandra Project
web posted: 11 August 2000
last updated: 30 October 2000
Contact the webmaster for comments and/or questions.