【正文】
rough the addition of a second power source. This is generally true if analog or external munication modules are present since these require 177。 DC supplies which, in the case of analog modules, must be well regulated.5. Programming unit.The programming unit allows the engineer or technician to enter and edit the program to be executed. In it39。s simplest form it can be a hand held device with a keypad for program entry and a display device (LED or LCD) for viewing program steps or functions, as shown. More advanced systems employ a separate personal puter which allows the programmer to write, view, edit and download the program to the PLC. This is acplished with proprietary software available from the PLC manufacturer. This software also allows the programmer or engineer to monitor the PLC as it is running the program. With this monitoring system, such things as internal coils, registers, timers and other items not visible externally can be monitored to determine proper operation. Also, internal register data can be altered if required to fine tune program operation. This can be advantageous when debugging the program. Communication with the programmable controller with this system is via a cable connected to a special programming port on the controller. Connection to the personal puter can be through a serial port or from a dedicated card installed in the puter.A Programmable Controller is a specialized puter. Since it is a puter, it has all the basic ponent parts that any other puter has。 a Central Processing Unit, Memory, Input Interfacing and Output Interfacing.The Central Processing Unit (CPU) is the control portion of the PLC. It interprets the program mands retrieved from memory and acts on those mands. In present day PLC39。s this unit is a microprocessor based system. The CPU is housed in the processor module of modularized systems.Memory in the system is generally of two types。 ROM and RAM. The ROM memory contains the program information that allows the CPU to interpret and act on the Ladder Logic program stored in the RAM memory. RAM memory is generally kept alive with an onboard battery so that ladder programming is not lost when the system power is removed. This battery can be a standard dry cell or rechargeable nickelcadmium type. Newer PLC units are now available with Electrically Erasable Programmable Read Only Memory (EEPROM) which does not require a battery. Memory is also housed in the processor module in modular systems.Input units can be any of several different types depending on input signals expected as described above. The input section can accept discrete or analog signals of various voltage and current levels. Present day controllers offer discrete signal inputs of both AC and DC voltages from TTL to 250 VDC and from 5 to 250 VAC. Analog input units can accept input levels such as 177。10 VDC, 177。5 VDC and 420 ma. current loop values. Discrete input units present each input to the CPU as a single 1 or 0 while analog input units contain analog to digital conversion circuitry and present the input voltage to the CPU as binary number normalized to the maximum count available from the unit. The number of bits representing the input voltage or current depends upon the resolution of the unit. This number generally contains a defined number of magnitude bits and a sign bit. Register input units present the word input to the CPU as it is received (Binary or BCD).Output units operate much the same as the input units with the exception that the unit is either sinking (supplying a ground) or sourcing (providing a voltage) discrete voltages or sourcing analog voltage or current. These output signals are presented as directed by the CPU. The output circuit of discrete units can be transistors for TTL and higher DC voltage or Triacs for AC voltage outputs. For higher current applications and situations where a physical contact closure is required, mechanical relay contacts are available. These higher currents, however, are generally limited to about 23 amperes. The analog output units have internal circuitry which performs the digital to analog conversion and generates the variable voltage or current output.The first thing the PLC does when it begins to function is update I/O. This means that all discrete input states are recorded from the input unit and all discrete states to be output are transferred to the output unit. Register data generally has specific addresses associated with it for both input and output data referred to as input and output registers. These registers are available to the input and output modules requiring them and are updated with the discrete data. Since this is input/output updating, it is referred to as I/O Update. The updating of discrete input and output information is acplished with the use of input and output image registers set aside in the PLC memory. Each discrete input point has associated with it one bit of an input image register. Likewise, each discrete output point has one bit of an output image register associated with it. When I/O updating occurs, each input point that is ON at that time will cause a 1 to be set at the bit address associated with that particular input. If the input is off, a 0 will be set into the bit address. Memory in today39。s PLC39。s is generally configured in 16 bit words. This means that one word of memory can store the states of 16 discrete input points. Therefore, there may be a number of words of memory set aside as the input and output image registers. At I/O update, the status of the input image register is set according to the state of all discrete inputs and the status of the output image register is transferred to the output unit. This transfer of information typically only occurs at I/O update. It may be forced to occur at other times in PLC39。s which have an Immediate I/O Update mand. This mand will force the PLC to update the I/O at other times although this would be a special case.B