3.0 ARCHITECTURAL OVERVIEW
‘The high performance of the PIC16F827A/622N/842A
family can be attributed to a number of architectural
features commonly found in RISC microprocessors. To
bogin with, the PICI6F627A623A648A uses a
Harvard architecture in which program and data are
accessed from separate memories using separate
busses. This improves bandwidth over traditional Von
Neumann architecture where program and data are
fetched from the same memory. Separating program
and data mamory further allows instructions to be sized
differently than 8-bit wide data word. Instruction
opcodes are 14-pits wide making it possible to have all
single.word instructons. A 14-bit wide program memory
access bus fetches a 14-bit instruction in a singlo
cycle. A two-stage pipeline overlaps fetch and execution
of instructions. Consequently all instructions (25)
execute in a single-cycle (200 ns @ 20 MHz) except for
program branches.
Table 21 lists device memory sizes (Flash, Data and
EEPROM),
ota
‘The PICIGF627A/625A/648A can directly or indirectly
address its register files or data memory. All Special
Function Registers (SFR), Including tne program
‘counter, are mapped in the data memory. The
PIC16F627A/625A/64EA have an orthogonal (symmetrical)
instruction set that makes it possible to Carry Out.
any operation, on any register, using any addressing
mode. This symmetrical nature anc lack of special,
‘optimal situations’ makes programming with the
PIC1GFE27A/620A/648A simple yet efficient. In
addition, the learning curve is reduced significantly.
‘The PIC16627A/628A/648A devices contain an 8-bit
ALU and working register. The ALU Is a general
purpose arithmetic unit it performs arithmetic and
Boolean functions belween dala in the working register
and any repister fle.
‘The ALU is 8-bits wide and capable of addition,
subtraction, shift and logical operations. Unless
‘otnerwise mentioned, arithmetic operations are two's
‘complement in nature. In two-operand instructions,
typically one operand is the working register
(Wi tegister). The other operand is a file register or an
immediate constant. In single operand instructions, the
‘operand is either the W register ora file register.
‘The W register Is an 8-it working register used for ALU
‘operations. It is not an addressable register.
Depending an the instruction executed, the ALU may
affect he values of the Carty (C), Digit Canty (DC), and
Zero (2) biis n the Status Register. The C and DC pis
‘operate as Borrow and Digit Borrow out bis,
respectively, in subtraction. See the SUBLW and SUBWF
instructions tor examples.
‘A simplified block diagram is shown in Figure 3-1, and
a description of the device pins in Table 3-2.
‘Two types of data memory are provided on the
PIC16F627A162BA/EA8A devices. Nonvolatlle
EEPROM data memory is provided for long term.
storage of cata, such 38 calloration valves, 100K-Up
table data, and any otfier data which may require
periodic updating in the field. These data types are not
Jost wnen power Is removed. The omer data memory
provided is regular RAM daia memory. Regular RAM
data memory is provided for temporary storage of data
‘during normal operation. Datais lost when power is
removed
88/5000
3.0 RESUMEN ARQUITECTONICO.
El allo rendimiento del PIC18F627A / 628A / BSA,
‘familia se puede atribuir @ una serie de arquitecténicos
caracteristicas que se encuentran cominmente en los
microprocesadores RISC. A
‘comenzar, el PICISF627A /628A / 649A usa un
‘Arquitectura de Harvard en la cual 8l programa y los datos son
accedido desde memonas separadas usando por separado
autobuses Esto mejore e! ancho de banda sobre Von tradicional
La arquitectura Neumann donde el programa y los datos son
tomado del mismo recuerdo. Programa de separacion
la memoria de datos ademas permite que las instrucciones se
dimensionen
diferente a la palabra de datos de 6 bits de ancho. Instruccion
Los codigos de operacion tienen 14 bits de ancho, lo que
permite tener todos
Instrucciones de una sola palabra. Una memoria de programa
amplia de 14 bits:
bus de acceso obtiene una instruccién de 14 bits en un solo
Ciclo. Una tuberia de dos etapas se superpone ala obtencion y
‘ejecucion
do instrucciones En consecuencia, todas las instrucciones (35)
ejecutar en un solo ciclo (200 ns @ 20 MHz) excepto por
ramas del programa.
La Tabla 3-1 enumera los tamafios de memoria del dispositive
(Flash, Datos y
EEPROM).
EI PIC18FA27A / 628A / 648A puede directa o indirectamente
direccionar sus arciivos de registro o memoria de datos. Todo especial
Rogistras de tuncion (SFR), ineluldo e! programa
contador, estan mapeados en la memoria de datos los
PICI6FA27A / 628A / 648A tienen una orlogonal (simétrica)
cconjunto de instruceiones que nace posiole levar a cabo
‘cualquier operacion. en cualquier registro, usando cualquier direccion,
‘modo. Esta naturaleza simétrca y la Talia de ‘especial
situaciones éptimas nace que la programacion con e!
PICIGF627A / 628A 645A simple pero cficente. En
Ademas, la curva de aprendizale se reduce significatwamente.
Los dispositivos PIC18F627A / 628A / 648A contlenen un 8 bits
ALU y registro de trabajo. La ALU es un general
lunidad artmética de propésito Realiza antmética y
Funciones booleanas enlre datos en el registo de trabajo
'y cualguler atenwo de registro.
La ALU tiene 6 bits de ancho y es capaz de agregarse
testa, cambio y operaciones logicas. A no ser que
{de 10 contrario, las operaciones antméticas son dos
‘compiemento én la naturaleza. En insirueciones de dos operandos,
tipicamente un operando es el registro de trabajo
(WV fegisto) £1 otro operando es un archivo de registro o un
consiante inmesiata. En mstrucciones de un solo operando,
‘operando es el registro W 0 un registro de archivo.
El registio W es un registro de trabajo de 6 bits ullizado para ALU
‘operaciones. No es un registro direccionable.
Dependiendo de la instruccion ejecutada, la ALU pued=
afeclan los valores de Carty (C), Dig Carry (DC) y
Cero (Z) bis en el registo de estado. Los Dts C y OC
‘operat como Barraw y Digit Borrow bits,
respectivamente, en resta. Vea SUBLW y SUBWF
Instrucciones vara elemolos.
Un diagrama de bloques simplincado se muestra en la Figura 3-1, y
tuna descripcién de las pines del dispositivo en la Tabla 5-2
‘Se proporcionan dos tipos de memoria de datos en
Dispositvos PIC 16F627A / 628A / 648A. No voll
La memoria de datos EEPROM se proporciona a largo plazo
‘almacenamiento de datos, como valores de calloracion, nUsqueda
alos de tablas y cualquier otro dato que pueda requerir|
‘actuaiizacién periddica en el campo. Estos tipos de datos no son
perdide cuando se elimina la potenela. La otra memoria ce datos
‘S€ proporciona memoria de datos RAM regular. RAM regular
la memoria de datos se proporciona para el almacenamiento temporal
de datos
‘durante el funcionamiento normal. Los datos se pierden cuando el poder
es
femoto,