Automatic polling for user interrupts in a programmable...

Data processing: generic control systems or specific application – Generic control system – apparatus or process – Sequential or selective

Utility Patent

Rate now

  [ 0.00 ] – not rated yet Voters 0   Comments 0

Details

C710S001000, C710S263000, C710S262000, C710S220000, C712S032000

Utility Patent

active

06169929

ABSTRACT:

BACKGROUND OF THE INVENTION
1. Field of the Invention
The present invention relates generally to programmable controllers of the type used in industrial automation. More particularly, the invention pertains to a method and apparatus for automatically polling for user interrupts in a programmable controller using relay ladder logic.
2. Description of the Prior Art
A programmable controller is a type of general purpose industrial computer which controls the operation of industrial or factory automation equipment or processes, such as an assembly line or a machine tool, in accordance with a stored program. The stored program includes a series of instructions or commands that direct the programmable controller to execute actions.
A typical language for programming the stored program is relay ladder logic, which is well known in the art. In general, a ladder logic program is executed from left to right and from top down to the end of the program. Each line of the ladder logic program is called a rung and contains at least one control instruction and usually contains one or more conditional instructions.
During operation, the programmable controller executes a series of operations that are performed sequentially and repeatedly. In general, this series of operations includes an input scan, a program scan and an output scan. During the input scan, the controller examines the on or off state of the external inputs and temporarily saves the status of the inputs in a memory file. During the program scan, the controller scans the instructions in the ladder logic program, uses the input status from the memory file, and determines if an output will be energized. The results of the program scan are saved to an output memory file. During the output scan, the controller will energize or de-energize its output circuits based on the output memory file to control external devices.
Each rung of a ladder logic program begins with a start of rung (SOR) instruction. While there may be additional input and output instructions combined into any particular rung, the SOR is one instruction that is guaranteed to be present at the beginning of every rung. In ladder logic, interrupts that execute as part of the user's program are only allowed to execute between rungs and not during the execution of the rung.
Heretofore, user interrupts have been controlled by disabling the interrupts when rung processing is occurring and then polling for interrupts to check to see if one has occurred. An example SOR instruction process for polling for an interrupt is depicted below in assembly code:
mov
R0, #InterruptRegister
jnb
R0.0, #SkipInterrupt
call
ProcessInterrupt
SkipInterrupt:
It is desirable to improve the operation of programmable controllers to improve their speed of operation. As will be described in greater detail hereinafter, the method and apparatus of the present invention accomplishes such a task by eliminating the need for conventional polling techniques, as described above, and employs a number of novel features that render it highly advantageous over the prior art.
SUMMARY OF THE INVENTION
Accordingly, it is an object of this invention to provide an improved programmable controller.
Another object of this invention is to provide a method and apparatus to eliminate manual polling techniques for user interrupts using an automatic polling process that provides increased processing performance due to the savings of execution time and memory space penalties incurred from manual polling.
Still another object of this invention is to provide a method and apparatus that can be employed in a cost-effective manner and is well suited for use in micro programmable controllers.
To achieve the foregoing and other objectives, and in accordance with the purposes of the present invention, a programmable controller is provided for controlling the outputs to a plurality of output devices relative to inputs. The controller includes a memory for storing a ladder logic control program having a plurality of ladder logic instruction rungs. Each of the rungs has a start of rung (SOR) instruction. A processor is coupled to the memory for executing the ladder logic control program. The processor is coupled to an I/O module for receiving inputs and sending signals to the plurality of output devices relative to the inputs. User interrupts are disabled during execution of the rungs. During execution of the SOR instruction, a predetermined register, such as the MCR register, is read causing simultaneous enabling of user interrupts which overrides the previously disabled user interrupts to allow the processor to receive an interrupt request signal. The interrupt request signal is thereby received before the read function of the predetermined register has completed.
By automatically enabling and polling user interrupts based on the read function of the MCR register, manual polling for user interrupts during the SOR function is eliminated. The elimination of this manual polling provides increased performance of the programmable controller due to faster execution and less memory access of the SOR instruction.
Other objects, features and advantages of the invention will become more readily apparent upon reference to the following description when taken in conjunction with the accompanying drawings, which drawings illustrate several embodiments of the invention.


REFERENCES:
patent: 4021783 (1977-05-01), Highberger
patent: 4972365 (1990-11-01), Dodds et al.
patent: 5295059 (1994-03-01), Brooks et al.

LandOfFree

Say what you really think

Search LandOfFree.com for the USA inventors and patents. Rate them and share your experience with other people.

Rating

Automatic polling for user interrupts in a programmable... does not yet have a rating. At this time, there are no reviews or comments for this patent.

If you have personal experience with Automatic polling for user interrupts in a programmable..., we encourage you to share that experience with our LandOfFree.com community. Your opinion is very important and Automatic polling for user interrupts in a programmable... will most certainly appreciate the feedback.

Rate now

     

Profile ID: LFUS-PAI-O-2442630

  Search
All data on this website is collected from public sources. Our data reflects the most accurate information available at the time of publication.