Добавил:
Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
Jack H.Automating manufacturing systems with PLCs.2005.pdf
Скачиваний:
261
Добавлен:
23.08.2013
Размер:
5.34 Mб
Скачать

continuous sensors - 23.42

10.

encoders cost more but can have higher resolutions. Potentiometers have limited ranges of motion

11.

 

FS

 

 

 

 

 

 

BTW

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Rack: 0

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Group: 0

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Module: 0

 

 

 

 

 

 

 

 

 

 

 

BT Array: BT9:0

 

 

 

 

 

 

 

 

 

 

 

Data File: N7:0

 

 

 

 

 

 

 

 

 

 

 

Length: 37

 

 

 

 

 

 

 

 

 

 

 

Continuous: no

 

 

BT9:0/EN

BT9:1/EN

 

 

 

BTR

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Rack: 0

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Group: 0

 

 

 

 

 

 

 

 

 

 

 

Module: 0

 

 

 

 

 

 

 

 

 

 

 

BT Array: BT9:1

 

 

 

 

 

 

 

 

 

 

 

Data File: N7:37

 

 

 

 

 

 

 

 

 

 

 

Length: 20

 

 

 

 

 

 

 

 

 

 

 

Continuous: no

 

 

BT9:1/DN

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

CPT

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Dest F8:0

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Expression

 

 

 

 

 

 

 

 

 

"20.0 * N7:41 / 4095.0 - 10"

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

CPT

 

 

 

 

 

 

 

 

 

 

Dest F8:0

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Expression

 

 

 

 

 

 

 

 

 

 

"300.0 * (F8:0 + 10) / 20"

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

RAD

 

 

 

 

 

 

 

 

 

 

Source F8:0

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Dest F8:1

 

 

 

 

 

 

 

 

 

 

 

 

 

 

23.9 ASSIGNMENT PROBLEMS

1.Write a simple C program to read incremental encoder inputs (A and B) to determine the current position of the encoder. Note: use the quadrature encoding to determine the position of the motor.

continuous sensors - 23.43

2.A high precision potentiometer has an accuracy of +/- 0.1% and can rotate 300degrees and is used as a voltage divider with a of 0V and 5V. The output voltage is being read by an A/D converter with a 0V to 10V input range. How many bits does the A/D converter need to accommodate the accuracy of the potentiometer?

3.The table of position and voltage values below were measured for an inexpensive potentiometer. Write a C subroutine that will accept a voltage value and interpolate the position value.

theta (deg) V

0

0.1

67

0.6

145

1.6

195

2.4

213

3.4

296

4.2

315

5.0