Download presentation
Presentation is loading. Please wait.
Published byFerdinand Hart Modified over 9 years ago
1
Aum Amriteswaryai Namah:
2
HHHHave separate program memory and data Memory AAAAccessed by separate busses
3
PIC 16F877A Microcontroller Like any microcontroller, it has CPU, memory and I/O in one chip. Using some I/O devices like keypad, display and interfacing circuits we can create a ‘complete system’. PIC based wireless sensor board
4
Aum Amriteswaryai Namah:
6
PIN DIAGRAM
8
Memory Classification Memory Memory Program Memory Program Memory Data Memory Data Memory General Purpose RAM General Purpose RAM Special Function Registers Special Function Registers
9
Specifications of program memory PM (program memory) = 8k words PC (program counter = 13 bits wide to address PM) Each word = 14 bits => All op-codes are 14 bit wide. PM (program memory) = 8k words PC (program counter = 13 bits wide to address PM) Each word = 14 bits => All op-codes are 14 bit wide.
10
Data Memory Organization DDDData memory = RAM File = File Registers. 555512 bytes arranged in 4 banks of 128 bytes each. W W W Width of word = 8 bits GGGGeneral Purpose Registers (GPR): Called scratch pad area/registers ----For data storage -----For scratch pad operations SSSSpecial Function Register (FSR, STATUS etc.) ----Control operation of the device
11
RAM FILE BANKS FFirst 32 of each bank = reserved. The important register (eg: STATUS) values are repeated in each bank. EEach bank = 128 bits wide. Hence need only 7 bits for address. To select one among the 4 banks, 2 bits (b6 b5) of status register is used. bb6 = RP1, b7 = RP0 RRP1 RP0 = 00 => bank 0 selected ; RP1 RP0 = 01 => bank 1 selected RRP1 RP0 = 10 => bank 2 selected ; RP1 RP0 = 11 => bank 3 selected
12
16 registers of each bank is common and repeated in all 4 banks. Hence common data is stored here during bank switching. RAM FILE BANKS contd… GPRs SFRsBank0000h 01Fh 020h 07Fh GPRs SFRs Bank1 080h 09Fh 0A0h 0FFh 0F0h GPRs SFRs Bank2 100h 11Fh 120h 17Fh 170h GPRs SFRs Bank3 180h 19Fh 1A0h 1FFh 1F0h RP RP RP RP RP RP RP RP = 00 = 01 = 10 = 11 = 00 = 01 = 10 = 11
14
WREG - Working Register TTTThe WREG register is referred to as working register IIIIs a special register inside the CPU of uC DDDDoesn’t reside in Data Memory like SFRs IIIInvolves in the execution of many instructions CCCCan be the destination of many instructions.
15
Status Register
16
Status Register contd..
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.