Добавил:
Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
(EOD).Mechatronics.pdf
Скачиваний:
82
Добавлен:
23.08.2013
Размер:
5.07 Mб
Скачать

page 136

12. DISCRETE SENSORS

• There are a number of system conditions that need to be detected when doing control. These conditions are most commonly true/false detections, having discrete states.

12.1 INTRODUCTION

There are a few important concepts when connecting to sensors, including,

-The physical phenomena that allows detection

-The actual wiring of the sensors

12.2 SENSOR WIRING

There are a variety of basic methods for connecting sensors to devices. These include,

-Plain Switches - normally open or closed to allow current to flow.

-TTL (Transistor Transistor Logic) - for low voltage logic using 0V and 5V.

-Sinking/Sourcing - DC current is drawn through the sensor.

-Solid State Relays - These are used for switching AC outputs.

12.2.1 Switches

• Plain switched outputs usually accompany relays for outputs, or similar devices.

12.2.2 Transistor Transistor Logic (TTL)

This method switches between two logical DC voltages.

Typically the low voltage is 0V and it indicates a false condition.

The true state is normally indicated with a high voltage. 5V is quite common, but other voltages can be used for certain sensors.

The voltage levels have certain tolerances built in. For example 0V indicates false, but a voltage up to 1.2V might still be considered false. This also means there is an ambiguous zone where the voltage will be judged neither true or false. This zone can be eliminated using schmitt trig-

page 137

gers.

12.2.3 Sinking/Sourcing

These scheme is used for a variety of reasons.

-they can be made to appear like normal switches.

-they can be used to switch low current devices and hence replace controllers for simple applications.

The two types indicate which way the current and voltage are switched to the output. The methods also refer to transistor types because of the similar behavior (Note: in fact they do use transistors inside).

The two main differentiation is,

-Sinking (NPN) - In this case, when actuated, the sensor will connect to ground, or pull the input low. If this is the case you need to use an output that normally stays high, true, floats high, etc. The figure below shows an approximate representation.

page 138

 

 

V+

The sensor responds to the physical

 

V+

phenomenon. If the sensor is

 

 

inactive (nothing detected) then

physical

 

 

 

sensor

the active line is low and the

phenomenon

 

 

transistor is off, this is like an

 

output

 

 

 

 

open switch. That means the

 

 

 

 

 

NPN

NPN output will have no current

 

Sensor

in/out, and hence no voltage.

 

 

 

 

 

When the sensor is active, it will

 

Active Line

 

make the active line high. This

 

 

will turn on the transistor, and

 

 

 

effectively close the switch.

 

 

V-

This will allow current to flow

 

V-

into the sensor to ground (hence

 

 

 

 

 

sinking). The voltage on the

 

 

 

NPN output will be pulled down

 

 

 

to V-. Note: the voltage will

 

 

 

always be 1-2V higher because

 

 

 

of the transistor.

- Sourcing (PNP) - In this case, when actuated, the sensor will connect to V+, or pull the input high. If this is the case you need to use an output that normally stays low, flase, floats low, etc. The figure below shows an approximate representation.

page 139

 

V+

The sensor responds to the physical

V+

phenomenon. If the sensor is

 

inactive (nothing detected) then

physical

 

 

the active line is low and the

phenomenon

 

 

transistor is off, this is like an

Active Line

 

 

open switch. That means the

 

 

 

 

PNP output will have no current

Sensor

 

in/out, and hence no voltage.

 

PNP

When the sensor is active, it will

 

make the active line high. This

 

sensor

will turn on the transistor, and

 

output

effectively close the switch.

 

V-

This will allow current to flow

V-

from V+ through the sensor to

 

 

 

the output (hence sourcing). The

 

 

voltage on the PNP output will

 

 

be pulled up to V+. Note: the

 

 

voltage will always be 1-2V

 

 

lower because of the transistor.

• To directly connect devices to these sensors we can use the arrangement below.

sensor V+

NPN

V-

sensor V+

PNP

V-

V+

power supply

V-

V+

power supply

V-

Note: remember to check the current and voltage ratings for the sensors.

• It is worth stating the obvious - The output of sensors will be the inputs for other devices, such as PLCs - this will lead to confusion when specifying PLC input devices. Some manufacturers

page 140

indicate what the input type is, others specify what it is for. This basic result of this is that you must look at the electrical connections of the card, and not just the designation.

Manufacturer

Sensor Type

Name of Required Card Type(s)

Allen Bradley

NPN

 

 

PNP

 

Aromat

NPN

 

 

PNP

 

• Note, if using these sensors with PLCs, care is required to select the appropriate cards and connections. The figure below is for NPN sensors.

PLC Input Sourcing Card (2 DC inputs)

Electronics Card Internal

PLC Data Bus

+V

current flow

 

 

 

 

+V

 

+V

 

 

power

 

 

NPN

supply

 

NPN

-V

 

sensor

00

-V

 

 

01

Note: When we have a PLC input card that has

 

a V+ (not a common) then we can use NPN

 

sensors. In this case the current will flow

External Electrical

out of the card (sourcing) and we must

switch it to ground.

 

 

 

ASIDE: This card is shown with 2 optocouplers (one for each output). Inside these devices the is an LED and a phototransistor, but no electrical connection. These devices are used to isolate two different electrical systems. In this case they protect the 5V digital levels of the PLC computer from the various external voltages and current.

• The figure below is for PNP sensors. These are generally more common combinations.

page 141

PLC Sinking Input Card (2 DC inputs)

 

+V

 

 

 

00

PNP

 

 

PNP

current flow

 

sensor

Internal

 

 

-V

 

 

 

 

 

Card

01

 

 

 

 

+V

Electronics

 

 

 

 

power

 

 

 

 

 

 

supply

 

 

 

-V

 

com

 

 

 

Note: When we have a PLC input card that has

 

a common then we can use PNP sensors. In

 

this case the current will flow into the card

 

and then out the common to the power sup-

 

ply.

 

 

It is quite common for manufacturers to offer PLC output cards that will handle PNP and NPN sensors. In this case the card will require both V+ and a common connection, and the each output must be set for either NPN or PNP.

Two wire sensors are also common because they reduce the wiring.

page 142

PLC Sinking Input Card

PLC Sourcing Input Card

V+

 

 

+V

 

two wire

00

sensor

 

 

-V

01

 

+V

 

power supply

-V

com

Note: These sensors require a certain leakage current to power the electronics.

V+

00

 

 

 

+V

 

 

 

two wire

 

 

sensor

01

-V

+V

 

 

power

 

 

supply

 

 

-V

com

Соседние файлы в предмете Электротехника