Transcript PIC Theory
Technology
Applied Control Systems
1
Applied Control Systems
Pin configuration
2
Applied Control Systems
Connection of variable resistor / potentiometer
Analogue pin connections
Input 0 – Pin 17
Input 1 – Pin 18
Input 2 – Pin 1
3
4
Applied Control Systems
Analogue to Digital conversion
PICAXE 18X: Internal 8 bit analogue to digital converter (28 = 256)
Possible Voltage input range:- 0v – 5v
Possible conversion
:- 0 – 255
Examples: - 0v = 0, 5v = 255, 3v = 153
Conversion formula: Input voltage *255
Conversion =
Supply voltage
5
Applied Control Systems
Connection of Light Dependant Resistor
6
Applied Control Systems
7
Applied Control Systems
8
Applied Control Systems
Voltage Regulator
9
Applied Control Systems
Voltage Regulator with Diode
10
Applied Control Systems
0V to pin 5
5V to pin 14
11
Applied Control Systems
12
Applied Control Systems
13
Measure the input voltage.
14
Measure the output voltage from the 7805
15
Applied Control Systems
Adding Capacitors
16
Applied Control Systems
Reset Switch
17
Applied Control Systems
Reset Switch
18
Applied Control Systems
Reset Switch – pin 4
19
What happens when the reset is
pressed and released?
20
Applied Control Systems
Resonator
21
Applied Control Systems
Generic components
1.
Power supply
2.
Download cable
3.
Reset connection
4.
Available Inputs
5.
Available Outputs
22
Applied Control Systems
Generic components
1.
Power supply
2.
Download cable
3.
Reset connection
4.
Available Inputs
5.
Available Outputs
23
Applied Control Systems
Using Outputs
24
Applied Control Systems
Transistor driver output
25
26
What happens when input 7 is pressed
and released?
27
Set output 7 high for 2sec- low for 2sec –
loop continually
28
Applied Control Systems
PICAXE 18X Project Board (5 inputs, 8 outputs)
Inputs
Outputs
4 Terminal blocks
6 LED outputs
1 Digital
thermometer
Two transistor
driven terminal
blocks
29
Applied Control Systems
Use circuit No. 8 to help complete the diagram
Outputs
Inputs
(a)
(b)
30
Applied Control Systems
Green
Yellow
w
Red
Green
Yellow
Red
31
32
Applied Control Systems
33
Applied Control Systems
34
Applied Control Systems
Inputs
Outputs
35
Applied Control Systems
Inputs
Outputs
Identify your input and output needs
36