PIC16F84-10/P Microchip Technology, PIC16F84-10/P Datasheet - Page 567

IC MCU FLASH 1KX14 EE 18DIP

PIC16F84-10/P

Manufacturer Part Number
PIC16F84-10/P
Description
IC MCU FLASH 1KX14 EE 18DIP
Manufacturer
Microchip Technology
Series
PIC® 16Fr

Specifications of PIC16F84-10/P

Program Memory Type
FLASH
Program Memory Size
1.75KB (1K x 14)
Package / Case
18-DIP (0.300", 7.62mm)
Core Processor
PIC
Core Size
8-Bit
Speed
10MHz
Peripherals
POR, WDT
Number Of I /o
13
Eeprom Size
64 x 8
Ram Size
68 x 8
Voltage - Supply (vcc/vdd)
4 V ~ 6 V
Oscillator Type
External
Operating Temperature
0°C ~ 70°C
Processor Series
PIC16F
Core
PIC
Data Bus Width
8 bit
Data Ram Size
68 B
Maximum Clock Frequency
10 MHz
Number Of Programmable I/os
13
Number Of Timers
1
Operating Supply Voltage
2 V to 6 V
Maximum Operating Temperature
+ 70 C
Mounting Style
Through Hole
3rd Party Development Tools
52715-96, 52716-328, 52717-734
Development Tools By Supplier
ICE2000
Minimum Operating Temperature
0 C
Lead Free Status / RoHS Status
Lead free / RoHS Compliant
For Use With
DVA16XP180 - ADAPTER DEVICE FOR MPLAB-ICEAC164010 - MODULE SKT PROMATEII DIP/SOIC
Data Converters
-
Connectivity
-
Lead Free Status / Rohs Status
Lead free / RoHS Compliant

Available stocks

Company
Part Number
Manufacturer
Quantity
Price
Part Number:
PIC16F84-10/P
Manufacturer:
MICROCHIP
Quantity:
4 499
Part Number:
PIC16F84-10/P
Manufacturer:
MIC
Quantity:
1 000
Part Number:
PIC16F84-10/P
Manufacturer:
MIC
Quantity:
20 000
29.6
1997 Microchip Technology Inc.
Design Tips
Question 1:
Answer 1:
There are a few possibilities, two are:
1.
2.
Question 2:
Answer 2:
For code compatibility and upgrades to later parts, the use of the TRIS instruction is not recom-
mended. You should note the TRIS instruction is limited to ports A, B and C. Future devices may
not support these instructions.
Question 3:
Answer 3:
No. The TRIS instruction is Bank independent. Again the use of the TRIS instruction is not rec-
ommended.
Question 4:
Answer 4:
An easy example of a Read-Modify-Write (R-M-W) instruction is the bit clear instruction BCF. You
might think that the processor just clears the bit, which on a port output pin would clear the pin.
What actually happens is the whole port (or register) is first read, THEN the bit is cleared, then
the new modified value is written back to the port (or register). Actually, any instruction that
depends on a value currently in the register is going to be a Read-Modify-Write instruction. This
includes ADDWF, SUBWF, BCF, BSF, INCF, XORWF , etc... Instructions that do not depend on
the current register value, like MOVWF, CLRF, and so on are not R-M-W instructions.
One situation where you would want to consider the affects of a R-M-W instruction is a port that
is continuously changed from input to output and back. For example, say you have TRISB set to
all outputs, and write all ones to the PORTB register, all of the PORTB pins will go high. Now, say
you turn pin RB3 into an input, which happens to go low. A BCF PORTB,6 is then executed to
drive pin RB6 low. If you then turn RB3 back into an output, it will now drive low, even though the
last value you put there was a one. What happened was that the BCF of the other pin (RB6)
caused the whole port to be read, including the zero on RB3 when it was an input. Then, bit 6
was changed as requested, but since RB3 was read as a zero, zero will also be placed back into
that port latch, overwriting the one that was there before. When the pin is turned back into an
output, the new value was reflected.
For the midrange devices, there are several instructions that work with a literal and W. For
instance, if it were desired to decrement W, this can be done with an ADDLW 0xFF. (the 0x
prefix denotes hex to the assembler)
Notice that all of the instructions can modify a value right where it sits in the file register.
This means you can decrement it right where it is. You do not even need to move it to W.
If you want to decrement it AND move it somewhere else, then you make W the DESTI-
NATION of the decrement (DECF register,W) then put it where you want it. It is the same
number of instructions as a straight move, but it gets decremented along the way.
How can I modify the value of W directly? I want to decrement W.
Is there any danger in using the TRIS instruction for the PIC16CXXX since
there is a warning in the Data book suggesting it not be used?
Do I have to switch to Bank1 of data memory before using the TRIS instruc-
tion (for parts with TRIS registers in the memory map)?
I have seen references to “Read-Modify-Write” instructions in your data
sheet, but I do not know what that is. Can you explain what it is and why I
need to know this?
Section 29. Instruction Set
DS31029A-page 29-45
29

Related parts for PIC16F84-10/P