final without hamdy and getting started

65 13 0
final without hamdy and getting started

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

Thông tin tài liệu

Documentation Hardware Introduction 1 Control systems Control Strategies PLC History Mechanical system 9 Motor Types AC Motor DC Motor Stepper Motor Sensors and actuators 16 Introduction Sensor types How do I choose the right sensor Application and Testing 23 Stepper Motor approach Dc motor approach Embedded system Simulated system 30 Alarms Pic microcontrollers 31 PIC18 PIC18F452 Peripherals used 33 INTERRUPTS Timer0 A2D UART Software Introduction 36 Systems concepts 37 Human machine interface 38 Hardware Solutions 39 Remote terminal Unit Supervisory Station Operational philosophy Communication infrastructures and methods SCADA Architecture 41 First Generation: Monolithic Second Generation: Distributed Third Generation: Networked Trends in SCADA 43 Security Issues 44 SW Requirements 46 Program Components 46 DataBase SQL server 2005 56 Introdunction ADO.net 56 Introduction ADO.net Overview Connection Introduction Control systems apply artificial means to change the behavior of a system. The type of control problem often determines the type of control system that can be used. Each controller will be designed to meet a specific objective. The major types of control are : • Continuous The values to be controlled change smoothly. e.g. the speed of a car. • Logical The value to be controlled are easily described as onoff. e.g. the car motor is onoff. NOTE: all systems are continuous but they can be treated as logical for simplicity. e.g. “When I do this, that always happens” For example, when the power is turned on, the press closes • Linear Can be described with a simple differential equation. This is the preferred starting point for simplicity, and a common approximation for real world problems. e.g. A car can be driving around a track and can pass same the same spot at a constant velocity. But, the longer the car runs, the mass decreases, and it travels faster, but requires less gas, etc. Basically, the math gets CONTROL CONTINUOUS DISCRETE LINEAR NON_LINEAR CONDITIONAL SEQUENTIAL e.g. PID e.g. MRAC e.g. FUZZY LOGIC BOOLEAN TEMPORAL e.g. TIMERS e.g. COUNTERS EVENT BASED EXPERT SYSTEMS tougher, and the problem becomes nonlinear. e.g. We are driving the perfect car with no friction, with no drag, and can predict how it will work perfectly. • NonLinear Not Linear. This is how the world works and the mathematics become much more complex. e.g. As rocket approaches sun, gravity increases, so control must change. • Sequential A logical controller that will keep track of time and previous events. The difference between these control systems can be emphasized by considering a simple elevator. An elevator is a car that travels between floors, stopping at precise heights. There are certain logical constraints used for safety and convenience. The points below emphasize different types of control problems in the elevator. Logical: 1. The elevator must move towards a floor when a button is pushed. 2. The elevator must open a door when it is at a floor. 3. It must have the door closed before it moves. etc. Linear: 1. If the desired position changes to a new value, accelerate quickly towards the new position. 2. As the elevator approaches the correct position, slow down. Nonlinear: 1 Accelerate slowly to start. 2. Decelerate as you approach the final position. 3. Allow faster motion while moving. 4. Compensate for cable stretch, and changing spring constant, etc. Logical and sequential control is preferred for system design. These systems are more stable, and often lower cost. Most continuous systems can be controlled logically. But, some times we will encounter a system that must be controlled continuously. When this occurs the control system design becomes more demanding. When improperly controlled, continuous systems may be unstable and become dangerous. When a system is well behaved we say it is self regulating. These systems don’t need to be closely monitored, and we use open loop control. An open loop controller will set a desired position for a system, but no sensors are used to verify the position. When a system must be constantly monitored and the control output adjusted we say it is closed loop. A cruise control in a car is an excellent example. This will monitor the actual speed of a car, and adjust the speed to meet a set target speed. Many control technologies are available for control. Early control systems relied upon mechanisms and electronics to build controlled. Most modern controllers use a complc puter to achieve control. The most flexible of these controllers is the PLC (Programmable Logic Controller). Control Strategies : Open Loop : Feed forward : Closed Loop : Sequential Control : basis of computer operation. digital systems that have outputs dependent on previous system state . Programmable Computing Control Systems : Control device: A programmable logic controller (PLC) or programmable controller is a digital computer used for automation of electromechanical processes, such as control of machinery on factory assembly lines, amusement rides, or lighting fixtures. PLCs are used in many industries and machines, such as packaging and semiconductor machines. Unlike generalpurpose computers, the PLC is designed for multiple inputs and output arrangements, extended temperature ranges, immunity to electrical noise, and resistance to vibration and impact. Programs to control machine operation are typically stored in batterybacked or nonvolatile memory. A PLC is an example of a real time system since output results must be produced in response to input conditions within a bounded time, otherwise unintended operation will result. History Origin The PLC was invented in response to the needs of the American automotive manufacturing industry. Programmable controllers were initially adopted by the automotive industry where software revision replaced the rewiring of hardwired control panels when production models changed. Before the PLC, control, sequencing, and safety interlock logic for manufacturing automobiles was accomplished using hundreds or thousands of relays, cam timers, and drum sequencers and dedicated closedloop controllers. The process for updating such facilities for the yearly model changeover was very time consuming and expensive, as the relay systems needed to be rewired by skilled electricians. In 1968 GM Hydramatic (the automatic transmission division of General Motors) issued a request for proposal for an electronic replacement for hardwired relay systems. The winning proposal came from Bedford Associates of Bedford, Massachusetts. The first PLC, designated the 084 because it was Bedford Associates eightyfourth project, was the result. Bedford Associates started a new company dedicated to developing, manufacturing, selling, and servicing this new product: Modicon, which stood for MOdular DIgital CONtroller. One of the people who worked on that project was Dick Morley, who is considered to be the father of the PLC. The Modicon brand was sold in 1977 to Gould Electronics, and later acquired by German Company AEG and then by French Schneider Electric, the current owner. One of the very first 084 models built is now on display at Modicons headquarters in North Andover, Massachusetts. It was presented to Modicon by GM, when the unit was retired after nearly twenty years of uninterrupted service. Modicon used the 84 moniker at the end of its product range until the 984 made its appearance.The automotive industry is still one of the largest users of PLCs. Development Early PLCs were designed to replace relay logic systems. These PLCs were programmed in ladder logic, which strongly resembles a schematic diagram of relay logic. Modern PLCs can be programmed in a variety of ways, from ladder logic to more traditional programming languages such as BASIC and C. Another method is State Logic, a very highlevel programming language designed to program PLCs based on state transition diagrams. Many of the earliest PLCs expressed all decision making logic in simple ladder logic which appeared similar to electrical schematic diagrams. This program notation was chosen to reduce training demands for the existing technicians. Other early PLCs used a form of instruction list programming, based on a stackbased logic solver. Basic PLC Operation PLCs consist of input modules or points, a Central Processing Unit (CPU), and output modules or points. An input accepts avariety of digital or analog signals from various field devices (sensors) and converts them into a logic signal that can be used by the CPU. The CPU makes decisions and executes control instructions based on program instructions in memory. Output modules convert control instructions from the CPU into a digital or analog signal that can be used to control various field devices (actuators). A programming device is used to input the desired instructions. These instructions determine what the PLC will do for a specific input. An operator interface device allows process information to be displayed and new control parameters to be entered. Pushbuttons (sensors), in this simple example, connected to PLC inputs, can be used to start and stop a motor connected to a PLC through a motor starter (actuator). PLC compared with other control systems PLCs are welladapted to a range of automation tasks. These are typically industrial processes in manufacturing where the cost of developing and maintaining the automation system is high relative to the total cost of the automation, and where changes to the system would be expected during its operational life. PLCs contain input and output devices compatible with industrial pilot devices and controls; little electrical design is required, and the design problem centers on expressing the desired sequence of operations in ladder logic (or function chart) notation. PLC applications are typically highly customized systems so the cost of a packaged PLC is low compared to the cost of a specific custombuilt controller design. On the other hand, in the case of massproduced goods, customized control systems are economic due to the lower cost of the components, which can be optimally chosen instead of a generic solution, and where the nonrecurring engineering charges are spread over thousands or millions of units. For high volume or very simple fixed automation tasks, different techniques are used. For example, a consumer dishwasher would be controlled by an electromechanical cam timer costing only a few dollars in production quantities. A microcontrollerbased design would be appropriate where hundreds or thousands of units will be produced and so the development cost (design of power supplies and inputoutput hardware) can be spread over many sales, and where the enduser would not need to alter the control. Automotive applications are an example; millions of units are built each year, and very few endusers alter the programming of these controllers. However, some specialty vehicles such as transit busses economically use PLCs instead of customdesigned controls, because the volumes are low and the development cost would be uneconomic. Very complex process control, such as used in the chemical industry, may require algorithms and performance beyond the capability of even highperformance PLCs. Very highspeed or precision controls may also require customized solutions; for example, aircraft flight controls. Programmable controllers are widely used in motion control, positioning control and torque control. Some manufacturers produce motion control units to be integrated with PLC so that Gcode (involving a CNC machine) can be used to instruct machine movements. PLCs may include logic for singlevariable feedback analog control loop, a proportional, integral, derivative or PID controller. A PID loop could be used to control the temperature of a manufacturing process, for example. Historically PLCs were usually configured with only a few analog control loops; where processes required hundreds or thousands of loops, a distributed control system (DCS) would instead be used. As PLCs have become more powerful, the boundary between DCS and PLC applications has become less distinct. PLCs have similar functionality as Remote Terminal Units. An RTU, however, usually does not support control algorithms or control loops. As hardware rapidly becomes more powerful and cheaper, RTUs, PLCs and DCSs are increasingly beginning to overlap in responsibilities, and many vendors sell RTUs with PLClike features and vice versa. The industry has standardized on the IEC 611313 functional block language for creating programs to run on RTUs and PLCs, although nearly all vendors also offer proprietary alternatives and associated development environments. Comparison of PLC with Other Control Systems : CCs Relay systems Digital Logics Computers PLC systems Price Per Function Fairly Low Low High Low Physical Size Bulky Very Compact Fairly Compact Very Compact Operating Speed Slow Very Fast Fairly Fast Fast Noise Immunity Excellent Good Fairly Good Good Advantages of PLCs : The same, as well as more complex tasks, can be done with a PLC. Wiring between devices and relay contacts is done in the PLC program. Hardwiring, though still required to connect field devices, is less intensive. Modifying the application and correcting errors are easier to handle. It is easier to create and change a program in a PLC than it is to wire and rewire a circuit. Following are just a few of the advantages of PLCs: • Smaller physical size than hardwire solutions. • Easier and faster to make changes. • PLCs have integrated diagnostics and override functions. • Diagnostics are centrally available. • Applications can be immediately documented. • Applications can be duplicated faster and less expensively. Mechanical system Overview of Motor Types ________________________________________ Motor Types Industrial motors come in a variety of basic types. These variations are suitable for many different applications. Naturally, some types of motors are more suited for certain applications than other motor types are. This document will hopefully give some guidance in selecting these motors. • AC Motors • DC Motors • Brushless DC Motors • Servo Motors • Brushed DC Servo Motors • Brushless AC Servo Motors • Stepper Motors • Linear Motors AC Motors Advantages • Simple Design • Low Cost • Reliable Operation • Easily Found Replacements • Variety of Mounting Styles • Many Different Environmental Enclosures Simple Design The simple design of the AC motor simply a series of three windings in the exterior (stator) section with a simple rotating section (rotor). The changing field caused by the 50 or 60 Hertz AC line voltage causes the rotor to rotate around the axis of the motor. The speed of the AC motor depends only on three variables: 1. The fixed number of winding sets (known as poles) built into the motor, which determines the motors base speed. 2. The frequency of the AC line voltage. Variable speed drives change this frequency to change the speed of the motor. 3. The amount of torque loading on the motor, which causes slip. Low Cost The AC motor has the advantage of being the lowest cost motor for applications requiring more than about 12 hp (325 watts) of power. This is due to the simple design of the motor. For this reason, AC motors are overwhelmingly preferred for fixed speed applications in industrial applications and for commercial and domestic applications where AC line power can be easily attached. Over 90% of all motors are AC induction motors. They are found in air conditioners, washers, dryers, industrial machinery, fans, blowers, vacuum cleaners, and many, many other applications. Disadvantages • Expensive speed control • Inability to operate at low speeds • Poor positioning control Poor positioning control Positioning control is expensive and crude. Even a vector drive is very crude when controlling a standard AC motor. Servo motors are more appropriate for these applications. DC Motors The brushed DC motor is one of the earliest motor designs. Today, it is the motor of choice in the majority of variable speed and torque control applications. Advantages • Easy to understand design • Easy to control speed • Easy to control torque • Simple ,cheap drive design Easy to understand design The design of the brushed DC motor is quite simple. A permanent magnetic field is created in the stator by either of two means: • Permanent magnets • Electromagnetic windings If the field is created by permanent magnets, the motor is said to be a permanent magnet DC motor (PMDC). If created by electromagnetic windings, the motor is often said to be a shunt wound DC motor (SWDC). Today, because of costeffectiveness and reliability, the PMDC motor is the motor of choice for applications involving fractional horsepower DC motors, as well as most applications up to about three horsepower. At five horsepower and greater, various forms of the shunt wound DC motor are most commonly used. This is because the electromagnetic windings are more cost effective than permanent magnets in this power range. Caution: If a DC motor suffers a loss of field (if for example, the field power connections are broken), the DC motor will immediately begin to accelerate to the top speed which the loading will allow. This can result in the motor flying apart if the motor is lightly loaded. The possible loss of field must be accounted for, particularly with shunt wound DC motors. Opposing the stator field is the armature field, which is generated by a changing electromagnetic flux coming from windings located on the rotor. The magnetic poles of the armature field will attempt to line up with the opposite magnetic poles generated by the stator field. If we stopped the design at this point, the motor would spin until the poles were opposite one another, settle into place, and then stop which would make a pretty useless motor However, we are smarter than that. The section of the rotor where the electricity enters the rotor windings is called the commutator. The electricity is carried between the rotor and the stator by conductive graphitecopper brushes (mounted on the rotor) which contact rings on stator. Imagine power is supplied: The motor rotates toward the pole alignment point. Just as the motor would get to this point, the brushes jump across a gap in the stator rings. Momentum carries the motor forward over this gap. When the brushes get to the other side of the gap, they contact the stator rings again and the polarity of the voltage is reversed in this set of rings The motor begins accelerating again, this time trying to get to the opposite set of poles. (The momentum has carried the motor past the original pole alignment point.) This continues as the motor rotates. In most DC motors, several sets of windings or permanent magnets are present to smooth out the motion. Easy to control speed Controlling the speed of a brushed DC motor is simple. The higher the armature voltage, the faster the rotation. This relationship is linear to the motors maximum speed. The maximum armature voltage which corresponds to a motors rated speed (these motors are usually given a rated speed and a maximum speed, such as 17502000 rpm) are available in certain standard voltages, which roughly increase in conjuntion with horsepower. Thus, the smallest industrial motors are rated 90 VDC and 180 VDC. Larger units are rated at 250 VDC and sometimes higher. Specialty motors for use in mobile applications are rated 12, 24, or 48 VDC. Other tiny motors may be rated 5 VDC. Most industrial DC motors will operate reliably over a speed range of about 20:1 down to about 57% of base speed. This is much better performance than the comparible AC motor. This is partly due to the simplicity of control, but is also partly due to the fact that most industrial DC motors are designed with variable speed operation in mind, and have added heat dissipation features which allow lower operating speeds. Easy to control torque In a brushed DC motor, torque control is also simple, since output torque is proportional to current. If you limit the current, you have just limited the torque which the motor can achieve. This makes this motor ideal for delicate applications such as textile manufacturing. Simple, cheap drive design The result of this design is that variable speed or variable torque electronics are easy to design and manufacture. Varying the speed of a brushed DC motor requires little more than a large enough potentiometer. In practice, these have been replaced for all but subfractional horsepower applications by the SCR and PWM drives, which offer relatively precisely control voltage and current. Common DC drives are available at the low end (up to 2 horsepower) for under US100 and sometimes under US50 if precision is not important. Large DC drives are available up to hundreds of horsepower. However, over about 10 horsepower careful consideration should be given to the priceperformance tradeoffs with AC inverter systems, since the AC systems show a price advantage in the larger systems. (But they may not be capable of the applications performance requirments). Disadvantages • Expensive to produce • Can’t reliably control at lowest speeds • Physically larger • High maintenance • Dust A stepper Motor is a brushless, synchronous electric motor that can divide a full rotation into a large number of steps. The motors position can be controlled precisely, without any feedback mechanism (see Openloop controller). Stepper motors are similar to switched reluctance motors (which are very large stepping motors with a reduced pole count, and generally are closedloop commutated.) How Stepper Motors Work Stepper motors consist of a permanent magnet rotating shaft, called the rotor, and electromagnets on the stationary portion that surrounds the motor, called the stator. Figure 1 illustrates one complete rotation of a stepper motor. At position 1, we can see that the rotor is beginning at the upper electromagnet, which is currently active (has voltage applied to it). To move the rotor clockwise (CW), the upper electromagnet is deactivated and the right electromagnet is activated, causing the rotor to move 90 degrees CW, aligning itself with the active magnet. This process is repeated in the same manner at the south and west electromagnets until we once again reach the starting position. Openloop versus closedloop commutation Steppers are generally commutated open loop, ie. the driver has no feedback on where the rotor actually is. Stepper motor systems must thus generally be over engineered, especially if the load inertia is high, or there is widely varying load, so that there is no possibility that the motor will lose steps. This has often caused the system designer to consider the tradeoffs between a closely sized but expensive servomechanism system and an oversized but relatively cheap stepper. A new development in stepper control is to incorporate a rotor position feedback (eg. an encoder or resolver), so that the commutation can be made optimal for torque generation according to actual rotor position. This turns the stepper motor into a high pole count brushless servo motor, with exceptional low speed torque and position resolution. An advance on this technique is to normally run the motor in open loop mode, and only enter closed loop mode if the rotor position error becomes too large this will allow the system to avoid hunting or oscillating, a common servo problem. Stepper motor drive circuits Stepper motor performance is strongly dependent on the drive circuit. Torque curves may be extended to greater speeds if the stator poles can be reversed more quickly, the limiting factor being the winding inductance. To overcome the inductance and switch the windings quickly, one must increase the drive voltage. This leads further to the necessity of limiting the current that these high voltages may otherwise induce Applications Computercontrolled stepper motors are one of the most versatile forms of positioning systems. They are typically digitally controlled as part of an open loop system, and are simpler and more rugged than closed loop servo systems. Industrial applications are in high speed pick and place equipment and multiaxis machine CNC machines often directly driving lead screws or ballscrews. In the field of lasers and optics they are frequently used in precision positioning equipment such as linear actuators, linear stages, rotation stages, goniometers, and mirror mounts. Other uses are in packaging machinery, and positioning of valve pilot stages for fluid control systems. Digital Encoders A digital optical encoder is a device that converts motion into a sequence of digital pulses. By counting a single bit or by decoding a set of bits, the pulses can be converted to relative or absolute position measurements. Encoders have both linear and rotary configurations, but the most common type is rotary. Rotary encoders are manufactured in two basic forms: the absolute encoder where a unique digital word corresponds to each rotational position of the shaft, and the incremental encoder, which produces digital pulses as the shaft rotates, allowing measurement of relative position of shaft. Most rotary encoders are composed of a glass or plastic code disk with a photographically deposited radial pattern organized in tracks. As radial lines in each track interrupt the beam between a photoemitterdetector pair, digital pulses are produced. Absolute encoder The optical disk of the absolute encoder is designed to produce a digital word that distinguishes N distinct positions of the shaft. For example, if there are 8 tracks, the encoder is capable of producing 256 distinct positions or an angular resolution of 1.406 (360256) degrees. The most common types of numerical encoding used in the absolute encoder are gray and binary codes. To illustrate the acion of an absolute encoder, the gray code and natural binary code dsisk track patterns for a simple 4track (4bit) encoder are illustrated in Fig 2 and 3. The linear patterns and associated timing diagrams are what the photodetectors sense as the code disk circular tracks rotate with the shaft. Sensors and actuators INTRODUCTION Sensors allow a PLC to detect the state of a process. Logical sensors can only detect a state that is either true or false. Examples of physical phenomena that are typically detected are listed below. • inductive proximity is a metal object nearby? • capacitive proximity is a dielectric object nearby? • optical presence is an object breaking a light beam or reflecting light? • mechanical contact is an object touching a switch? The language of PLCs consists of a commonly used set of terms; many of which are unique to PLCs. In order to understand the ideas and concepts of PLCs, an understanding of these terms is necessary. Sensor: A sensor is a device that converts a physical condition into an electrical signal for use by the PLC. Sensors are connected to the input of a PLC. A pushbutton is one example of a sensor that is connected to the PLC input. An electrical signal is sent from the pushbutton to the PLC indicating the condition (open closed) of the pushbutton contacts. Actuators: Actuators convert an electrical signal from the PLC into a physical condition. Actuators are connected to the PLC output. A motor starter is one example of an actuator that is connected to the PLC output. Depending on the output PLC signal the motor starter will either start or stop the motor. Generally there are 5 steps to determine which switch type is best suited to the application. This depends on the material properties of the target to be detected. Step ( 1 ) : type of sensor . Step ( 2 ) : Housing design . Step ( 3 ) : Sensing range (mm) Step ( 4 ) : Electrical data and connections Step ( 5 ) : General specifications • Proximity Sensor: A type of sensing switch that detects the presence or absence of an object without physical contact. • Inductive Proximity Sensor: A type of sensing switch that uses an electromagnetic coil to detect the presence of a metal object without coming into physical contact with it. Inductive proximity sensors ignore nonmetallic objects. • Capacitive Proximity Sensor : A type of sensing switch that produces an electrostatic field to detect the presence of metal and nonmetallic objects without coming into contact with them. • Ultrasonic Sensor A type of sensing switch that uses high frequency sound to detect the presence of an object without coming into contact with the object. 1 THE DESIGN PROCESS The design of a technical system involves making choices on the basis of criteria (from a list of requirements), availability of parts and materials, financial resources, and time. These aspects play a significant role when designing a measurement system. Blanchard and Fabrycky (1998) distinguish six major phases of the design process: (a) conceptual design; (b) preliminary design; (c) detail design and development; (d) productionconstruction; (e) operational usemaintenance; (f) retirement – see also (Sydenham, 2004). Thus, sensor selection is a crucial activity in the systems design process, as it will make a great impact on the production of the measurement instrument and the performance during its entire lifetime and may even have consequences related to disposal. Design methods have evolved over time, from purely intuitive (as in art) to formal (managerial). The process of sensor selection is somewhere in between: it is an act of engineering, in which the design is supported by advanced tools for simulating system behavior based on scientific knowledge. The basic attitude is (still) the use ofknowhow contained in the minds of people and acquired. 2 THE REQUIREMENTS Sensor selection means meeting requirements. Unfortunately, these requirements are often not known precisely or in detail, in particular when the designer and the user are different persons. The first task of the designer is to get as much information as possible about the future applications of the measurement instrument, all possible conditions of operation, the environmental factors, and the specifications with respect to quality, physical dimensions, and costs. The list of demands should be exhaustive. Even when not all items are relevant, they must be indicated as such. This will leave more room to the designer, and will minimize the risk of being forced to start all over again at a later date. Rework is an expensive process and should be avoided where possible by reducing errors as early as possible in the systems engineering life cycle process. The requirements list should be made in such a way as to enable unambiguous comparison with the final specifications of the designed instrument. Once the designer has a complete idea about the future use of the instrument, the phase of the conceptual design can start. Before thinking about sensors, the measurement principle has to be considered first. For the instrumentation of each measurement principle, the designer has a multitude of sensing methods at his or her disposal. For realization of a particular sensor method, the designer has to choose the optimal sensor type out of a vast collection of sensors offered by numerous sensor manufacturers How do I Choose the Right Sensor? Step 1: What is the sensing distance required? The sensing distance is the distance between the tip of the sensor and the object to be sensed. The selection guide and the specifications table for each sensor family lists the sensing distances. Some things to keep in mind are: A. In many applications, it is beneficial to place the sensor as far as possible from the sensing object due to temperature concerns. If a sensor is placed too close to a hot temperature source, the sensor will fail quicker and require more maintenance. Greater distance may be achieved with extended and triple range sensors. In many applications, a sensor may not be mountable close to the sensed object. In this case, longer sensing distances are needed. Extended sensing distance sensors are offered in 8mm to 30mm dimeters, and triple sensing distance sensors in 8mm and 12mm formats. In many cases, using an extended distance sensor to get the sensor farther away from the detected object can be beneficial to the life of the sensor. For example, without an extended distance sensor you may not be able to place the sensor close enough to the detectable object, or you may need to buy more expensive high temperature sensors. Another example would be a mechanical overshoot situation, where mounting the sensor farther from the detection object may eliminate unneeded contact with the sensor, thereby extending the life of the sensor. These are just a few examples, but the benefits of using extended distance sensors are obvious in many applications. Think of how extended distance sensors could save you time and money in your application. B. The material being sensed (i.e. brass, copper, aluminum, steel, etc.) makes a difference in the type of sensor needed. Note: If you are sensing a nonmetallic object, you must use a capacitive sensor. The sensing distances specified in this catalog were calculated using FE360 material. Many materials are more difficult to sense and require a shorter distance from the sensor tip to the object sensed. If sensing a material that is difficult to sense, you may consider using our unique stainless steel sensing technology. This will measure virtually all materials at the specified sensing distances. Step 2: How much space is available for mounting the sensor? Have you ever tried using a round sensor or short body version, and not been able to make it fit? Our rectangular sensors can meet your needs. The same technology used in a standard round proximity sensor is enclosed in a rectangular housing. This technology includes sensing distances, electrical protection and switching frequencies similar to round sensors. Step 3: Is a shielded or unshielded sensor needed? Shielded and unshielded sensors are also referred to as embeddable and nonembeddable. Unshielded sensors allow longer sensing distances but shielded sensors allow flush mounting. Step 4: Consider environmental placement concerns. Will the sensor be placed underwater, in a hightemperature environment, continually splashed with oil, etc.? This will determine the type of sensor you may use. In the selection table and in the specification tables for each sensorfamily, we list the environmental protection degree ratings. Most of our sensors are rated IECIP67 and others are rated IP65 or IP68. These ratings are defined as: IP65: Protection from live or moving parts, dust, and protection from water jets from any direction. IP67: Protection from live or moving parts, dust, and protection from immersion in water. IP68: Protection from live or moving parts, dust, and protection from submersion in water under pressure. Step 5: What is the sensor output connected to? Note: If using AC sensors, please skip this step. The type of output required must be determined (i.e., NPN, PNP or analog). Most PLC products will accept either output. If connecting to a solid state relay, a PNP output is needed. Step 6a: Do I need 2, 3, or 4wire discrete outputs? This is somewhat determined by what the sensor will be connected to. Step 6b: Do I need analog outputs? This is determined by the sensor application and what the sensor will be connected to. Sensors with analog outputs produce an output signal approximately proportional to the target distance. Step 7: Determine output connection type. Do you want an axial cable factory attached to the sensor (pigtail) or a quick disconnect cable? There are many advantages to using a quickdisconnect cable, such as easier maintenance and replacement. All proximity sensors will fail in time and using a QD (quickdisconnect) cable allows for simple replacement. Factory attached axial cables come in a 2 meter length. CD08CD12 QD cables come in 2 meter, 5 meter , and 7 meter lengths. Extension cables are available in 1 meter and 3 meter lengths to extend the length of the standard QD cables. QD cables are offered in PVC and PUR jackets for meeting the requirements of all applications. Axial cables typically come with a PVC jacket. PVC is a general purpose insulation while PUR provides excellent oxidation, oil and ozone resistance. PUR is beneficial if the cable is exposed to oils or placed in direct sunlight. There are also advantages to a factory attached axial cable: Cost: The cable is integrate into the sensor and included in the price. QD cables must be purchased separately. Environmental impact: Since the cable is sealed into the sensor, there is less chance of oil, water or dust penetration into the sensor, which could cause failure. MultiAxis Synchronization In many machine control and automation problems, there are two or more axes of motion which must be coordinated. The term multiaxis synchronization refers to the motion which requires coordination, and the techniques used to achieve control of the motion. With today’s increasing automation and machine sophistication, the control applications have become more demanding, and the control techniques have improved. This paper reviews some of the basic elements of motion coordination, illustrated with the requirements of familiar applications. A review of control choices is presented, with special emphasis on a technique called following. The key concepts and capabilities of following are explained with the help of a detailed web processing example. Introduction to MultiAxis Synchronization The term axis of motion refers to one degree of freedom, or forward and backward motion along one direction. It may be linear or rotary motion, and may take the form of a conveyer belt, a rotary knife, or many other types. When two or more axes of motion are involved on a single machine, that machine is employing multiaxis motion. The axes may be working independently, or moving together. The need for multiaxis synchronization arises whenever the axes must move together, and the relationship between their respective motion is important. The most familiar example of a multiaxis application requiring synchronization is that of an XY plotter. Here there are two axes, the X direction and the Y direction. Each may move independently of each other, but if a two dimensional figure is to be drawn accurately, their motion must be coordinated. XY cutting machine In many machines, the synchronization requires more than the coordination of starting and stopping. The position and velocity relationship between the axes will often be important to the proper operation of the machine. For example, if there are interlocking moving parts on a machine, position coordination during motion may be required to avoid collision. If multiple axes control the orientation of a moving part, the position and velocity synchronization of the axes will determine how accurately the part is oriented as it moves. In some cases, a certain velocity or position achieved on one axis will be the signal to start motion on another axis. In such cases, the accuracy of the eventual position relationship of the axes will depend on how accurately the position of first axis is monitored by the second. The Mechanical Approach to Synchronization By definition, synchronization of two or more axes requires a definite relationship between one axis and the others. Before electronic motion control was available, the traditional approach to this had been largely mechanical, using a central motion source. Individual axes were driven from this source with gears and drive trains. The gears determine the speed relationship, and the drive trains deliver the motion to the appropriate place. Such an approach works well if the desired gear ratio is constant and the drive train is short and direct. More complex arrangements require more costly mechanics, and the problems of backlash and mechanical wear become more pronounced. If the relationship desired between axes was not constant, but needed to follow a pattern, mechanical cams were used. The shape of the cam determines the motion pattern of the cam follower with respect to the motion of the cam driver. If the required shape is very complex, the cam can be quite difficult to design, and expensive to machine and produce. Cams are also subject to wear, which directly affects the accuracy and repeatability of the cam follower motion. Individual axes were started and stopped using clutches and brakes. These are required to accelerate and decelerate the load, but as with all mechanics, they suffer the problem of wear. They also do not allow for precise control of the position relationship between axes, because the amount of slip during starting and stopping can not be precisely controlled. Clutches and brakes tend to be rough on the rest of the machinery, because of the sudden jerk when they are engaged. Stepper and Servo Motion Control Systems The availability of electronic motion control has brought solutions to the problems inherent with the mechanical approach to synchronization. To understand how these solutions are achieved, it is helpful to review basic electronic motion control systems. One axis of electronic motion control consists of the motor, the motor drive, and the controller. The controller accepts motion commands from a host computer or an internally stored program. These commands are interpreted by the controller to generate continuously updated position commands (motion profiles) to the drive. The motor drive controls the current to the motor which will result in the commanded position. In a multiaxis system, one controller can control several motor and drive combinations. The motion control system may be a stepper or servo system. Stepper systems tend to be less expensive than servo systems, but have less speed and power for a given size of motor. In stepper systems, the drive receives position commands in the form of low voltage pulses (steps), and adjusts the phase of the current in two sets of motor coils to align the motor shaft. Each new step received corresponds to an additional increment of rotation on the shaft. Current is maintained in the motor coils, even when the motor shaft is in the correct position. Common step motor resolutions range from 200 steps per revolution (full stepping) to 50,000 steps per revolution (microstepping). Servo systems employ motor shaft position feedback , either from an incremental encoder or from a resolver. The actual position and velocity derived from the feedback is compared to that commanded in the motion profile to result in a torque command to the drive. In servo motors, the phase of the current is adjusted according to the actual position of the shaft. It is continuously adjusted to produce maximum torque for a given current amplitude. This process is called commutation, and is done mechanically in brushed motors, and electronically in brushless motors. The drive controls the amplitude of the current to the motor in proportion to the torque command. In analog servo systems, the feedback goes to the controller, and the controller’s output is an analog torque command. In digital servo systems, the drive accepts steps as the position commands, and the shaft feedback goes only to the drive. Servo systems must be tuned to match the load they are moving for the best performance. A properly tuned system results in powerful and precise positioning of the load. The choice of motion control system will depend on the particular application. A dedicated motion control company such as Compumotor can provide any of these systems, as well as expert technical assistance in the design, implementation, and tuning of the system. The Electronic Approach to Synchronization Programmable stepper and servo motor systems provide a direct replacement to mechanical components, and solve many problems. Individual axes are driven from individual motors instead of gears and drive trains. The speed and position relationship between axes is controlled with the controller, and this may be infinitely and continuously adjusted, rather than fixed as with gears. Motors deliver the motion directly to the appropriate place, eliminating the need for drive trains. The problems of backlash and mechanical wear are gone, resulting in precise, repeatable control and reduced maintenance. Complex position relationships between axes may be programmed and stored in the controller as direct replacements for mechanical cams, eliminating the cost and maintenance associated with cams and improving the reliability and accuracy of the resulting motion. Controllers can also accept electronic inputs from sensors, read runtime status from other parts of a machine, and impose delays or dwells. These features give much greater design flexibility and runtime decisionmaking power to a machine than could be achieved with mechanical components. Programmable acceleration and deceleration allow very smooth and controlled starts and stops to individual axes of motion. The smoothness reduces machine wear and makes a machine run more quietly. The control gives better precision in the axis synchronization, which results in better quality in overall machine function. The increased control also allows higher speed moves on the individual axes. This translates directly into increased throughput and higher productivity for a machine. Application and Testing Application: using an automation system to perform a machining process Stepper motor approach : There are 2 channels for positioning in the DRT type of MASTERK120S series. With this function, you are able to do simple position control putting a stepping motor driver or a servo motor together with it. Internal circuit and wiring Positioning function (1) Positioning function Positioning Control includes position control, speed control. (1) Position control Positioning control from start address (present stopped position) to goal address (transfer amount) for the assigned axis A) Control by Absolute method (Absolute coordinate) Positioning control from start address to goal address (the address assigned by positioning data). Positioning control is carried out based on the address assigned (origin address) by return to origin. Transfer direction shall be determined by start address and goal address. • Start address < Goal address : forward direction positioning • Start address > Goal address : reverse direction positioning Example: When Start address is 1000 and goal address is 8000, this will be forward direction and transfer amount shall be 7000 (7000=80001000). • Parameter setting B) Control by Incremental method (Relative coordinate)

