Académique Documents
Professionnel Documents
Culture Documents
4
5
6
7
8
9
10
11
12
13
15
17
5. MikroICD;
6. USB connector;
7. Optocouplers;
18. Relays;
Step no.1
Take the development system and product CD out of the box. Insert the product
CD into CD drive. Please, do not connect the development system to a PC yet.
Step no.2
Install PICPLC8A programmer software to enable a program to be transferred from PC to the microcontroller chip. Installation instructions are con/
tained in the PICFlash 2 programmer manual.
Step no.3
Install USB drivers on your PC to enable programmer's hardware to operate properly on the PICPLC8A board. For detailed installation instructions
refer to the 'Installing USB drivers' manual.
Step no.4
Connect the PICPLC8A to PC using USB cable. Please use one of USB
ports on the back of the PC because they are directly connected to the com
puter motherboard.
The first time you switch the PICPLC8A on, your PC will automatically
detect a new hardware. You will be immediately prompted whether Windows should search for new drivers update or not. Select the option 'No, not
this time' and click 'Next'. Another window appears, click 'Next' and the
operating system will automatically find the drivers. Click 'Finish' to complete this process and run PICFlash 2 as explained in the PICFlash 2 programmer manual.
Next time you switch the PICPLC8A on, Windows will not ask for new
drivers update during driver installation.
.
After these four steps, your PICPLC8A is successfully installed and ready for use. You can read
a program from the chip or write another one into it. The product CD provides numerous simple program examples to make your first steps Easy...
Apart from this manual, the development system box contains development system, product CD,
USB cable, and user's manuals for installing PICflash 2 programmer and USB drivers. In order to
use PICPLC8A properly, it is necessary to go through the following steps:
INTRODUCTION
INTRODUCTION
PICPLC8A is a programmable logic controller design to control devices in industry and automatics using relays. It has a built-in programmer so that there is no need for additional hardware for the microcontroller programming. Besides, this controller has inputs isolated by optocouplers, RS-232 and RS-485 communication modules and PS/2 communication module as
well. Four IDC-10 male connectors enable the PICPLC8A to be directly connected to the
microcontroller pins, if needed.
Figure 1 illustrates the PICPLC8A development system. There are identification marks next to
each component on a silkscreen, both on the top and bottom. These marks describe connections
to the microcontroller, operation modes and provide other useful information so that there is
almost no need for additional schematics.
Figure 1
JUMPERS
Jumper is commonly used as a selector between two possible connections via 3-pin connector.
As illustrated in Figure 2, the middle connector pin can be connected to the left or right pin,
depending on the jumpers position.
Jumper is not
placed and
middle pin is
unconnected.
Figure 2
Jumper as a selector
Jumper is placed
on the right side
connecting middle
and right pin.
Jumper is placed
on the left side
connecting middle and left pin.
JUMPERS
Jumpers are devices used to break or establish connection between two points. Under the plastic cover of a jumper, there is a metal contact which establishes connection when the jumper is
placed over two pins.
MCU PORT
The PICPLC8A supports 40-pin microcontrollers in DIP40
package (PIC18F4520). See Figure 3. The microcontroller
pins are routed to various peripherals. All ports are directly
connected to Direct Port Access Connectors. These connectors are normally used for connecting external peripherals to
the board or as points for connecting digital logic probes.
Some of the pins are connected to other peripherals such
as optocouplers, RS-232 communication, RS-485 communication, etc.
MCU PORT
Figure 4
System connection
POWER SUPPLY
Figure 6
Note:
Power supply
POWER SUPPLY
10
Figure 9
RS232 connector
11
12
RS-485 communication circuit enables point-to-point data transfer. It is commonly used to transfer data between several microcontrollers. LTC485 interface transceiver is used to transform a signal on microcontrollers Rt, Rx and
Tx lines into a differential signal on A and B lines.
The PICPLC8A development board has one RS-485 communication circuit. In
order to provide more flexible system, the microcontroller is connected to
LTC485 via three jumpers (J10,J11 and J12) as shown in Figure 12.
OPTOCOUPLERS
13
OPTOCOUPLERS
The PICPLC8A has 8 optocouplers inputs. Optocouplers are widely used in industrial applications
where inputs must be electrically isolated from the rest of the development board. The main objective is to protect the microcontroller from voltage spikes that might occur on input lines.
In order that input circuit is electrically isolated from the rest of the board, it must have its own
power supply (12V DC).The optocoupler chip has two LEDs on each input and two open collector transistors on each output pin. All optocoupler outputs are connected to the microcontroller PORTB. PORTB must be driven high by putting jumper J6 in the upper position (pullup), because optocoupler has open drain output.
OPTOCOUPLERS
14
RELAYS
15
RELAYS
In order to control devices using high power for their operation, the PICPLC8A has 8 relays connected to the microcontroller PORTD. The relay coil voltage amounts to 12V DC (+U12).
Figure 15 Relays
The microcontroller PORTD pins cannot provide enough current necessary to directly run
relays so that they are connected to the ULN2804 Darlington drivers. Each relay has one LED
indicator connected in parallel with its coil. It is used to indicate whether the appropriate relay
is active or not. There is only normally open contact on each relays output (for example W0A and W0-B).
RELAYS
16
17
Relays
Power supply
regulator
External power
supply 16V-30V
DC 12V-22V AC
Optocoupler,RS-232 and
RS485 connectors
Reset pushbutton
Power supply
supervisor
MCU 8MHz
crystal
PICPLC8A
Optocouplers
Direct port
access
Jumpers to
determine input
pin performance in idle
state (connected to pull-up or
pull-down resistors)
RS-485 module
connector
PS/2 connector
USB 2.0
connector