Cha 2.0
Cha 2.0
Cha 2.0
Microcontroller
1
Outline
– Introduction
– Types of Microcontrollers
– Microchip PIC
• PIC16F877a
– External view of PIC16F877a
• Pin diagram and functionality of PIC16F877a
– Block diagram and description of functionalities(PIC16F877a)
• Architecture
• Internal block diagram
– Memory
» Program memory
» Data memory
• GPRs
• SFRS
• Memory banks
– PIC16F877a Registers
» CPU register
– I/O ports and peripherals modules
2
Introduction
What is a microcontroller?
A microcontroller (sometimes abbreviated µC, uC or MCU) is a small
computer on a single integrated circuit containing a processor core,
memory, and programmable input/output peripherals. It can only
perform simple task. A microcontroller is often described as a
‘computer-on-a-chip’.
3
Introduction
• Microcontrollers are purchased ‘blank’ and then programmed with a specific
control program.
• Once programmed the microcontroller is build into a product to make the
product more intelligent and easier to use.
6
Examples of Embedded System
• Consumer Electronic : DVD player, wi-fi, air-conditioner,
washing machine etc.
• Medical Monitoring Devices : ECG (electrocardiogram), blood
pump, blood pressure meter, etc.
• Security System : Alarm, remote sueveilance, smart card +
reader etc.
• Closed Loop Process Control : Motor speed control, robot, etc.
• Personal Computing : Keyboard, printer, USB hub, SCSI HD, etc.
• Automotive : Ignition control, Automatic transmission, anti-lock
brake system (ABS), active suspension, etc
• Military : Missile, torpedo, ejection seat, etc
• Communications : Handphone, modem, radar, satelite etc.
7
Types of Microcontroller
• Parallax Propeller
• Freescale 68HC11 (8-bit)
• Intel 8051
• Silicon Laboratories Pipelined 8051 Microcontrollers
• ARM processors (from many vendors) using ARM7 or Cortex-M3
cores are generally microcontrollers
• STMicroelectronics STM8 (8-bit), ST10 (16-bit) and STM32 (32-bit)
• Atmel AVR (8-bit), AVR32 (32-bit), and AT91SAM (32-bit)
• Freescale ColdFire (32-bit) and S08 (8-bit)
• Hitachi H8, Hitachi SuperH (32-bit)
• Hyperstone E1/E2 (32-bit, First full integration of RISC and DSP on
one processor core [1996])
• Infineon Microcontroller: 8, 16, 32 Bit microcontrollers for
automotive and industrial applications.
…cont’d
• MIPS (32-bit PIC32)
• NEC V850 (32-bit)
• Microchip PIC (8-bit PIC16, PIC18, 16-bit dsPIC33/PIC24)
• PowerPC ISE
• PSoC (Programmable System-on-Chip)
• Rabbit 2000 (8-bit)
• Texas Instruments Microcontroller MSP 430 (16-bit), C2000 (32-
bit), and Stellaris (32-bit)
• Toshiba TLCS-870 (8-bit/16-bit)
• Zilog eZ8 (16-bit), eZ80 (8-bit)
• etc
Microchip PIC
• PIC is a family of Harvard architecture microcontroller made by
Microchip Technology. The name PIC initially referred to
"Peripheral Interface Controller“ . PIC microcontrollers were the
first RISC microcontroller.
1:
Why use PIC16F877A?
Timers 3
CCP 2