Documentation Hardware Introduction Control systems Control Strategies PLC History Mechanical system Motor Types AC Motor DC Motor Stepper Motor Sensors and actuators -Introduction Sensor types How I choose the right sensor Application and Testing -Stepper Motor approach Dc motor approach 16 23 Embedded system Simulated system Alarms Pic microcontrollers PIC18 PIC18F452 Peripherals used INTERRUPTS Timer0 A2D UART - 30 - 31 - 33 Introduction Systems concepts Human machine interface Hardware Solutions Remote terminal Unit Supervisory Station Operational philosophy Communication infrastructures and methods SCADA Architecture First Generation: "Monolithic" Second Generation: "Distributed" Third Generation: "Networked" Trends in SCADA Security Issues S/W Requirements Program Components - 36 37 38 39 Software 41 43 44 46 46 DataBase SQL server 2005 Introdunction ADO.net Introduction ADO.net Overview - 56 - 56 Connection Introduction Control systems apply artificial means to change the behavior of a system The type of control problem often determines the type of control system that can be used Each controller will be designed to meet a specific objective The major types of control are : • Continuous - The values to be controlled change smoothly e.g the speed of a car • Logical - The value to be controlled are easily described as on-off e.g the car motor is on-off NOTE: all systems are continuous but they can be treated as logical for simplicity e.g “When I this, that always happens!” For example, when the power is turned on, the press closes! • Linear - Can be described with a simple differential equation This is the preferred starting point for simplicity, and a common approximation for real world problems e.g A car can be driving around a track and can pass same the same spot at a constant velocity But, the longer the car runs, the mass decreases, and it travels faster, but requires less gas, etc Basically, the math gets CONTROL CONTINUOUS DISCRETE LINEAR NON_LINEAR CONDITIONAL SEQUENTIAL e.g PID e.g MRAC e.g FUZZY LOGIC BOOLEAN TEMPORAL e.g TIMERS e.g COUNTERS EVENT BASED EXPERT SYSTEMS tougher, and the problem becomes non-linear e.g We are driving the perfect car with no friction, with no drag, and can predict how it will work perfectly • Non-Linear - Not Linear This is how the world works and the mathematics become much more complex e.g As rocket approaches sun, gravity increases, so control must change • Sequential - A logical controller that will keep track of time and previous events The difference between these control systems can be emphasized by considering a simple elevator An elevator is a car that travels between floors, stopping at precise heights There are certain logical constraints used for safety and convenience The points below emphasize different types of control problems in the elevator Logical: The elevator must move towards a floor when a button is pushed The elevator must open a door when it is at a floor It must have the door closed before it moves etc Linear: If the desired position changes to a new value, accelerate quickly towards the new position As the elevator approaches the correct position, slow down Non-linear: Accelerate slowly to start Decelerate as you approach the final position Allow faster motion while moving Compensate for cable stretch, and changing spring constant, etc Logical and sequential control is preferred for system design These systems are more stable, and often lower cost Most continuous systems can be controlled logically But, some times we will encounter a system that must be controlled continuously When this occurs the control system design becomes more demanding When improperly controlled, continuous systems may be unstable and become dangerous When a system is well behaved we say it is self regulating These systems don’t need to be closely monitored, and we use open loop control An open loop controller will set a desired position for a system, but no sensors are used to verify the position When a system must be constantly monitored and the control output adjusted we say it is closed loop A cruise control in a car is an excellent example This will monitor the actual speed of a car, and adjust the speed to meet a set target speed Many control technologies are available for control Early control systems relied upon mechanisms and electronics to build controlled Most modern controllers use a complc puter to achieve control The most flexible of these controllers is the PLC (Programmable Logic Controller) - Control Strategies : Open Loop : - Requirements Control plan Action Outcome Plant system Disturbance Feed forward : - Modification to plan taking account of disturbance Requirements Control plan Measurements Measurements of disturbances disturbances of Action Plant system Outcome Disturbance Closed Loop : - Feedback Measured value Requirements )set point( Deviation )error signal( Control Action Plant Compare plan system Disturbance Measurement outcome Sequential Control : basis of computer operation digital systems that have outputs dependent on previous system state Combinational Logic Storage Device Programmable Computing Control Systems : - Data memory Input Data Firmware Output Data Program Control device: A programmable logic controller (PLC) or programmable controller is a digital computer used for automation of electromechanical processes, such as control of machinery on factory assembly lines, amusement rides, or lighting fixtures PLCs are used in many industries and machines, such as packaging and semiconductor machines Unlike generalpurpose computers, the PLC is designed for multiple inputs and output arrangements, extended temperature ranges, immunity to electrical noise, and resistance to vibration and impact Programs to control machine operation are typically stored in battery-backed or nonvolatile memory A PLC is an example of a real time system since output results must be produced in response to input conditions within a bounded time, otherwise unintended operation will result History Origin The PLC was invented in response to the needs of the American automotive manufacturing industry Programmable controllers were initially adopted by the automotive industry where software revision replaced the re-wiring of hard-wired control panels when production models changed Before the PLC, control, sequencing, and safety interlock logic for manufacturing automobiles was accomplished using hundreds or thousands of relays, cam timers, and drum sequencers and dedicated closed-loop controllers The process for updating such facilities for the yearly model change-over was very time consuming and expensive, as the relay systems needed to be rewired by skilled electricians In 1968 GM Hydramatic (the automatic transmission division of General Motors) issued a request for proposal for an electronic replacement for hard-wired relay systems The winning proposal came from Bedford Associates of Bedford, Massachusetts The first PLC, designated the 084 because it was Bedford Associates' eighty-fourth project, was the result Bedford Associates started a new company dedicated to developing, manufacturing, selling, and servicing this new product: Modicon, which stood for MOdular DIgital CONtroller One of the people who worked on that project was Dick Morley, who is considered to be the "father" of the PLC The Modicon brand was sold in 1977 to Gould Electronics, and later acquired by German Company AEG and then by French Schneider Electric, the current owner One of the very first 084 models built is now on display at Modicon's headquarters in North Andover, Massachusetts It was presented to Modicon by GM, when the unit was retired after nearly twenty years of uninterrupted service Modicon used the 84 moniker at the end of its product range until the 984 made its appearance.The automotive industry is still one of the largest users of PLCs Development Early PLCs were designed to replace relay logic systems These PLCs were programmed in "ladder logic", which strongly resembles a schematic diagram of relay logic Modern PLCs can be programmed in a variety of ways, from ladder logic to more traditional programming languages such as BASIC and C Another method is State Logic, a very high-level programming language designed to program PLCs based on state transition diagrams Many of the earliest PLCs expressed all decision making logic in simple ladder logic which appeared similar to electrical schematic diagrams This program notation was chosen to reduce training demands for the existing technicians Other early PLCs used a form of instruction list programming, based on a stack-based logic solver Basic PLC Operation PLCs consist of input modules or points, a Central Processing Unit (CPU), and output modules or points An input accepts avariety of digital or analog signals from various field devices (sensors) and converts them into a logic signal that can be used by the CPU The CPU makes decisions and executes control instructions based on program instructions in memory Output modules convert control instructions from the CPU into a digital or analog signal that can be used to control various field devices (actuators) A programming device is used to input the desired instructions These instructions determine what the PLC will for a specific input An operator interface device allows process information to be displayed and new control parameters to be entered Pushbuttons (sensors), in this simple example, connected to PLC inputs, can be used to start and stop a motor connected to a PLC through a motor starter (actuator) PLC compared with other control systems PLCs are well-adapted to a range of automation tasks These are typically industrial processes in manufacturing where the cost of developing and maintaining the automation system is high relative to the total cost of the automation, and where changes to the system would be expected during its operational life PLCs contain input and output devices compatible with industrial pilot devices and controls; little electrical design is required, and the design problem centers on expressing the desired sequence of operations in ladder logic (or function chart) notation PLC applications are typically highly customized systems so the cost of a packaged PLC is low compared to the cost of a specific custom-built controller design On the other hand, in the case of mass-produced goods, customized control systems are economic due to the lower cost of the components, which can be optimally chosen instead of a "generic" solution, and where the non-recurring engineering charges are spread over thousands or millions of units For high volume or very simple fixed automation tasks, different techniques are used For example, a consumer dishwasher would be controlled by an electromechanical cam timer costing only a few dollars in production quantities A microcontroller-based design would be appropriate where hundreds or thousands of units will be produced and so the development cost (design of power supplies and input/output hardware) can be spread over many sales, and where the end-user would not need to alter the control Automotive applications are an example; millions of units are built each year, and very few end-users alter the programming of these controllers However, some specialty vehicles such as transit busses economically use PLCs instead of custom-designed controls, because the volumes are low and the development cost would be uneconomic Very complex process control, such as used in the chemical industry, may require algorithms and performance beyond the capability of even high-performance PLCs Very high-speed or precision controls may also require customized solutions; for example, aircraft flight controls Programmable controllers are widely used in motion control, positioning control and torque control Some manufacturers produce motion control units to be integrated with PLC so that G-code (involving a CNC machine) can be used to instruct machine movements PLCs may include logic for single-variable feedback analog control loop, a "proportional, integral, derivative" or "PID controller." A PID loop could be used to control the temperature of a manufacturing process, for example Historically PLCs were usually configured with only a few analog control loops; where processes required hundreds or thousands of loops, a distributed control system (DCS) would instead be used As PLCs have become more powerful, the boundary between DCS and PLC applications has become less distinct PLCs have similar functionality as Remote Terminal Units An RTU, however, usually does not support control algorithms or control loops As hardware rapidly becomes more powerful and cheaper, RTUs, PLCs and DCSs are increasingly beginning to overlap in responsibilities, and many vendors sell RTUs with PLC-like features and vice versa The industry has standardized on the IEC 61131-3 functional block language for creating programs to run on RTUs and PLCs, although nearly all vendors also offer proprietary alternatives and associated development environments Comparison of PLC with Other Control Systems :C\Cs Relay systems Digital Logics Computers PLC systems Price Per Function Fairly Low Low High Low Physical Size Bulky Very Compact Fairly Compact Very Compact Operating Speed Slow Very Fast Fairly Fast Fast Noise Immunity Excellent Good Fairly Good Good The Man Program Module     friendly and Interactive user interface, using dock able panels and forms changeable theme and selectable colors Handy toolbars and shortcut keys Keyboard and Mouse Support for drag drop and on fly properties change 50 Dockable panels and forms 1- Authentication Module     Friendly authentication Interface User name and password authentication Support for creating a new user but only with the Control System Administrator Use of encryption and decryption to secure login process 51 2- Communication Module  OPC, TCP, Ether, Serial  PLC, MC, RTU Interfacing  Real time acquisition support  Continuous detection and reporting The New Process Wizard After Entering the data and pressing the next button 52 3- Design Interface           Multi Process Design Support New Open Save Cut Copy Past Undo Redo Component Libraries Drag Drop support Properties Edit/Reset Database Interface Alarms trends and event logging Run/Stop Simulation Report generate/Print Charts and Trends 53 4- Run Time Interface  System Attached Service  Start/Stop Process (Service)  Alarms Trends Display  Issue Change Process Data  Report (request/ View/ Print)  Playback Historians Objects Used in the SW Implementation 54 55 56 Controls Library Dock Panel Library 57 Toolbox Library 58 SQL server 2005 Introduction SQL Server 2005 is Microsoft’s relational database management system (RDBMS) It builds on a legacy of accomplishments spanning more than a decade of SQL Server development and critical success, from SQL Server 6.0, 6.5, 7.0, and 2000 But it is more than that It is the most widely used and most scalable data management system in the world, currently deployed in hundreds of thousands of companies where it is in service day in and day out, storing the records of the digital universe that now supports our very existence Despite the lofty capabilities of this product, and its reputation for being highly complex, one of the key-and ambitious-objectives of this book is to get all database administrators and developers, young and old, using SQL Server 2005 If within a few chapters you don’t see your way to becoming permanently hitched to this product, then my mission has failed This chapter has thus been designed to be a warm-up for the benefit of novice users, traditional desktop RDBMS users, and gurus working on the dependable SQL Server 2000, other platforms, or older versions ADO.NET Microsoft ADO.NET is the latest data access technology from Microsoft ADO.NET is a collection of classes that are part of the NET Framework, and is designed to provide consistent access to data in loosely coupled n-tier application architectures such as web services ADO.NET can be used to access a variety of data sources including databases such as Microsoft SQL Server, Oracle, and Microsoft Access, as well as XML, OLE DB, and ODBC data sources ADO.NET separates data access from manipulation Connected classes available in NET data providers connect to a data source, execute commands, and retrieve results Disconnected classes let you access and manipulate data offline and later synchronize changes with the underlying data source XML support is tightly integrated with ADO.NET, allowing you to load, access, and manipulate data using XML as well as the disconnected classes simultaneously ADO.NET is very different from its predecessor ADO With the increasing popularity of NET and ADO.NET 59 Introduction This part describes how to connect to a variety of data sources from ADO.NET; how to handle security-related issues including storing connection strings and using different authentication methods; and how to set up, monitor, and optimize connection pooling ADO.NET Overview ADO.NET is designed to support data access requirements of loosely coupled ntier application architectures including web services ADO.NET can access a variety of different data sources, including relational databases such as Microsoft SQL Server, Oracle, and Microsoft Access, as well as other data sources such as Microsoft Excel, Outlook, and text files A NET data provider is used to connect to a data source, execute commands, and retrieve results The NET Framework ships with four NET-managed data providers: Microsoft SQL Server, Oracle, OLE DB, and ODBC Other providers are also available—for example, Oracle has developed its own NET data provider for Oracle Data providers also exist for databases such as Sybase and MySQL Database-specific providers usually access the underlying data store directly and offer the best performance, broadest functionality, and support for database-specific features Since a data provider needs only to implement a set of standard interfaces, the capabilities and performance of data providers for the same data source can differ significantly In addition to database-specific providers, the OLE DB NET data provider allows access to most OLE DB data sources through OLE DB providers Similarly, the ODBC NET data provider uses the ODBC drivers to access most ODBC data sources You can also develop your own data provider to access proprietary data sources or to meet special requirements ADO.NET is fundamentally different from ADO despite sharing a similar name ADO.NET is based on a disconnected architecture and has both connected and disconnected classes Each data provider is responsible for providing the :connected classes Connection 60 .A unique session with the data source Command Executes SQL statements and stored procedures against the data source DataReader Forward-only, read-only access to a query result set stream DataAdapter Bridges the connected classes with the disconnected classes; also used to fill a disconnected DataSet and update the data source with changes made to a disconnected DataSet The disconnected classes are part of the ADO.NET classes in the NET Framework They provide a consistent programming model regardless of the :data source or data provider The disconnected classes include DataSet An in-memory relational database DataTable A single table of memory-resident data DataColumn The schema of a column in a DataTable DataRow A row of data in the DataTable DataView A data-bindable view of a DataTable used for custom sorting, filtering, searching, editing, and navigation DataRelation A parent/child relationship between two DataTable objects in a DataSet Constraint 61 A constraint on one or more columns in a DataTable used to maintain data integrity The DataSet retains no information about the source of the data used to fill it with data It maintains both current and original versions of data allowing the data source to be updated with changes at some future time Disconnected data classes facilitate transport-independent marshaling vertically between application tiers and horizontally across a distributed application, and persisting data ADO.NET and XML converge in NET You can save the DataSet as an XML document, or fill it from an XML document You can access and modify data simultaneously using both the DataSet classes and XML classes The DataSet is a disconnected, in-memory relational database that provides sophisticated navigational capabilities It acts as a container for other objects including DataTable, DataColumn, DataRow, and DataRelation The DataAdapter works with the DataSet to update the data source with changes made offline to the DataSet You can also data bind a DataSet to a variety of Windows Forms and Web Forms controls, in particular, any control that supports the IList interface The DataSet maintains both current and original versions of its data Although data appears to be changed, it is not permanently changed until the AcceptChanges( ) method is called either explicitly or implicitly to commit the changes The DataReader provides forward-only, read-only access to a result set The DataReader offers the best performance for accessing data by avoiding the overhead associated with the DataSet The Connection object underlying a DataReader remains open and cannot be used for any other purpose while data is being accessed This makes the DataReader unsuitable for communicating data remotely between application tiers, or interacting with the data dynamically If you want to discard a result set in a DataReader before the entire result set has been read, call the Cancel( ) method of the DataReader before calling the Close( ) method This discards the results on the server so they are not transmitted to the client Simply calling Close( ) causes the remaining results to be pulled to the client to empty the stream Since the DataReader reads a result set stream directly from a connection, there is no way to know the number of records in a DataReader 62 Connections, Connection Strings, and Connection Pooling Database connections are a critical and limited resource Connections must be managed to ensure that an application performs well and is scalable SQL Server and Oracle data providers provide connection pooling while the OLE DB and ODBC providers use the pooling provided by OLE DB or ODBC respectively Connections should be opened as late as possible and closed as soon as possible using either the Close( ) or Dispose( ) method The connection should be used as briefly as possible, meaning that connections should not last longer than a method call Connections should not be passed between methods—in addition to creating performance problems and limiting scalability, this can lead to security vulnerabilities 63 64 ... powerful and cheaper, RTUs, PLCs and DCSs are increasingly beginning to overlap in responsibilities, and many vendors sell RTUs with PLC-like features and vice versa The industry has standardized... design, and expensive to machine and produce Cams are also subject to wear, which directly affects the accuracy and repeatability of the cam follower motion Individual axes were started and stopped... command and operation step In case of deceleration stop by deceleration stop command in deceleration speed section, starts to operate ‘current operation step+1’ again by Start command and

Ngày đăng: 09/09/2021, 06:38

Mục lục

  • History

    • Origin

    • Development

    • PLC compared with other control systems

    • Overview of Motor Types

    • Motor Types

      • AC Motors

        • Advantages

          • Simple Design

          • Low Cost

          • Disadvantages

            • Poor positioning control

            • DC Motors

              • Advantages

                • Easy to understand design

                • Easy to control speed

                • Easy to control torque

                • Simple, cheap drive design

                • Disadvantages

                • How Stepper Motors Work

                  • Open-loop versus closed-loop commutation

                  • Stepper motor drive circuits

                  • Applications

                  • Digital Encoders

                    • Absolute encoder

                    • Systems concepts

                    • Human Machine Interface

                    • Hardware solutions

                      • Remote Terminal Unit (RTU )

                      • Supervisory Station

                        • Operational philosophy

Tài liệu cùng người dùng

  • Đang cập nhật ...

Tài liệu liên quan