Mechatronics Unit 1 & 4 Notes PDF
Mechatronics Unit 1 & 4 Notes PDF
Mechatronics Unit 1 & 4 Notes PDF
Unit – I
INTRODUCTION TO MECHATRONICS:
m
camera all you need to do is point it at the subject and press the button
to take the picture. The camera automatically adjusts the focus so that
.co
the subject is in focus and automatically adjusts the aperture and
1
systems and is more than just a control system; it is a complete
m
adopted Mechatronics has to involve a concurrent approach to these
.co
disciplines rather than a sequential approach of developing, say, a
microprocessor part.
Definition: tas
“Mechatronics is the synergetic integration of mechanical engineering
lda
with electronics and intelligent computer control in the design and
SYSTEMS:
thought of as a box which has an input, and an output and where we are
w.
not concerned with what goes on inside the box but only the
relationship between the output and the input. Thus for example, a
ww
Example: A Motor.
2
Fig: System
Basically in mechatronics we divide the systems in to 2 types
1. Measurement System.
2. Control System.
MEASUREMENT SYSTEM:
making measurements. It has an input the quantity being measured and its
3
Elements of Measurement system
shown in figure.
m
.co
ta s
1. A sensor which responds to the quantity being measured by giving as
is a temperature sensor.
lda
2. A signal conditioner takes the signal from the sensor and manipulates it
control system, for use to exercise control. Thus for example the output
signal conditioner.
w
a digital readout.
4
CONTROL SYSTEM:
and the pump can be adjusted to supply water through radiators. So the
m
required temperature can be maintained in the house.
.co
ta s
lda
In a system when the output quantity is controlled by varying the input
There are two basic forms of control system one being called and Open
ww
loop and other closed-loop systems. The difference between these can be
5
The room will heat up and reach a temperature which is only
determined by the fact the 1 kW element was switched on, and not the 2
compensate.
The heating system with the heating element could be made a closed loop
means that the input to the switch depends on the deviation of the actual
6
Illustration of a motor:
determined solely by the initial setting of a knob which affects the voltage
result of temperature changes, or the shaft load will change the shaft speed
setting of the control knob will be for a particular shaft speed and this will
In an open-loop control system the output from the system has no effect
on the input signal. In a closed-loop control system the output does have
reliability.
7
However, there are disadvantages like,
More complex
number of components.
1. Comparison element.
2. Control element.
3. Correction element.
4. Process dement
5. Measurement element.
Comparison element
8
The symbol used, in, general, for an element at which signals are
The inputs are all added; hence the feedback input is marked as negative
and the reference signal positive so that the sum gives the difference
Control element
signal.
valve.
The control plan being used by the element may be just to supply a
Correction element
the temperature of the process or a valve which opens and allows more
The term actuator is used for the element of a correction unit that
Process element
with its temperature being controlled or a tank of water with its level
being controlled.
9
Measurement element
temperature.
10
with the set value and an error signal generated. This is then acted on by
the computer to give at its output a signal, which, after suitable signal
initial setting of the lever arm arrangement so that it just cuts off the water
supply at the required level. When water is drawn from the tank the float
moves downwards with the water level. This causes the lever arrangement
to rotate and so allows water to enter the tank. This flow continues until
the ball has risen to such a height that it has moved the lever arrangement
to cut off the water supply. It is closed loop control system with the
elements being:
Controlled variable - the water level in the tank
Reference value - initial setting of the float and lever position
Comparison clement - the lever
Error signal - the difference between the actual and initial
settings of the lever positions
Control unit - the pivoted lever
Correction unit - the flap opening or closing the water supply
Process - the water level in the tank
Measuring device - the floating ball and lever
SEQUENTIAL CONTROLLERS:
When a controller operates in a sequence way i.e. Step by step, then that
11
the control .actions are ordered in time, which is obtained by an electrical
circuit with sets, of relays or cam operated switches which are wired up in
out are,
1. Pre wash cycle -the clothes in the drum are washed with cold water.
2. Main wash cycle - the clothes are washed with hot water.
3. Rinse cycle - the washed clothes are rinsed with cold water number of
times.
12
Visit : www.Civildatas.com
The above figure shows the basic washing machine system and gives
The system that is used for the washing machine controller was a
mechanical switches. Figure below show the basic principle of one such
switch.
The rotation turns the controller cams so that each in turn operates
The contours of the cams and the means by which the program is
specified and stored in the machine. The sequence of instructions and the
of cams chosen.
13
arrangement of cams but by a software program.
current is supplied and switched off when it ceases. This valve allows cold
water into the drum for a period of time determined by the profile of the
cam or the output from the microprocessor used to operate its switch.
will stop the water going into the tank, during the permitted time, when it
A sensor is used to give a signal when the water level has reached the
preset level and give art output front the microprocessor which is used
to switch off the current to the valve. In the case of a cam-controlled valve,
the sensor actuates a switch which closes the valve admitting water to the
For the main wash cycle, the microprocessor gives an output which
starts when lie pre-wash part of the program is completed: in the case
of the cam-operated system the cam has a profile such that it starts in
a circuit to open a valve to allow cold water into the drum. This level is
sensed and the water shut off when tine required level is reached.
water. A temperature sensor is used to switch off the current when the
14
Visit : www.Civildatas.com
the drum. This will continue for the time determined by the microprocessor
switches on the current to a discharge pump to empty the water from the
drum.
signals to open valves which allow cold water into the machine. Switch it
off, operate the motor to rotate the drum, operate a pump to empty the
water from the drum, and repeat this sequence a number of times.
events. This PLC can be easily reprogrammed for different tasks. The PLC is
shown below.
15
Visit : www.Civildatas.com
The example for input devices are switches relays and limit switches. The
examples for output devices are motor to be controlled, Lamp, relay and
solenoid. The controller monitors the inputs and outputs according to the
program stored in the PLC by the operator. PLC are similar to computers but
have certain features which are specific to their use of controllers. These are,
operations.
Note:
micro controller
16
AUTOMATIC CAMERA:
When the switch is operated to activate the system and the camera
input from the range sensor and sends an output to the lens position
drive to move the lens to achieve focusing. The lens position is fed back
modify the lens position according to the inputs from the range sensor.
The light sensor gives an input to the microprocessor which then gives
controlled rather than aperture controlled mode, the time for which the
shutter will be opened. When the photograph has been taken, the
17
The program for the microprocessor is a number of steps
decisions with the input and output signals either being low or high
A few steps of the program for the automatic camera might be of the
form:
begin
if battery check input OK
then continue
otherwise stop
loop
read input from range sensor calculate lens
movement output signal to lens position drive
input data from lens position encoder
compare calculated output with actual output stop output when lens in
correct
position
send in-focus signal to viewfinder display
etc.
18
THE ENGINE MANAGEMENT SYSTEM:
The engine management system of a car is responsible for managing
When the piston moves down a valve opens and the air-fuel mixture is
When the piston moves up again the valve closes and the air-fuel
mixture is compressed.
When the piston is near the top of the cylinder the spark plug ignites the
causes the piston to move back down again and so the cycle is repeated.
19
For ignition timing, the crankshaft drives a distributor which makes
electrical contact for each spark plug in turn and a timing wheel.
pulses are sent to the distributor so they occur at the right moments of
time.
To control the amount of air fuel mixture entering a cylinder during the
intake strokes, the microprocessor varies the time for which a solenoid is
20
Visit : www.Civildatas.com Visit : www.Civildatas.com
MECHATRONICS APPROACH:
The domestic washing machine that used cam operated switches in order
to control the washing cycle is out of date. Such mechanical switches are being
essentially a collection of logic gates and memory elements that are not wired
m
means of software.
.co
example of a mechatronics approach in that a mechanical system has become
camcorders, watches, hi-fi and video recorder systems, central heating controls,
ww
sewing machines, etc.. They are to be found in cars in the active suspension,
21
PART – A –TWO MARK QUESTIONS
1. Write about Mechatronics?
5. What is the function of conditioning and interfacing Circuits and graphical displays?
m
7. What are the important sub-systems involved in Mechatronic system?
.co
9. What are the important elements of measurement system?
16. What are the import elements of a closed loop control system?
PART – B QUESTIONS
26
1. Range and Span:
+ The range of a transducer defines the limits between which the input can vary.
+ The difference between the limits (maximum value - minimum value) is
known as span.
+ For example a load cell is used to measure force. An input force can vary from
20 to 100 N. Then the range of load cell is 20 to 100 N. And the span of load
cell is 80 N (i.e., 100-20)
2. Error:
+ If the transducer is ideally designed and made from appropriate materials
with ideal workmanship, then output will indicate the true value. But in
actual practice the output of the transducer will deviate from the true value.
+ The algebraic difference between the indicated value and the true value of the
measured parameter is termed as the error of the device.
+ Error = Indicated value —true value
+ For example, if the transducer gives a temperature reading of 30° C when
the actual temperature is 29° C, then the error is + 1° C. If the actual
temperature is
3 1° C, then the error is —1° C.
3. Accuracy:
+ Accuracy is the extent to which the value indicated by the
measurement system would be wrong.
+ Accuracy is the summation of all possible errors that are likely to occur.
+ For example, a thermocouple has an accuracy of ± 1° C. This means
that reading given by the thermocouple can be expected to lie within + 1° C (o
r) —
1° C of the true value.
+ Accuracy is also expressed as a percentage of the full range output (or)
full- scale deflection.
+ For example, a thermocouple can be specified as having an accuracy of ±4
% of full range output. Hence if the range of the thermocouple is 0 to 200°
C, then the reading given can be expected to be within + 8° C (or) —8° C of
the true reading.
4. Sensitivity:
+ The sensitivity is the relationship showing how much output we can get per
unit input.
+ ie sensitivity = Output / Input
5. Hysteresis error:
+ When a device is used to measure any parameter plot the graph of output
Vs value of measured quantity.
+ First for increasing values of the measured quantity and then for decreasing
values of the measured quantity.
+ The two output readings obtained usually differ from each other.
27
Visit : www.Civildatas.com
6. Non-linearIty error:
+ A linear relationship is assumed between the input and output and hence,
a straight line is drawn in the graph as shown here.
Fig.1.2
+ In the first method, (fig 1.2), the straight line is drawn by joining the output
values at the end points of the range.
28
+ In the next method, the straight line is drawn by using the method of least
squares to determine the best fit line by considering all data values are in
error. Refer fig (1.3).
+ In the last method, the straight line is drawn by using the method of
least squares to determine the best fit line which passes through the zero
point.
Fig.1.3 Fig.1.4
7. Repeatability/Reproducibility:
+ The repeatability and reproducibility of a transducer are its ability to give the
same output for repeated applications of the same input value.
+ Repeatability is also defined as the measure of the deviation of test
results mean value.
8. Reliability:
+ The reliability of a system is defined as the possibility that it will perform its
assigned functions for a specific period of time under given conditions.
+ The reliability of a device (or) system is affected not only by the choice of
individual parts in system but also by manufacturing methods, quality of
maintenance and the type of user.
9. Stability:
+ The stability of a transducer is its ability to give the same output when used to
measure a constant input over a period of time.
+ The term drift is the change in output that occurs over time.
+ The drift can be expressed as a percentage of the full range.
+ Zero drift means if there is change in output when there is zero input.
10. Dead band / time:
+ There will be no output for certain range of input values. This is known as
dead band. There will be no output until the input has reached a
particular value.
+ The length of time from the application of an input until the output begins to
respond and change is known as Dead time.
29
11. Resolution:
+ Resolution is defined as the smallest increment in the measured value
that can be detected.
+ The resolution is the smallest change in the input value which will
produce an observable change in the input.
+ Resolution is also known as the degree of fineness with which
measurements can be made.
+ For example, if a micrometer with a minimum graduation of 1mm is.
used to measure to the nearest 0.5 mm, then by interpolation, the
resolution is estimated as 0.5 mm.
12. Backlash:
+ Backlash is defined as the maximum distance (or) angle through
which any part of a mechanical system can be moved in one
direction without causing any motion of the attached part.
+ Backlash is an undesirable phenomenon and is important in the
precision design of gear trains.
13. Output Impedance:
+ Before defining impedance, we should know about Ohm’ s law.
+ Ohm’ s law is used to define the relationship between voltage V, Current I
and
Resistance
R.
(i.e.,) V=IR
+ Ohm’ s law can be extended to the AC circuit analysis of resistor,
capacitor and inductor elements as
v=ZI
where Z is called impedance of the elements. So impedance is
similar to resistance.
+ The sensors produce electrical output.
+ When these sensors are interfaced with an electronic circuit, it is
necessary to know the output impedance.
+ This impedance is connected in either series (or) parallel with that
circuit and the inclusion of the sensor will modi1 the behaviour of the
system to which it is connected.
Displacement Sensors:
The measurement of the amount by which some object has been moved.
1. Potentiometer,
2. Resistance strain gauge,
3. LVDT,
4. Push pull displacement sensor.
30
Position Sensors:
+ The determination of the position of some object with reference to
some reference point.
1. Photo electric sensors,
2. H
sensors.
Proximity Sensors:
1. Contact Sensors:
2. Non-contact sensors:
31
1. Potentiometer Sensor
Fig.1.5
Fig.1.6
32
Visit : www.Civildatas.com
Fig.1.7
33
3. Semiconductors strain
gauges.
Fig.1.8
Fig.1.9
34
+ In Metal Wire Strain Gauges a wire stretched between two points
in an insulating medium such as air.
+ The wires may be made of various copper nickel, chrome nickel or nickel
iron alloys. They are about 0.003 mm in diameter and gauge factor of 2.
The length of wire is 25 mm or less.
+ In Metal foil strain gauge the foil is usually made up of constantan, and it
is etched in a grid pattern onto a thin plastic backing material, usually
polyimide. The foil is terminated at both ends with large metallic pads.
+ The size of the entire gauge is very small and has a length of 5 mm to
15 mm length.
+ In Semiconductor strain gauges the p type and n type silicon
semiconductors are used.
+ The semiconductor strain gauges have the gauge factors of about +100 or
—
100. In p-type gauges resistance increases with tensile strain. While in n-
type,
resistance decreases. Typical thickness is about 0.25 mm and
effective length range from 1.25 to 12 mm.
Fig.1.10
Fig.1.11
35
Visit : www.Civildatas.com
Advantages of L VDT:
1. High range
2. Friction and electrical isolation
3. Low hysteresis
4. Power consumption is less.
+ It has three plates with the upper pair forming one capacitor and the
lower pair forming another capacitor.
+ There is a non-linear relationship form between the change in capacitance
AC
and the displacement X.
+ The displacement moves the central plate between the two other plates.
+ The result of this, the central plate moving downwards and to
increase the plate separation of the upper capacitor and decrease the
separation of the lower capacitor.
1. Photoelectric Sensors
+ It is used to detect the object by breaking a beam of light (Refer
Fig.1.12(a)) or radiation falling on a device or by detecting the light
reflected back by the object (Refer Fig.1.12(b)).
Fig.1.12
Fig.1.13
37
Visit : www.Civildatas.com Visit : www.Civildatas.com
Visit : www.Civildatas.com
Fig.1.14
1. Absolute Encoder:
38
Visit : www.Civildatas.com Visit : www.Civildatas.com
Visit : www.Civildatas.com
2. Incremental Encoder:
+ Working: A beam of light passes through the slots in a disc and it is
detected by a suitable light sensor.
+ When the disc is rotated, the output is shown in terms of pulses
and these pulses being proportional to the angle of disc rotation.
39
Fig. 1.17. Incremental
encoder
+ The above Fig. shows the basic form of such sensor and it is used
for the detection of non-magnetic conductive materials.
4. Microswitch:
+ It is used for determining the presence of an item on a conveyor belt
and this might be actuated by the weight of the item on the belt
depressing the belt by a spring loaded platform nearer to the sensor
the presence of item in the conveyor is determined.
+ The closeness of switch is done by movement of this spring loaded
platform.
Fig. 1.20.
Microswitch
5. Reed switch:
+ It is a non-contact proximity switch. It is used for checking the
closure of doors.
41
Visit : www.Civildatas.com Visit : www.Civildatas.com
Visit : www.Civildatas.com
+ When a magnet is brought close to the switch, the magnetic reeds are
attracted each other and close the switch contacts.
To detect and monitor the velocity and motion the following sensors are used.
42
Visit : www.Civildatas.com
3. Tachogenerators:
44
Fig. 2.25. A.C Tachometer
generator
45
4.2 MOTION SENSORS
1. Stroboscope:
+ Stroboscope is a simple portable manually operated device for
periodic or rotary motions measurement.
+ It is a variable frequency flashing light instrument and the flashing is
set by the operator.
+ If a strong light is caused to flash on a moving object at the time
each flash occurs. The stroboscope occupies a given position, and the
object will appear to be stationary.
+ The flashing light whose frequency can be varied and controlled,
and this source is called strobotron.
2 Pyroelectric Sensors:
+ It consists of a polarised pyroelectric crystal with thin metal film
electrodes on opposite faces. (Pyro electric materials, e.g., lithium
tantalate are crystalline materials which generate charge in response to
heat flow. When such materials heated to about 610° C in an electric
field, the electric dipoles within the material line up and it becomes
polarised as shown in Fig.).
+ Due to the crystal is polarised with charged surfaces, the ions are
drawn from the surrounding air and electrons from any measurement
circuit is connected to the sensor to balance the surface charge as
shown in Fig.
+ For measurement of a human or heat source motion, the sensing
element has to differentiate between general background heat radiation
and a moving heat source. For that a single pyroelectric sensor is not
capable to use and dual pyroelectric sensors are used as shown in
Fig.
+ In this dual pyroelectric sensors the sensing element has the one
front electrode and two back electrodes. When two sensors being
connected means both sensors are receive the same heat signal and
their outputs are cancelled.
46
Visit : www.Civildatas.com
47
+ Suppose a heat source moves from its position means the heat radiation
moves from one of the sensing elements to the other, then the current
is alternates in one direction first and then reversed to the other
direction second.
+ A moving human gives an alternating current of 1O A. When the
infrared radiation is incident on the dual pyroelectric sensor material and
changes its temperature, the polarisation in the crystal is reduced. A
focusing device is needed to direct the infrared radiation onto the
sensor.
1. Diaphragms
+ In this the pressure to be measured is applied to the diaphragm, causing
it to deflect, and the deflection being proportional to the applied
pressure. This movement can be monitored by some form of
displacement sensor. (Example for displacement sensor is strain
gauge) and it is shown in Fig.2.27.
48
Fig. 2.28. Diaphragm type strain gauge pressure
transducer
Fig. 2.29.
49
Visit : www.Civildatas.com Visit : www.Civildatas.com
+ The Fig.2.30 shows the bellows can be combined with a LVDT to
give a pressure sensor with an electrical output.
+ The bellows are made up of materials like stainless steel, phosphor
bronze, nickel, rubber and nylon.
+ The output pressure is calibrated through the LVDT.
3. Capsule
Fig. 2.31.
Capsule
5. Tactile Sensor
51
+ It is one form of pressure sensor and it is used to determine the pressure
in
Robotics in such a form fingertips of robotics contact with the
object.
52
+ These type of sensors also used in ‘ touch display screens’ where
physical contacts to be sensed.
+ The above Fig.2.33 shows the one form of tactile sensor.
+ It uses piezo electric polyvinylidene fluoride (PVDF) film.
+ There are two layers of such film is used and it is separated by a
soft film which transmits vibrations.
+ The alternating voltage is supplied in the lower PVDF film and this
results in mechanical oscillations of the film.
+ The intermediate film transmits these vibrations to the upper PVDF film.
+ Due to the piezoelectric effect the vibrations formed are cause an
alternating voltage to be produced across the upper film.
+ So the pressure is applied to the upper PVDF film and its vibrations
are
affected the output voltage.
6. Piezoelectric sensor
Fig.
2.35.
2. Orifice Plate
+ It is a simple disc with a central hole and it is placed in the tube through
which the fluid flow.
54
1. Differential Pressure Sensor
+ In this the differential pressure cell determines the pressure difference
between base of the liquid and atmospheric pressure.
+ The differential pressure sensor can be used in either form of open or
closed vessel system.
Fig.
2.37.
2. Float System
+ In this method the level of liquid is measured by movement of a float.
+ The movement of float rotates the arm and slider will move across
a potentiometer.
+ The output result is related to the height of the liquid.
Fig.
2.38.
55
+
Fig. 2.39.
Thermocouple
57
+ Here to maintain the 0° C at one junction a compensation circuit is
Used to provide an e.m.f. which varies with the temperature of the cold
junction.
+ When it is added to the thermocouple e.m.f. it will generate a combined
e.m.f.
This is shown in Fig.2.42.
+ In the above Fig.2.42, the wires from the measuring junction are
screwed directly to an isothermal block terminal strip.
+ The temperature of the block is ambient temperature.
+ This reference temperature is measured by semiconductor
sensor and compensation circuitry develops a voltage Ecomp which
is combined with measuring junction and the net voltage across the
voltmeter = T (Temperature being measured).
+ The isothermal block can accept many thermocouple pairs in
multichannel instruments with microprocessor computing power
since the T (reference junction sensor now sends its temperature
data to the computer which computes the needed voltage correction
for each thermocouple.
+ The thermocouples like E, J, K and T are relatively cheap and it has
accuracies
of about ± ito 3%.
+ The noble metal thermocouples are very high cost compared with this
and it has accuracies of about ±1% better than the base metal
thermocouples.
+ Thermocouples are used in applications ranging from measurement
of room air temperature to that of a liquid metal bath. The problems
which may be encountered are
1. Faulty reference junction,
2. Installation faults,
3. Junctions formed by users may involve excessive temperatures
or faulty soldering techniques,
4. Gross errors can result due to wrong installation of thermocouple.
2. Resistance Temperature Detectors (RTDs)
+
Fig. 2.43. Resistance temperature
detector
Fig. 2.45.
60
Salient Features ofRTDs:
1. High degree of accuracy.
2. Resistance thermometer is interchangeable in a process without
compensation or recalibration.
3. It is normally designed for fast response as well as accuracy to
provide close control of processes.
3. Thermistors
+ Thermistor is a semiconductor device that has a negative
temperature coefficient of resistance in contrast to positive coefficient
displayed by most metals.
+ Thermistors are small pieces of material made from mixtures of metal
oxides,
such as Iron, cobalt, chromium, Nickel, and Manganese.
+ The shape of the materials is in terms of discs, beads and rods.
+ The thermistor is an extremely sensitive device because its resistance
changes rapidly with temperature.
+ The resistance of conventional metal-oxide thermistors decreases in
a very non-linear manner with an increase in temperature is shown in
the Fig.2.46 below.
+ The change in resistance per degree change in temperature is
considerably
larger than that which occurs with metals.
Fig. 2.46.
Thermistors
Fig. 2.47.
Thermistor
(a) Thermodiodes:
+ Thermodiode is widely used method for measuring temperature.
When the temperature of doped semiconductors changes, the
mobility of their charge carriers changes and this affects the rate at
which electrons and holes can diffuse across ap-n junction.
1. Measurement of temperature,
2. Control of temperature,
3. Temperature compensation,
4. Measurement of thermal conductivity,
5. Measurement of power at high frequencies,
6. Measurement of composition of gases,
7. Providing time delay,
8. Vacuum measurements.
Fig. 2.48.
Transistor
62
5. Bimetallic
strips
Fig.
2.50.
63
+ If the diode is sufficiently reverse biased, it will breakdown.
+ The current passing through the diode when forward biased only.
+ If an A.C. voltage is applied across a diode, it can be regarded
as only switching on when forward bias it and being off in the reverse
direction.
+ The photodiodes have a very fast response to light and it can be
used as a variable resistance device controlled by the light incident on
it.
2. Photo Transistors
Fig.
2.51.
+ The main current flows in at the collector and out at the emitter
in npn transistor.
+ The main current flowing in at the emitter and out at the collector in
pnp
transistor
.
+ The phototransistors have a light sensitive collector-base p-n junction.
+ There is a very small collector to emitter current when there is no
incident light. Suppose the light is incident a base current is produced
and it is proportional to the light intensity.
+ So this will produce a collector current and it is used for measure of the
light
intensity.
+ The example for photo transistors is photo Darlington arrangement.
66
8.0 SELECTION OF SENSORS
PART- A
67
24. What is a
comparator?
25. Name an application of a Schmitt trigger.
26. Why integrators are preferred over differentiators in analog
computers?
27. What is a voltage follower?
28. What is the advantage of CMOS Schmitt trigger?
PART-B
1. Explain the terminologies used in transducers.
2. What are all the displacement sensors? Explain each one briefly.
3. Explain the position sensors with neat figure.
4. Define proximity and explain the proximity sensors.
5. What are all the velocity and Motion sensors?
6. How the pressure is measured? Explain the pressure sensors neatly.
7. Explain the temperature measurement sensors.
8. Explain the light sensors with neat figure.
9. What are all the points to be considered while selecting the sensors?
10. Explain the signal processing.
11. Explain some applications of operational amplifier.
12. Explain the operation of successive approximation ADC.
13. How do a dual slope ADC and single slope ADC differ?
14. What is Flash ADC ? Discuss.
15. Explain the construction of R-DR ladder DAC.
16. Discuss the various terms associated with ADC.
68
MECHATRONICS (UNIT – IV)
1
Visit : www.Civildatas.com
After a program has been developed in RAM, it may be loaded into an EPROM
memory chip and so made permanent. The I/0 unit provides the interface between the
system and the outside world. Programs are entered into the system through input
devices like key pad or sometimes through Personal Computer (PC) which is loaded
with an appropriate software package. The I/0 channels have signal conditioning and
isolation units, so that sensors and actuators can be generally directly connected to
them without the need for any other circuitry. The figure shows the basic form of an
input channel. Common input voltages are 5V and 24VCommon output voltages are
24V and 240V.
2
Visit : www.Civildatas.com
There are three types of output
1) Relay type.
2) Transistor type.
3) Triac type
1) Relay Type
With relay type, the signal from the PLC output is used to operate a relay and so is
able to switch currents of the order of few amperes in an external circuit. The relay
isolates the PLC from the external circuit and can be used for both d.c and a.c
switching Relays are relatively slow to operate.
2) Transistor type
The transistor type of output (fig) uses a transistor to switch current through the
external circuit. This provides a faster switching action. Opto isolators are used with
transistor switches to provide isolation between the external circuit and the PLC. The
transistor output is only for D.C. switching.
3) Triac type:
Triac outputs can be used to control external loads which are connected to the a.c.
power supply. Opto isolators are again used to provide isolation.
3
INPUT / OUTPUT PROCESSING
The programming commonly used with PLC is ladder programming. This involves
each program task being specified as through a rung of a ladder. This each rung
could be specify that the state of switches A&B.The inputs, be examined and if A&B
are both closed then a solenoid, the output is energized. The sequence followed by a
PLC when carrying out a program can be as follows
1. Scan the inputs associated with one rung of the ladder program.
2. Solve the logic operation involving those inputs.
3. Set/reset the output for that rung.
4. Move on the next rung and repeat the operations 1, 2, 3.
Thus a PLC is continuously running through its program and updating it as a result of
input signal. Each such loop is termed as cycle. This continues until the program is
competed.
There are two methods that can be used for I/0 processing:
1. Continuous updating
In this method, the CPU scans input channels as they occurring the program
instructions. Each input is examined individually and its effect on the program
determined. there involves a time delay, typically about 3 ms, when each input is
scanned in order to ensure that only valid input signals are read by the
microprocessor.
This delay enable CPU to avoid counting an input signal twice, A number of inputs
may have to be scanned, each with a 3 ms delay, before the program has the
instruction for a logic operation to be executed and an output to occur. The outputs
are latched so that they retain their status until the next update. The 3 ms built-in
delay for each input is, for ensuring the signals read by the CPU is the valid one. or
more frequently, if there is contact bounce at a switch.
2. Mass I/0 Copying
In the above method, with 3 ms delay on each input, the time taken to examine
several hundred I/0 points can become comparatively long. To allow a more rapid
execution of a program, a specific area of RAM is used as a buffer store between the
control logic and I/0 units. Each I/0 have and address in this memory. At the start of
each program is executed the stored input data is read, as required, from RAM and
the logic operations carried out. The resulting output signals are stored in the
4
Visit : www.Civildatas.com
reserved I/0 section RAM. At the end of each program cycle, all the outputs are
transferred from RAM to the output channels. The outputs are latched so that they
retain their status until the next update.
PROGRAMMING
Ladder diagram
PLC’s are programmed using ladder diagram techniques. A special standard
schematic representation of the physical components arrangement (hardware) and its
way of connections made between them is called as ladder diagram. These are line
diagram the represent both the system hardware and the process controller.
A ladder diagram consists of two vertical lines called power power rails are connected
along with I/O devices and other components as horizontal lines between the two
vertical lines known as rungs.
Rules followed in ladder diagram
1. The vertical lines of the diagram represent the power rails, and the horizontal lines
representing the rungs.
2. Each rung on the ladder defines one operation in the control process.
3. A ladder diagram must read from left to right and from top to bottom. when the
scanning of first rung is completed then the second rung starts from left to right.
4. Each rung must start with an input and must end with an output.
5. Each rung must have more than one input but only one output.
6. The input must always located at the rung left and the output at the right end of the
rung.
7. Electrical devices are shown in their normal condition.
Ladder diagram can be entering from a monitor screen by using mouse. When
entered, they translated by the PLC into machine language for microprocessor to
understand it. The nature of input determines whether the output is to be energized or
not.
The Ladder programming is one of the basic forms of programming commonly used
with PLC’s. In this type of programming, each program task being specified as though
a rung of ladder. Circuits are connected between these two vertical lines as horizontal
lines, i.e. the rungs of the ladder. Fig. shows the basic symbols that are used in the
ladder diagram.
5
Ladder Symbols
Precede outputs and depending on, the different PLC manufacturer, different
notations are used. For example, the Mitsubishi F series of PLC’s precedes inputs
elements by an X and output elements by a Y and uses the following numbers:
Numbering schemes are followed for inputs and outputs and depending on, the
different PLC manufacturer, different notations are used. For example, the Mitsubishi
F series of PLC’s precedes inputs elements by an X and output elements by a Y and
uses the following numbers:
Inputs X300 - 307,310 - 313
X600 - 607,610 - 61 3
(24 possible inputs)
Outputs Y330-337
Y 430 - 437
(1 6 possible outputs)
To illustrate the drawing of a ladder diagram, consider a situation where the output
from the PLC is to energies a solenoid when a normally open start switch connected
to the input is activated by being closed (Fig. (a)). the program required is shown in
Fig. (b).
6
Starting with the input, we have the normally open symbol 11. This might have an
input addressX400. The line terminates with the output, the solenoid, with the symbol
0. This might have the output address Y430. To indicate the end of the program the
end rung is marked. When the switch is closed the solenoid is activated. This might,
for example, be a solenoid valve which opens to allow water to enter a vessel.
LOGIC FUNCTIONS
Logic functions may be obtained through various combinations of switches. Also it is
explained how one can write ladder program using such combinations.
1. And function
Only when both the switches are closed simultaneously, the lamp will be lit, otherwise
it is put off. Thus, this situation corresponds to an AND logic function. The ladder
diagram representing the AND function is shown in Fig.(b). The switches A and B are
represented as input 1 and input 2 and lamp is represented as an output.
2. OR function
Consider a situation shown in Fig.
7
If either one of the switch A or B is closed, then the lamp will be lit. If both switches
are opened simultaneously, then lamp will be put off. This situation Corresponds to an
OR system. The ladder diagram representing the OR function is shown in fig.(b) The
switches A and B are represented as output.
3. Nor function
Consider a situation show in Fig. (a)
When neither A nor B have an input (i.e., neither switch A nor switch B is opened) the
lamp will be lit. When there is input to A or B (i.e., if switch A or B is opened) the lamp
will be put off. This situation corresponds to a NOR system. The ladder diagram
representing NOR function is shown in Fig. (b) Switch A and B are represented as
input 1 and input 2; and lamp is represented as output. In this case the switches A
and B are normally closed. When input occurs, the corresponding switch is opened.
There will be output if neither of the input occurs. There will not be output if any of the
input occurs.
4. NAND Function
Consider a situation show in Fig. (a)
8
The lamp will not be lit, when both A and B have input simultaneously (i.e., when both
are opened simultaneously the lamp will be lit if both inputs did not occur
simultaneously (i.e., when both are not opened simultaneously). The ladder diagram
is shown in Fig. (b)
5. EXCLUSIVE-OR (XOR) function
Consider a situation shown in Fig. (a) In this system, there will be output (i.e., the
lamp will be lit) if any one of the input occurs. There will not be output if both inputs
occur or if both do not occur. The ladder diagram is shown in Fig (b) Note that, it is
represented, each input by two sets of contacts, one normally open and one normally
closed.
LATCHING
There are often situation where it is necessary to hold a coil energized, even when
the input which energized it ceases. The term latch circuit is used for the circuit used
to carry out such and operation. It is a self-maintaining circuit in that, after being
energized, it maintains that state until another input is received. It remembers its last
state.
An example of a latch circuit is shown in Fig (a) when input 1 is energized and closes,
there is an output. However, when there is an output, a set of contacts associated
with the output is energized and closes. These contact OR the input 1 contacts. Thus,
even if input 1 contact open, the circuit will still maintain the output energized. The
only way to release the output is by operating the normally closed contact input 2.As
an example of the use of a latching circuit, consider the requirement for a PLC to
9
control a motor so that when the start signal button is momentarily pressed the motor
starts and when the stop switch is used the motor switches off, signal lamps
indicating when the motor is off and when on. Figure B shows a possible program.
With no inputs, the signal lamp for the motor indicates that it is off.
The motor contacts which are normally closed have the off lamp on. When the start
button is pressed, the normally open contacts are closed and the motor switched on.
This is latched on by the motors contact in parallel with the start contacts. Also, other
motor contacts which are normally closed opens and the off lamp goes off and motor
contacts which are normally open closes and the on lamp goes on. The motor is
stopped by the stop switch which opens the previously closed contacts.
SEQUENCING
There are often control situations where sequences of outputs are required, with the
switch from one output to another being controlled by sensors.
10
Consider the requirement for a ladder program for a pneumatic system (Fig) with
double solenoid valves controlling two double-acting cylinders A and B if limit
switches a-, a+, b-, b+ are used to detect the limits of the piston rod movements in the
cylinders and the cylinder activation sequence A+, B+, A-, B- is required.
Fig. shows a possible program. A start switch input has been included in the first
rung. Thus cylinder extension for A, i.e., the solenoid A+ energized, only occurs when
the start switch is closed and the b- switch is closed, this switch indicating that the B
cylinder is retracted. When cylinder A is extended, the switch a+, which indicates the
extension of A, is activated. This then leads to an output to solenoid B+ which results
in B extending. This closes the switch indicating the extension of B, i.e. the b+ switch,
and leads to the output to solenoid A-. and the retraction of cylinder A.
This retraction closes limit switch a- and so gives the output to solenoid B- which
results in B retracting. This concludes the program cycle and leads to the first rung
again, which await the closure of the start switch before being repeated.
MNEMONICS
Each horizontal rug on the ladder in a ladder program represents a line in the
program and the entire ladder gives the complete program in 'ladder language'. The
programmer can enter the program into the PLC using a keyboard with the graphic
symbols for the ladder elements, or using a computer screen and a mouse to select
11
symbols, and the program panel or computer then translates these symbols into
machine language that can be stored in the PLC memory.
There is an alternative way of entering a program and that is to translate the ladder
program into mnemonics, each code corresponding to a ladder element, and then
enter these into the programming panel or computer. These are then translated into
machine language. The mnemonics used by different PLC manufacturers differ. For
the Mitsubishi F series PLCs, mnemonics use are:
LD -Start a rung with an open contact
OUT -An output
AND -A series element and so an AND logic instruction
OR -Parallel elements and so an OR logic instruction
I -A NOT logic instruction
.... I -Used in conjunction with other instructions to indicate the
inverse
OR1 -An OR NOT logic function
AN1 -An AND NOT logic function
LDI - Start a rung with a closed contact
ANB -AND used with two sub circuits
ORB -OR used with two sub circuits
RST -Reset shift register/counter
SHF -Shift
K - Insert a constant
END -End ladder
The following examples show how individual rungs on a ladder are entered.
The AND gate shown in Fig. would be entered as :
An AND System
12
An OR System
An NAND System
An NOR System
An XOR System
13
TIMERS
When timer circuits are activated, they result in closing or opening of input contacts
after some preset time. Fig. shows part of a program involving a delay-on timer.
When input occurs, the timer is activated, and after some preset time, the contacts
associated with timers close and output occurs. When we want to introduce larger
time delays, it may not be possible with one timer circuit, hence we may cascade
more timers as shown in Fig.
When input contacts close, timer 1 is activated; after its time delay, its contacts close
and timer 2 is activated; after its time delay, its contacts close and output occurs.
14
Normally PLC’s are provided with delay-on timer. The diagram shown in Fig.
Explains how a delay-off timer can be devised. When the input contacts are
momentarily closed, the output is energized and the timer is activated. The outputs
contacts and latch the input and keep the output on. After the reset time of the timer,
the timer contact breaks the latch circuits and hence the output is put off.
INTERNAL RELAYS
The terms internal relay, auxiliary relay and marker is considered as internal relay in
the PLC. In reality they are not Relays. How ever they are simulated by the software
within the PLC. They are useful in implementing switching sequences. Internal relays
are used in a situation where occurrence of output depends on two different input
arrangements. Fig. shows the ladder diagram for such an arrangement. In the
diagram, first rung shows one input arrangement used to control the internal relay
IR1. The second rung shows the other input arrangement used to control the internal
15
relay IR2. The contacts of the two relays are to control the output. Another use of
internal relays is for the starting of multiple outputs.
Fig. shows the ladder diagram. When start contacts are closed, the internal relay is
activated and latches the input. It also starts output 1 and makes it possible for
outputs2 and 3 to be activated.
Another example of use of internal relay is resetting a latch. Fig. shows the ladder
diagram. When the input 1 is momentarily pressed, the output occurs. Then the
output is latched. The output can be unlatched by opening the internal relay contact.
This can happen by the close of input 2 contacts.
16
COUNTERS
As the name implies, counters are used for counting operations. It is an in-built
operation in any PLC. For example, in a packaging section of an industry, assume
that the finished products are passing along a conveyor into boxes. The counters can
be used to count how many products have passed into one box, so that the next box
can be replaced after a particular count.
Two types of counters are possible, namely, up-counter and down-counter. In the
down counter the counter counts down a preset value to zero, whereas in the up
counter the counter starts from zero and count up to a preset value. In both the
cases, as tie counter operation comes to an end, its 'contact' changes state, i.e., it
may close or open.
17
Visit : www.Civildatas.com
The counter is basically represented by a rectangle spanning two lines. (Refer fig.)
One line is used to reset the counter. The other line is used as 'OUT' line and the
symbol K10indicates that the counter contact will change state on the 10th count.
When the input 1 closes momentarily, the counter is reset to the set value, in this
case '10'. Now the counter starts counting as the input 2 closes and opens. When the
input 2closes and opens for 10 times, then the counter contact close and the output is
switched on. In case, before 10 pulses are received from input 2, if input 1
momentarily closes, then the counter will reset back to 10.
Example: Draw a ladder diagram to direct 6 items along path 1 for packaging in a box
and then 12 items along path 2for packaging in another box.
Two counters are used. One counter is used to count six and another to count twelve.
When input 1 momentarily closes, both counters are reset and preset to their
respective counts 6and 12. As items pass up to to the junction in the paths, input
18
2contacts can be made to close and open. After 6 items pass into one box, counter 1
contact closes and activates the output which in turn closes one path and opens
another. Counter 1also has contacts which close and enables counter 2 to start
counting. When counter 2 has counted 12 items it resets both counters and opens
counter 1 contacts which deactivates the output and the items will start falling into 6
items box.
SHIFT REGISTERS:
A number of internal relays can be grouped together to forma register which can
provide a storage area for a series of sequence of individual bits.
Registers are used to store a bit sequence, for example a4-bit sequence 1101 can be
stored using 4 internal registers. Similarly an eight-bit sequence can be stored using
eight internal registers. A number of internal relays can be grouped together to form a
register array.
In shift registers the bits are shifted along the register array by one bit when there is a
suitable input fed to the register. Consider a 4 bit shift register with its bit sequence as
Assume. a 0 is fet to this shift register, then the bits are shifted along the register by
one bit and the last bit overflows:
When the 'shift register' function is selected at the control panel of a PLC, then a
number of auxiliary registers are automatically grouped together to form a shift
register. In Mitsubishi PLC a programming function 'SFT' is to be used against the
auxiliary relay number, which is the first in the register array. For example if it is a 4-
bitregister to be formed, and if we select M 140 to be the first relay number then
automatically, the 4consecutive relays fromM140 will be assigned to form a 4-bit shift
register, ie M140, MI41, MI42 andMI43. A shift register has three inputs, namely OUT
SFT1 and RST. OUT is used to load data into the first element of the shift register.
SFT in used to shift the bits by one bit and RST (Reset) in used to clear all the bits of
the shift register to 0.
19
MASTER AND JUMP CONTROLS:
Master Relay:
More than one output or a block outputs arranged in each output rung can be
simultaneously turn off or on by using one internal relay contact. If this single relay
contact is switched on or off, then it affects every one of the rungs. When the contact
input 1 close then master relay MC1 is activated and simultaneously the block
m
program rungs controlled by the relay MC1 follows. In the ladder shown, OUTI, OUT2
& OUT3 also simultaneously activated. The end of master relay controller section is
indicated by the reset MCR.
.c o
When contact input 2 close then master relay MC2 is activated and simultaneously
the block program rungs controlled by the relay MC2 follows. If there are no inputs to
input 1 &2, then the next input to be checked is for input 9 whose controlled output is
OUT 6. Therefore this branching program operates as -there is input I, then branch to
tas
follow MC1 controlled path, input 2, then branch to follow MC2 controlled path,
otherwise neither input occurs follow the rest of the program & ignore the branches.
In a Mitsubishi PLC, an internal relay can be assigned as a master control relay by
lda
programming it. The instruction MCMI00 is used to program as internal relay MI00 as
master control relay. To indicate the end of master relay controlled section, the
instruction MCR MI00 is used.
ivi
Jumps
20
Visit : www.Civildatas.com Visit : www.Civildatas.com
Visit : www.Civildatas.com
m
.c o
DATA HANDLING: tas
In some cases, it may be required to deal with related group of bits, i.e. a block of
eight inputs and operate on them as data word. The operations that may be carried
lda
out with a PLC on data words normally include.
1. Data movement
2. Data comparison
3. Arithmetic operations
ivi
locations allocate for data storage are called data registers. Each data register can
store either 8 bits or 16 bits & its address may be specified as DO, Dl, D2 etc. Every
instruction has three parts-one specify the source data register, second to specify the
w
destination data register and third to specify the 'operation' to be performed on the
data.
ww
Data movement
Data movement instruction has move instruction, source address of the data and
destination address of the data. For example, to move from Dl to D2,
21
Visit : www.Civildatas.com
m
Data Comparison:
Data comparisons include less than (<or LES), equal to (=orEQU), less than or equal
to (or LEQ), greater than (> or GRT), greater than or equal to ( or GEQ) and not
.c o
equal to (# or <> or NEQ)
tas
lda
For example to compare the data available in Dl & D2, the ladder program rung would
be of the form shown in fig.
Example: Draw a ladder diagram that the alarm keeps sounding when the sensor
temperature is above 80°C and stops sounding when the temperature falls below
ivi
70°C.
The sensor temperature is fed as input data to the source address. The destination
address has the set value, here it80°C. When the input temperature rises to 80°C or
above, the source data becomes greater than or equal to destination data and output
.C
alarm sound which in turn is latched in the input. When the temperature falls to 70°C
or lower, the source data is less than or equal to destination data (shown in second
w
rung of the ladder) and IR output occurs. Now in the first line (the ladder, the IR
contact opens and alarm is switched off.
ww
22
Arithmetic Operations:
Addition and subtraction operations are commonly found in all PLCs. Even more
arithmetic operations are possible in some PLCs. ADDISUB instruction contains
address of the addend, augend and the result registers along with the arithmetic
operation to be performed. These operations may be used to change the preset
m
values of the timers or counters.
.c o
Code Conversions:
tas
In a PLC, all the internal operations are carried out in binary form only. However, it
lda
may be required to handle decimal or octal numbers at the input or output in which
case a conversion from binary to decimal to octal or a conversion from decimal/octal
to binary is required. For example to convert a BCD number in the source register to
a binary number and store the result in destination register, refer the fig.
ivi
.C
ANALOG INPUT/OUTPUT:
w
In PLCs, analog signals might be given as inputs and the actuators at the output
might also require analogue signals. in such cases, an analog-to-digital converters &
ww
digital-to-analog converters may be used at the input & output channel respectively.
Example 1 : Draw a ladder diagram to show the speed of motor increasing at a
steady rate from zero to its maximum value :
23
Visit : www.Civildatas.com
An on/off switch is used at the input. When the switch is in OFF position, the data
register has 'OO', as its contents and hence DAC output is zero & so the motor is at
zero speed. But as the switch closes, the data register is incremented. As the
program loops through theses two rungs of the ladder, the data register keeps
incrementing by one, &the DAC output increases steadily and hence the motor
speeds up at a steady rate. The motor reaches its full speed when the data register
contents has the word 11111111.
SELECTION OF A PLC:
24