Download as pdf or txt
Download as pdf or txt
You are on page 1of 8

PIC-P40 development board

Users Manual
All boards produced by Olimex are ROHS compliant
Rev.E, February 2008
Copyright(c) 2008, OLIMEX Ltd, All rights reserved
Page 1
INTRODUCTION:
PIC-P40 board is development board, which allow you to prototype and
develop code for all Microchips PIC microcontrollers with 40 pins.
What you can do with PIC-P40? A lot of stuff lets see what we have:
PIC-P40 have RS232 connector and driver, so you can interface your
PIC microcontroller to other embedded or PC with RS232. The RS232
driver have 4 lines Tx, Rx, CTS and jumper selectable RTS or DTR.
The pin labeled RX is output and should be connected to PIC UART Tx.
The pin labeled TX is input and should be connected to PIC UART Rx.
Note that MAX232 driver on the socket is 5V device, so if you decide
to run your PIC on 3.3V you should replace it with MAX3232 which
works on 3.3V
The on-board ICSP connector allow you to program the PIC on the
board without pulling it of the socket, by ICSP programmer like PIC-
MCP, PIC-MCP-USB, PIC-PG1, PIC-PG2, PIC-PG3, PIC-PG4 or to
program and debug it with PIC-ICD2, PIC-ICD2-POCKET or PIC-ICD2-
TINY. IMPORTANT: all programmers provide power supply through
ICSP connector during the programming PIC-P40 should not be
powered via the external power jack!
The power supply circuit have diode bridge after the power supply jack
which allow you to power this board with both AC and DC power
supply adapters. The input voltage could be anything within the range
+7.5 15V DC or 6-12V AC.
Voltage regulator is made with LM317 adjustable voltage regulator and
have jumper which selects what voltage you supply to the PIC
microcontroller +3.3V or +5V, so you can work with PICs on both low
and normal voltage.
The oscillator circuit is made with 20 Mhz crystal oscillator, so you
can run your PIC at maximum performance.
The RESET circuit is made with simple RC circuit and RESET push
button, the reason to not use RESET IC is that the board should
support both 3.3V and 5V operation while RESET ICs are on fixed
voltage.
PIC-P40 have user button for user input connected to PIC
microcontrollers RE2 port. When RE2 port is initialized as INPUT you
will read 0 when the button is pressed and 1 when it is depressed.
Status LED is connected via jumper to PIC microcontrollers RA0 port.
When your RA0 port is initialized as OUTPUT and set to 0 LED will
go ON, when RA0 port is set to 1 LED will go OFF.
PIC-P40 have handy GND pin for connection to oscilloscope.
Page 2
Page 3
FEATURES:
ICSP/ICD connector for programming and debugging
RS232 interface with MAX232 IC on socket
DIL40 microcontroller socket
Quartz crystal 20Mhz
LED to RA0 through jumper
user Button to RE2
Reset button and circuit
Power plug-in jack, accept AC and DC input
selectable +3.3V / +5V power supply voltage regulator (3.3V when jumper is
closed)
Extension slot on every uC pin
Gird 100 mils
GND bus
Vcc bus
Four mounting holes 3,3 mm (0,13")
FR-4, 1.5 mm (0,062"), green soldermask, white silkscreen component print
Dimensions 100x80 mm (3,9x3,15")

Page 4
SCHEMATIC:
Page 5
4
.
7
u
F
/
2
5
V
D
C
4
.
7
u
F
/
2
5
V
D
C
4
.
7
u
F
/
2
5
V
D
C
4
.
7
u
F
/
2
5
V
D
C
1
0
0
n
4
7
0
u
F
/
1
6
V
D
C
1
0
0
u
F
/
1
6
V
D
C
2
2
p
2
2
p
1
0
0
n
1
0
0
n
N
A
1N4004
B
-
D
I
L
+
5
V
+
5
V
+
5
V
+
5
V
4
-
2
0
M
H
z
3
3
0
1
0
K
390/1%
240/1%
330/1%
1
0
k
P
I
C
1
6
F
8
7
S
S
M
A
X
2
3
2
L
M
3
1
7
3
.
3
V
B
U
T
C
1
C
2
C
3
C
4
C
5
C
6
C
7
C
8
C
9
C
1
0
C
1
1
C
1
2
C
1
3
C
T
S
D1
G
1
123456
I
C
S
P
1 2 3
J
2
123
J
3
L
E
D
1
2
L
E
D
_
J
P
W
R
Q
1
R
1
R
2
R3
R4
R5
R
6
12345
6789
R
S
2
3
2
R
S
T
R
T
S
/
D
T
R
R
X
T
X
I
N
T
/
R
B
0
3
3
M
C
L
R
#
/
T
H
V
1
O
S
C
1
/
C
L
K
I
N
1
3
O
S
C
2
/
C
L
K
O
U
T
1
4
P
G
C
/
R
B
6
3
9
P
G
D
/
R
B
7
4
0
P
G
M
/
R
B
3
3
6
P
S
P
4
/
R
D
4
2
7
P
S
P
5
/
R
D
5
2
8
P
S
P
6
/
R
D
6
2
9
P
S
P
7
/
R
D
7
3
0
R
A
0
/
A
N
0
2
R
A
1
/
A
N
1
3
R
A
2
/
A
N
2
4
R
A
3
/
A
N
3
5
R
A
4
/
T
0
C
K
I
6
R
A
5
/
A
N
4
7
R
B
1
3
4
R
B
2
3
5
R
B
4
3
7
R
B
5
3
8
R
C
0
/
T
1
O
S
O
1
5
R
C
1
/
T
1
O
S
I
1
6
R
C
2
/
C
C
P
1
1
7
R
C
3
/
S
C
K
1
8
R
D
0
/
P
S
P
0
1
9
R
D
1
/
P
S
P
1
2
0
R
D
2
/
P
S
P
2
2
1
R
D
3
/
P
S
P
3
2
2
R
E
0
/
R
D
#
/
A
N
5
8
R
E
1
/
W
R
#
/
A
N
6
9
R
E
2
/
C
S
#
/
A
N
7
1
0
R
X
/
R
C
7
2
6
S
D
I
/
R
C
4
2
3
S
D
O
/
R
C
5
2
4
T
X
/
R
C
6
2
5
11
32
12
31
U
1
V
D
D
V
S
S
C
1
+
1
C
1
-
3
C
2
+
4
C
2
-
5
R
1
I
N
1
3
R
1
O
U
T
1
2
R
2
I
N
8
R
2
O
U
T
9
T
1
I
N
1
1
T
1
O
U
T
1
4
T
2
I
N
1
0
T
2
O
U
T
7
V
+
2
V
-
6
U
2
1
5
1
6
G
N
D
V
C
C
U
2
P
A
D
J
I
N
O
U
T
V
R
1
1
2
-
R
T
S
2
3
-
D
T
R
RB3/RB5
P
I
C
-
P
4
0
R
e
v
.

E
C
O
P
Y
R
I
G
H
T
(
C
)

2
0
0
8
,

O
l
i
m
e
x

L
t
d
.
h
t
t
p
:
/
/
w
w
w
.
o
l
i
m
e
x
.
c
o
m
/
d
e
v
SOFTWARE:
DEMO1: PIC16F877-I/P BLINK LED
This is demo code which blinks the LED on PIC-P40 board.
Note:
LED jumper should be closed!
DEMO2: PIC16F877-I/P BUTTON read
This is demo code which show how to read BUTTON status and to switch
the LED ON when button is pressed and LED off when the button is
depressed.
DEMO3: PIC16F877-I/P RS232 send / receive routines
This is demo code, which show how to use the USART to send and receive
characters from host PC via RS232 cable.
The MAX232 by default is not connected to PIC on the board so you have to
solder two wires one from RC6 (pin #25) of PIC16F877 Tx signal to
MAX232 Rx labeled pin, and second from RC7 (pin #26) of PIC16F877 Rx
signal to MAX232 Tx labeled pin.
You must program the HEX code to PIC16F877 and run the code.
If you programmed the PIC correctly and wired the UART, when you open
Hyperterminal on your host PC computer with 9600 bps, 8 data bit, 1 stop
bit, No flow control and apply power supply to the PIC-P40 every character
you type on the hyperterminal will be printed back with * i.e. if you type
abc you will receive a*b*c*.
Page 6
ORDER CODE:
PIC-P40 assembled and tested (no kit, no soldering required)
PIC-P40/PCB blank PCBs only
How to order?
You can order to us directly or by any of our distributors.
Check our web www.olimex.com/dev for more info.
Revision history:
REV. E - create February 2008
Page 7
Disclaimer:
2008 Olimex Ltd. All rights reserved. Olimex, logo and combinations thereof, are registered trademarks of
Olimex Ltd. Other terms and product names may be trademarks of others.
The information in this document is provided in connection with Olimex products. No license, express or implied
or otherwise, to any intellectual property right is granted by this document or in connection with the sale of Olimex
products.
Neither the whole nor any part of the information contained in or the product described in this document may be
adapted or reproduced in any material from except with the prior written permission of the copyright holder.
The product described in this document is subject to continuous development and improvements. All particulars of
the product and its use contained in this document are given by OLIMEX in good faith. However all warranties
implied or expressed including but not limited to implied warranties of merchantability or fitness for purpose are
excluded.
This document is intended only to assist the reader in the use of the product. OLIMEX Ltd. shall not be liable for
any loss or damage arising from the use of any information in this document or any error or omission in such
information or any incorrect use of the product.
Page 8

You might also like