Precision Digital Controller using PSoC CY8C26443

Precision Digital Controller using PSoC CY8C26443-24PI Microcontroller
Abstract
The specific objective of this project is to design a precision digital controller for fully automatic
microcontroller controlled reaction vessels for use in development and manufacture of fine
chemicals and bio-engineering products, drugs and their intermediates with a high mass transfer
efficiency. Such applications impose stringent requirements on temperature maintenance, pH
maintenance, foaming, and oxygen content over extended periods of time even exceeding 48
hours. Such a facility would help research labs and pharmaceuticals to define application specific
control formats for multi loop and cascade control configurations.
Presently the analog version of the controller is available. This analog version has to be converted
into digital controller without altering the existing system. Also the system cost should be less
and give higher performance compared to the analog controller. The current project is being
implemented on the existing system in digital form.
The heart of the system is the microcontroller CY8C26443-24PI from Cypress Microsystems.
The manufacturer provides us with a microcontroller that can be configured according to our
application. In the microcontroller, we use the ADC, PWM, PGA and Timer blocks configured
according to our application. The application uses 4 analog signals which are provided to the 4
pins of port 0, through which the analog signals are fed to a multiplexer which selects the input
channel and in-turn feeds 8 bit ADC through a Programmable Gain Amplifier (PGA). There are 4
8-bit PWMs that are used to control the motors to control the flow of different parameters such as
acid, alkali, antifoam and oxygen. Other 4 pins of port 0 are configured as PWM outputs. A LCD
panel is connected to Port 1 to display the values of different parameters dynamically. A 4-bit
data bus configuration is used to control the LCD. Port 2 is used to control different motors and
heaters, these are controlled by on-off mechanism. Also an audio buzzer is connected to port 2 for
any warnings on over range in some parameters. A timer module in the device is utilized to
countdown on time. The motors are driven using MOSFETs for achieve more power efficiency.
The sensors for the different parameters come along with the signal conditioners, which provide
outputs of 0-5V or 4-20mA drive. The outputs from the sensor signal conditioners are directly
given to the ADC inputs of the microcontroller.
The power supply section consists of two transformers, one to supply 5V at 1A to the digital
system after regulation and the other to supply 12V at 4A for the motors.
In the present project only the automatic mode is used where the keyboard input is not taken for
providing limit (Upper and Lower) values for different parameters. This feature will be added in
the future upgrade of the project.
The block diagram of the Precision Digital Controller is shown in Fig 1.
PSoC Design Challenge-2002, Project Id - 179
[+] Feedback
Sensors and Signal
Conditioners
4
P0
P1
6
LCD
16x4
4
Keyboard
2x2
1
Buzzer
for Alarm
Microcontroller
CY8C26443-24PI
7
Motor
Drivers
P0
+5 V Power
Supply
P2
2
P2
2
Crystal
32.768 KHz
Fig 1. Block Diagram of Precision Digital Controller
PSoC Design Challenge-2002, Project Id - 179
[+] Feedback
2 20 V A C I n pu t
J6
2
1
S2
Power Supply for
Microcontroller and LCD
M ain s S wit c h
F1
U3
2A
T1
-
+
+
GND
1
D1
IN
C4
L M7 8 05
J7
2
C5
3
OUT
C6
4 70 0 uF 25 V
1
- 2
0.1uF
0.1uF
9V 1A
+
V C C =5 V
4 00 V 1 A B ridg e
U4
1
4A
D2
IN
T2
+
+ C7
1 2V 4A
4 00 V 4 A B ridg e
L T1 0 83
R5
1K5
OUT
2
J8
3
-
AD J
F2
+
R6
3 00 E
+C8
1
- 2
+C9
1 2V
0 . 1 u F Ta nt
4 70 0 uF 25 V
0 . 1 u F Ta nt
D3
+ C 10
R7
R ED LED
0 . 1 u F Ta nt
2.7K
Power Supply for Motors
Tit le
P re c is io n D igit a l C o nt rolle r - P owe r S up p ly
S ize
A
D at e :
D oc u m e nt N u m be r
1
S un d ay , J u ne 0 2, 2 00 2
R ev
1
S he e t
2
of
3
PSoC Design Challenge-2002, Project Id - 179
[+] Feedback
Precision Digital Controller
VCC5
J1
+
1
2
-
VCC=5V
VCC5
C1
Microcontroller Section
0.1uF
LCD Section
VCC5
Motor 5
Motor 6
Motor 7
Buzzer
Analog In
B1
-
20
8
21
7
22
6
23
5
1
2
Buzzer
+
3
4
Buzzer
R2
4K7
5V DC Buzzer
R3
13
15
4K7
P0[0]
P0[2]
P0[4]
P0[6]
P2[0]
P2[1]
P2[2]
P2[3]
P2[4]/External Ag nd
P2[5]
P2[6]/Ext ernal Vref
P2[7]
32.768 KHz
12pF
4
3
J4
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
12
17
11
18
10
U1
1
3
2
J2
4
5
6
7
8
9
10
11
12
13
14
15
LCD
LCD
VSS
CON
VDD
RS
R/W
E
D0
D1
D2
D3
D4
D5
D6
D7
Vled
LCD 16x4
VCC5
J5
19
4
C2
10K
Xres
2
CY 8C26443-24PI
14
3
2
1
P1[2]
P1[3]
P1[4]
P1[5]
P1[6]
P1[7]
VSS
Keyboard 2x2
1
A B
C D
P0[1]
P0[3]
P0[5]
P0[7]
R1
P1[1]/Crysin/SCLK
P1[0]/Crysout/SDAT A
Y1
K1
VCC
1
2
3
4
5
Analog Input from
Si gnal Condi tioners
SMP
24
25
26
27
28
J3
9
U2
Motor 4
Motor 3
Motor 2
Motor 1
4
3
2
1
C3
S1
Reset
12pF
R4
470E
Motor 1
Motor 2
Motor 3
Motor 4
Motor 5
Motor 6
Motor 7
1
2
3
4
5
6
7
8
Motor
T itle
Precision Digit al Cont roller - Microcontroller
Size
B
Date:
Docum ent Num ber
1
Saturday, May 25, 2002
Rev
1
Sheet
1 of
3
PSoC Design Challenge-2002, Project Id - 179
[+] Feedback
J9
J 10
- Mot or 3
+
- Mot or 4
+
+
C 11
-
12V
0.1uF /50V
D4
C 12
1N 4007
0.1uF /50V
D5
C 13
0.1uF /50V
1N 4007
Q1
IR F 840
J 14
J 15
Mot or
Mot or
R8
D7
1N 4007
Q2
IR F 840
C 15
0.1uF /50V
1N 4007
Q3
IR F 840
Q4
IR F 840
560E
R 10 560E
R 9 560E
R 11 560E
R 12 560E
R 13 560E
R 14 560E
J 16
J 17
+
D8
1N 4007
J 18
- Mot or 5
C 16
0.1uF /50V
Q5
IR F 840
+
D9
1N 4007
2
1
1
2
3
4
5
6
7
8
C 14
0.1uF /50V
2
1
1
2
3
4
5
6
7
8
D6
2
1
Mot or 1
Mot or 2
Mot or 3
Mot or 4
Mot or 5
Mot or 6
Mot or 7
2
1
- Mot or 2
+
J 12
2
1
1
2
2
1
2
1
- Mot or 1
+
J 13
J 11
- Mot or 6
C 17
0.1uF /50V
+
D 10
1N 4007
Q6
IR F 840
- Mot or 7
C 18
0.1uF /50V
Q7
IR F 840
Tit le
P re s io n D ig it a l C o n t ro lle r - M o t o r C o n t ro lle r
S ize
A
D at e:
D oc um ent N um ber
1
S a t u rd a y , M a y 2 5 , 2 0 0 2
R ev
1
S heet
3
of
3
PSoC Design Challenge-2002, Project Id - 179
[+] Feedback
PSoC Design Challenge-2002, Project Id - 179
[+] Feedback
PSoC Design Challenge-2002, Project Id - 179
[+] Feedback
PSoC Design Challenge-2002, Project Id - 179
[+] Feedback