0% found this document useful (0 votes)
4 views

The PIC MCU

Uploaded by

akocyriel5
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
4 views

The PIC MCU

Uploaded by

akocyriel5
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 13

THE PIC

MICROCONTROLLERS
DEFINITION

• A PIC (Peripheral Interface Controller) microcontroller is an


embedded circuit which contains essential elements of a
computer (processor, RAM, ROM, peripherals ports, Input /
Output interface…) all built on a single small chip.
PIC FAMILIES
• Although there are several hundred models of PIC
microcontrollers, the family can be broken down into
three main groups, which are:
 12-bit instruction word or Base-Line: (e.g. 12C5XX, 16C5X);

 14-bit instruction word or Mid-Range: (e.g. 16F8X, 16F87X, 16CXX);

 16-bit instruction word or High-End: (e.g. 17C7XX,


18C2XX, 18FXXXX).
MAIN PIC CHARACTERISTICS
All PIC microcontrollers offer the following features:

 RISC instruction set with only a handful of instructions to learn;


 Digital I/O ports;
 On-chip timer with 8-bit prescaler;
 Power-on reset;
 Watchdog timer;
 Power saving SLEEP mode;
 High source and sink current;
 Direct, indirect, and relative addressing modes;
 External clock interface;
 RAM data memory;
 EPROM or Flash program memory;
MAIN PIC CHARACTERISTICS

 Analogue input channels;

 Analogue comparators;

 Additional timer circuits;

 EEPROM data memory;

 External and internal interrupts;

 Internal oscillator;

 Pulse-width modulated (PWM) output;

 USART serial interface;


MAIN PIC CHARACTERISTICS

Some even more complex devices in the family offer the following additional features:

 CAN bus interface;

 I2C bus interface;

 SPI bus interface;

 Direct LCD interface;

 USB interface;

 Motor control
IDENTIFICATION OF A PIC
To identify a PIC, we can simply use its code.

PICXX-X-XX-XX

PICXX-X-XXX-XX The last digits represent the


maximum clock frequency that
PICXX-X-XXXX-XX the PIC microcontroller can
receive. For example, -04
means that the maximum
frequency is 4MHz. But if at
The two first digits After that the letters below Now the following digits the place of the suffix “-XX”
represent the range of the can follow: precisely identify the PIC. we find the character “A”, it
PIC, for example, 16 C indicates that the They indicate the real name means that the PIC can be
indicate a PIC mid-range. program memory is of the PIC clocked by a maximum
EPROM
frequency of 20MHz. it also
CR indicate that the
means that the supplying be up
memory type is ROM;
to 7.5V.
F for flash memory or
EEPROM.
NB: At times the frequency nor
the letter A are written
EXAMPLES
 A 12C671-20 is Base-Line PIC (12), with EPROM, of type 671 with 20MHz as maximum clock
frequency.

 A 16F84-04 is Mid-Range PIC (16), with flash memory, of type 84 with 4MHz as maximum clock
frequency.

• A 16F877A is Mid-Range PIC (16), with flash memory, of type 877 with 20MHz as maximum clock
frequency.

• A 18F2550 is High-End PIC (18), with flash memory, of type 2550 with 20MHz as maximum clock
frequency.

• A 18F4620-12 is High-End PIC (18), with flash memory, of type 4620 with 12MHz as maximum
clock frequency.
THE PIC16F84A MICROCONTROLLER
Characteristics
Program memory (FLASH) - for storing a written program. The 16F84 offers a 1024 x 14 flash program
memory. That is 1 kilo words of 14 bits

RAM - The 16F84 offers a 36 bytes of data RAM.

EEPROM - The 16F84 offers a 64 bytes of non-volatile EEPROM data memory.

PORTA and PORTB are physical connections between the microcontroller and the outside world. Port A has
five pins (RA0, RA1, RA2, RA3, RA4), and port B eight pins (RB0, RB1, RB2, RB3, RB4, RB5, RB6, RB7).

FREE-RUN TIMER- The timer can be used for measuring time which is very useful with some devices.

CENTRAL PROCESSING UNIT has a role of connective element between other blocks in the microcontroller.
It coordinates the work of other blocks and executes the user program.
INTERNAL ARCHITECTURE OF THE
16F84
PIN CONFIGURATION AND DESCRIPTION OF THE 16F84A
SETTING OF PINS
SOME OTHER PIC
MICROCONTROLLERS
U4
U5 U4 13
OSC1/CLKIN RB0/INT
33
9 21 14 34
16 17 OSC1/CLKIN RB0/INT OSC2/CLKOUT RB1
OSC1/CLKIN RA0 10 22 1
MCLR/Vpp/THV RB2
35
15 18 OSC2/CLKOUT RB1 36
OSC2/CLKOUT RA1 23 RB3/PGM
1 RB2 2 37
RA2 2 24 RA0/AN0 RB4
4 2 RA0/AN0 RB3/PGM 3 38
MCLR RA3 3 25 RA1/AN1 RB5
3 RA1/AN1 RB4 4
RA2/AN2/VREF- RB6/PGC
39
RA4/T0CKI 4 26 5 40
RA2/AN2/VREF-/CVREF RB5 RA3/AN3/VREF+ RB7/PGD
5 27 6
6 RA3/AN3/VREF+ RB6/PGC RA4/T0CKI
RB0/INT 6 28 7 15
7 RA4/T0CKI/C1OUT RB7/PGD RA5/AN4/SS RC0/T1OSO/T1CKI
RB1 7 16
8 RA5/AN4/SS/C2OUT RC1/T1OSI/CCP2
RB2 11 8 17
9 RC0/T1OSO/T1CKI RE0/AN5/RD RC2/CCP1
1 12 9 18
RB3 MCLR/Vpp/THV RC1/T1OSI/CCP2 RE1/AN6/WR RC3/SCK/SCL
10 13 10 23
RB4 RC2/CCP1 RE2/AN7/CS RC4/SDI/SDA
24
11 14 RC5/SDO
RB5 RC3/SCK/SCL 25
12 15 RC6/TX/CK
RB6 RC4/SDI/SDA 26
13 16 RC7/RX/DT
RB7 RC5/SDO
17
RC6/TX/CK 19
PIC16F84A 18 RD0/PSP0
RC7/RX/DT 20
RD1/PSP1
21
PIC16F876A RD2/PSP2
22
RD3/PSP3
27
RD4/PSP4
28
RD5/PSP5
29
RD6/PSP6
30
RD7/PSP7
PIC16F877

You might also like