PIC16C84-04I/P Microchip Technology, PIC16C84-04I/P Datasheet

IC MIC CTL EEPM 1K 4MHZ IT 18DIP

PIC16C84-04I/P

Manufacturer Part Number
PIC16C84-04I/P
Description
IC MIC CTL EEPM 1K 4MHZ IT 18DIP
Manufacturer
Microchip Technology
Series
PIC® 16Cr
Datasheet

Specifications of PIC16C84-04I/P

Core Processor
PIC
Core Size
8-Bit
Speed
4MHz
Peripherals
POR, WDT
Number Of I /o
13
Program Memory Size
1.75KB (1K x 14)
Program Memory Type
EEPROM
Eeprom Size
64 x 8
Ram Size
36 x 8
Voltage - Supply (vcc/vdd)
4 V ~ 6 V
Oscillator Type
External
Operating Temperature
-40°C ~ 85°C
Package / Case
18-DIP (0.300", 7.62mm)
Lead Free Status / RoHS Status
Request inventory verification / Request inventory verification
Data Converters
-
Connectivity
-
High Performance RISC CPU Features:
• Only 35 single word instructions to learn
• All instructions single cycle (400 ns @ 10 MHz)
• Operating speed: DC - 10 MHz clock input
• 14-bit wide instructions
• 8-bit wide data path
• 1K x 14 EEPROM program memory
• 36 x 8 general purpose registers (SRAM)
• 64 x 8 on-chip EEPROM data memory
• 15 special function hardware registers
• Eight-level deep hardware stack
• Direct, indirect and relative addressing modes
• Four interrupt sources:
• 1,000,000 data memory EEPROM
• EEPROM Data Retention > 40 years
Peripheral Features:
• 13 I/O pins with individual direction control
• High current sink/source for direct LED drive
• TMR0: 8-bit timer/counter with 8-bit
Special Microcontroller Features:
• Power-on Reset (POR)
• Power-up Timer (PWRT)
• Oscillator Start-up Timer (OST)
• Watchdog Timer (WDT) with its own on-chip RC
• Code protection
• Power saving SLEEP mode
• Selectable oscillator options
• Serial In-System Programming - via two pins
M
except for program branches which are two-cycle
- External RB0/INT pin
- TMR0 timer overflow
- PORTB<7:4> interrupt on change
- Data EEPROM write complete
ERASE/WRITE cycles
- 25 mA sink max. per pin
- 20 mA source max. per pin
programmable prescaler
oscillator for reliable operation
1997 Microchip Technology Inc.
DC - 400 ns instruction cycle
8-bit CMOS EEPROM Microcontroller
Pin Diagram
CMOS Technology:
• Low-power, high-speed CMOS EEPROM
• Fully static design
• Wide operating voltage range:
• Low power consumption:
technology
- Commercial: 2.0V to 6.0V
- Industrial:
- < 2 mA typical @ 5V, 4 MHz
- 60 A typical @ 2V, 32 kHz
- 26 A typical standby current @ 2V
RA4/T0CKI
PDIP, SOIC
RB0/INT
MCLR
RA2
RA3
RB1
RB2
RB3
V
SS
PIC16C84
2.0V to 6.0V
2
3
4
5
6
7
8
9
1
18
17
16
15
14
13
12
11
10
DS30445C-page 1
RA1
RA0
OSC1/CLKIN
OSC2/CLKOUT
V
RB7
RB6
RB5
RB4
DD

Related parts for PIC16C84-04I/P

PIC16C84-04I/P Summary of contents

Page 1

... Watchdog Timer (WDT) with its own on-chip RC oscillator for reliable operation • Code protection • Power saving SLEEP mode • Selectable oscillator options • Serial In-System Programming - via two pins 1997 Microchip Technology Inc. PIC16C84 Pin Diagram PDIP, SOIC RA2 1 18 RA3 ...

Page 2

... Data EEPROM Memory............................................................................................................................................................... 31 8.0 Special Features of the CPU ....................................................................................................................................................... 35 9.0 Instruction Set Summary.............................................................................................................................................................. 51 10.0 Development Support .................................................................................................................................................................. 67 11.0 Electrical Characteristics for PIC16C84....................................................................................................................................... 71 12.0 DC & AC Characteristics Graphs/Tables for PIC16C84 .............................................................................................................. 83 13.0 Packaging Information ................................................................................................................................................................. 97 Appendix A: Feature Improvements - From PIC16C5X To PIC16C84 ............................................................................................ 99 Appendix B: Code Compatibility - from PIC16C5X to PIC16C84.................................................................................................... 99 Appendix C: What’ ...

Page 3

... PIC16CXX microcontrollers typically achieve a 2:1 code compression and 2:1 speed improvement (at 10 MHz) over other 8-bit microcontrollers in their class. The PIC16C84 has 36 bytes of RAM, 64 bytes of Data EEPROM memory, and 13 I/O pins. A timer/counter is also available. The PIC16CXX family has special features to reduce external components, thus reducing cost, enhancing system reliability and reducing power consumption ...

Page 4

... PIC16C84 TABLE 1-1 PIC16C8X FAMILY OF DEVICES Maximum Frequency Clock of Operation (MHz) Flash Program Memory EEPROM Program Memory Memory ROM Program Memory Data Memory (bytes) Data EEPROM (bytes) Peripherals Timer Module(s) Interrupt Sources I/O Pins Features Voltage Range (Volts) Packages All PICmicro™ Family devices have Power-on Reset, selectable Watchdog Timer, selectable code protect and high I/O current capa- bility ...

Page 5

... PIC16C84 DEVICE VARIETIES A variety of frequency ranges and packaging options are available. Depending on application and production requirements the proper device option can be selected using the information in this section. When placing orders, please use the “PIC16C84 Identification System” at the back of this data sheet to specify the correct part number. There are two device “ ...

Page 6

... PIC16C84 NOTES: DS30445C-page 6 1997 Microchip Technology Inc. ...

Page 7

... This symmetrical nature and lack of ‘special optimal situations’ make programming with the PIC16CXX simple yet efficient. In addition, the learning curve is reduced significantly. The PIC16C84 has SRAM and EEPROM data memory. 1997 Microchip Technology Inc. PIC16C84 PIC16CXX devices contain an 8-bit ALU and working register ...

Page 8

... PIC16C84 FIGURE 3-1: PIC16C84 BLOCK DIAGRAM 13 Program Counter EEPROM Program Memory Level Stack (13-bit) Program Bus 14 Instruction reg 5 Power-up Timer Instruction Oscillator Decode & Start-up Timer Control Power-on Reset Watchdog Timing Timer Generation MCLR OSC2/CLKOUT OSC1/CLKIN DS30445C-page 8 Data Bus 8 RAM File Registers ...

Page 9

... TTL/ST Interrupt on change pin. Serial programming clock. (2) TTL/ST Interrupt on change pin. Serial programming data. P — Ground reference for logic and I/O pins. P — Positive supply for logic and I/O pins. I/O = Input/Output P = power TTL = TTL input ST = Schmitt Trigger input PIC16C84 DS30445C-page 9 ...

Page 10

... PIC16C84 3.1 Clocking Scheme/Instruction Cycle The clock input (from OSC1) is internally divided by four to generate four non-overlapping quadrature clocks namely Q1, Q2, Q3 and Q4. Internally, the program counter (PC) is incremented every Q1, the instruction is fetched from the program memory and latched into the instruction register in Q4. The instruction is decoded and executed during the following Q1 through Q4 ...

Page 11

... Program Memory Organization The PIC16CXX has a 13-bit program counter capable of addressing program memory space. For the PIC16C84, only the first (0000h-03FFh) are physically implemented (Figure 4-1). Accessing a loca- tion above the physically implemented address will cause a wraparound. For example, locations 20h, 420h, 820h, C20h, 1020h, 1420h, 1820h, and 1C20h will be the same instruction ...

Page 12

... PIC16C84 4.2 Data Memory Organization The data memory is partitioned into two areas. The first is the Special Function Registers (SFR) area, while the second is the General Purpose Registers (GPR) area. The SFRs control the operation of the device. Portions of data memory are banked. This is for both the SFR area and the GPR area ...

Page 13

... PORTA data direction register PORTB data direction register — EEIF WRERR WREN — Write buffer for upper 5 bits of the PC T0IE INTE RBIE T0IF PIC16C84 Value on Value on all Bit 1 Bit 0 Power-on other resets Reset (Note3) ---- ---- ---- ---- xxxx xxxx uuuu uuuu 0000 0000 ...

Page 14

... STATUS register (Table 9-2) because these instructions do not affect any status bit. Note 1: The IRP and RP1 bits (STATUS<7:6>) are not used by the PIC16C84 and should be programmed as cleared. Use of these bits as general purpose R/W bits is NOT recommended, since this may affect upward compatibility with future products ...

Page 15

... Microchip Technology Inc. Note: When the prescaler is assigned to the WDT (PSA = '1'), TMR0 has a 1:1 prescaler assignment. R/W-1 R/W-1 R/W-1 R/W-1 PSA PS2 PS1 PS0 128 PIC16C84 R = Readable bit W = Writable bit bit0 U = Unimplemented bit, read as ‘0’ Value at POR reset DS30445C-page 15 ...

Page 16

... PIC16C84 4.2.2.3 INTCON REGISTER The INTCON register is a readable and writable register which contains the various enable bits for all interrupt sources. FIGURE 4-5: INTCON REGISTER (ADDRESS 0Bh, 8Bh) R/W-0 R/W-0 R/W-0 R/W-0 GIE EEIE T0IE INTE bit7 bit 7: GIE: Global Interrupt Enable bit ...

Page 17

... Stack The PIC16C84 has an 8 deep x 13-bit wide hardware stack (Figure 4-1). The stack space is not part of either program or data space and the stack pointer is not readable or writable. The entire 13-bit PC is “pushed” onto the stack when a CALL instruction is executed or an interrupt is acknowl- edged. The stack is “ ...

Page 18

... NEXT clrf incf btfss goto CONTINUE : An effective 9-bit address is obtained by concatenating the 8-bit FSR register and the IRP bit (STATUS<7>), as shown in Figure 4-7. However, IRP is not used in the PIC16C84. 0 IRP bank select not used not used Addresses map back ...

Page 19

... I/O PORTS The PIC16C84 has two ports, PORTA and PORTB. Some port pins are multiplexed with an alternate func- tion for other features on the device. 5.1 PORTA and TRISA Registers PORTA is a 5-bit wide latch. RA4 is a Schmitt Trigger input and an open drain output. All other RA port pins have TTL input levels and full CMOS output drivers ...

Page 20

... PIC16C84 TABLE 5-1 PORTA FUNCTIONS Name Bit0 Buffer Type RA0 bit0 TTL RA1 bit1 TTL RA2 bit2 TTL RA3 bit3 TTL RA4/T0CKI bit4 ST Legend: TTL = TTL input Schmitt Trigger input TABLE 5-2 SUMMARY OF REGISTERS ASSOCIATED WITH PORTA Address Name Bit 7 Bit 6 ...

Page 21

... I/O (2) pin WR Port TTL WR TRIS Input Buffer D RB0/INT D Note 1: TRISB = '1' enables weak pull-up (if RBPU = '0' in the OPTION_REG register). RD Port 2: I/O pins have diode protection to V and PIC16C84 BLOCK DIAGRAM OF PINS RB3:RB0 V DD weak P pull-up Data Latch D Q I/O (2) pin CK TRIS Latch D Q ...

Page 22

... PIC16C84 EXAMPLE 5-1: INITIALIZING PORTB CLRF PORTB ; Initialize PORTB by ; setting output ; data latches BSF STATUS, RP0 ; Select Bank 1 MOVLW 0xCF ; Value used to ; initialize data ; direction MOVWF TRISB ; Set RB<3:0> as inputs ; RB<5:4> as outputs ; RB<7:6> as inputs TABLE 5-3 PORTB FUNCTIONS Name Bit Buffer Type ...

Page 23

... Note that: data setup time = (0.25T where T Port pin sampled here T PD Therefore, at higher clock frequencies, NOP a write followed by a read may be MOVF PORTB,W problematic. PIC16C84 PORTB<3:0> Outputs PORT latch PORT pins ---------- --------- ; 01pp ppp 11pp ppp ; 10pp ppp 11pp ppp ; ; 10pp ppp 11pp ppp ...

Page 24

... PIC16C84 NOTES: DS30445C-page 24 1997 Microchip Technology Inc. ...

Page 25

... MOVF TMR0,W MOVF TMR0,W MOVF TMR0,W MOVF TMR0,W T0+2 NT0 NT0 Read TMR0 Read TMR0 Read TMR0 Write TMR0 reads NT0 reads NT0 reads NT0 executed PIC16C84 software, by control bit PSA Data bus 8 TMR0 register PSout Set bit T0IF on Overflow PC+4 ...

Page 26

... PIC16C84 FIGURE 6-3: TMR0 TIMING: INTERNAL CLOCK/PRESCALE 1 PC MOVWF TMR0 Instruction Fetch T0 T0+1 TMR0 Instruction Execute FIGURE 6-4: TMR0 INTERRUPT TIMING OSC1 (3) CLKOUT TMR0 timer FEh 1 4 T0IF bit (INTCON<2>) GIE bit (INTCON<7>) INSTRUCTION FLOW PC PC Instruction Inst (PC) fetched Instruction Inst (PC-1) executed Note 1: T0IF interrupt fl ...

Page 27

... When assigned to the Timer0 Module, all instructions writing to the Timer0 Module (e.g., CLRF 1, MOVWF 1, 1,x ....etc.) will clear the prescaler. When BSF assigned to WDT, a CLRWDT instruction will clear the prescaler along with the Watchdog Timer. The prescaler is not readable or writable PIC16C84 (Note 4Tosc max. DS30445C-page 27 ...

Page 28

... PIC16C84 FIGURE 6-6: BLOCK DIAGRAM OF THE TMR0/WDT PRESCALER CLKOUT (= Fosc/4) 0 RA4/T0CKI pin 1 T0SE T0CS Watchdog Timer PSA WDT Enable bit Note: T0CS, T0SE, PSA, PS2:PS0 are bits in the OPTION register. DS30445C-page SYNC Cycles PSA 8-bit Prescaler 1MUX PS2:PS0 PSA WDT time-out ...

Page 29

... Timer0 module’s register T0IE INTE RBIE T0IF T0CS T0SE PSA PS2 — TRISA4 TRISA3 TRISA2 PIC16C84 CHANGING PRESCALER (TIMER0 WDT) ;Bank 0 ;Clear TMR0 ; and Prescaler ;Bank 1 ;Clears WDT ;Select new ; prescale value ;Bank 0 CHANGING PRESCALER (WDT TIMER0) ;Clear WDT and ...

Page 30

... PIC16C84 NOTES: DS30445C-page 30 1997 Microchip Technology Inc. ...

Page 31

... EEADR EEDATA holds the 8-bit data for read/write, and EEADR holds the address of the EEPROM location being accessed. PIC16C84 devices have 64 bytes of data EEPROM with an address range from 0h to 3Fh. The EEPROM data memory allows byte read and write. A byte write automatically erases the location and writes the new data (erase before write) ...

Page 32

... PIC16C84 7.2 EECON1 and EECON2 Registers EECON1 is the control register with five low order bits physically implemented. The upper-three bits are non- existent and read as '0's. Control bits RD and WR initiate read and write, respectively. These bits cannot be cleared, only set, in software. They are cleared in hardware at completion of the read or write operation ...

Page 33

... The specification is 400 A. With EEADR<7:6> cleared, the maximum is approximately 150 A. Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 — EEIF WRERR WREN WR PIC16C84 (72 ms duration) prevents for the device is DD Value on Value on all Bit 0 Power-on other resets Reset xxxx xxxx ...

Page 34

... PIC16C84 NOTES: DS30445C-page 34 1997 Microchip Technology Inc. ...

Page 35

... Address 2007h is beyond the user program memory space and it belongs to the special test/configuration memory space (2000h - 3FFFh). This space can only be accessed during programming. To find out how to program the PIC16C84, refer to PIC16C84 EEPROM Memory Programming Specifica- tion (DS30189). U-1 ...

Page 36

... A series resistor (RS) may be required for AT strip cut crystals varies with the crystal chosen. The PIC16C84 oscillator design requires the use of a parallel cut crystal. Use of a series cut crystal may give a frequency out of the crystal manufacturers specifications. When in XT modes, the device can have an external clock source to drive the OSC1/ CLKIN pin (Figure 8-3) ...

Page 37

... Cext values. The user needs to take into account variation due to tolerance of the external R and C components. Figure 8-6 shows how an R/C combination is connected to the PIC16C84. For Rext values below 2 the oscillator operation may become unstable, or stop completely. For very high Rext values (e ...

Page 38

... PIC16C84 8.3 Reset The PIC16C84 differentiates between various kinds of reset: • Power-on Reset (POR) • MCLR reset during normal operation • MCLR reset during SLEEP • WDT Reset (during normal operation) • WDT Wake-up (during SLEEP) Figure 8-7 shows a simplified block diagram of the on- chip reset circuit. The electrical specifi ...

Page 39

... PIC16C84 STATUS Register 0001 1xxx 000u uuuu 0001 0uuu 0000 1uuu uuu0 0uuu (1) uuu1 0uuu Wake-up from SLEEP: – through interrupt – through WDT time-out ...

Page 40

... PIC16C84 8.4 Power-on Reset (POR) A Power-on Reset pulse is generated on-chip when V rise is detected (in the range of 1.2V - 1.7V take advantage of the POR, just tie the MCLR pin directly (or through a resistor This will eliminate DD external RC components usually needed to create Power-on Reset. A minimum rise time for V met for this to operate properly. See Electrical Specifi ...

Page 41

... TIME-OUT SEQUENCE ON POWER-UP (MCLR NOT TIED MCLR INTERNAL POR PWRT TIME-OUT OST TIME-OUT INTERNAL RESET FIGURE 8-10: TIME-OUT SEQUENCE ON POWER-UP (MCLR NOT TIED MCLR INTERNAL POR PWRT TIME-OUT OST TIME-OUT INTERNAL RESET 1997 Microchip Technology Inc. PIC16C84 ): CASE PWRT T OST ): CASE PWRT T OST DS30445C-page 41 ...

Page 42

... PIC16C84 FIGURE 8-11: TIME-OUT SEQUENCE ON POWER-UP (MCLR TIED MCLR INTERNAL POR PWRT TIME-OUT OST TIME-OUT INTERNAL RESET FIGURE 8-12: TIME-OUT SEQUENCE ON POWER-UP (MCLR TIED MCLR INTERNAL POR PWRT TIME-OUT OST TIME-OUT INTERNAL RESET When V rises very slowly possible that the T DD has reached its fi ...

Page 43

... A brown-out is a condition where device power (V dips below its minimum value, but not to zero, and then recovers. The device should be reset in the event of a brown-out. To reset PIC16C84 devices when a brown-out occurs, and PWRTE external brown-out protection circuits may be built, as shown in Figure 8-13 and Figure 8-14. ...

Page 44

... PIC16C84 8.9 Interrupts The PIC16C84 has 4 sources of interrupt: • External interrupt RB0/INT pin • TMR0 overflow interrupt • PORTB change interrupts (pins RB7:RB4) • EEPROM write complete interrupt The interrupt control register (INTCON) records individual interrupt requests in flag bits. It also contains the individual and global interrupt enable bits. The global interrupt enable bit, GIE (INTCON< ...

Page 45

... INTF is enabled to be set anytime during the Q4-Q1 cycles. 1997 Microchip Technology Inc. Wake-up (If in SLEEP mode) Interrupt to CPU Interrupt Latency 2 PC+1 PC+1 Inst (PC+1) — Dummy Cycle Dummy Cycle Inst (PC) PIC16C84 0004h 0005h Inst (0004h) Inst (0005h) Inst (0004h) DS30445C-page 45 ...

Page 46

... PIC16C84 8.9.1 INT INTERRUPT External interrupt on RB0/INT pin is edge triggered: either rising if INTEDG bit (OPTION_REG<6>) is set, or falling, if INTEDG bit is clear. When a valid edge appears on the RB0/INT pin, the (INTCON<1>) is set. This interrupt can be disabled by clearing control bit INTE (INTCON<4>). Flag bit INTF must be cleared in software via the interrupt service routine before re-enabling this interrupt ...

Page 47

... MUX WDT Time-out Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 — CP PWRTE WDTE FOSC1 T0CS T0SE PSA PS2 PS1 PIC16C84 out and generating a device = Min., Temperature = Max., max. DD PS2:PS0 To TMR0 (Figure 6-6) PSA Value on Value on all Bit 0 Power-on other resets Reset FOSC0 1111 1111 ...

Page 48

... PIC16C84 8.12 Power-down Mode (SLEEP) A device may be powered down (SLEEP) and later powered up (Wake-up from SLEEP). 8.12.1 SLEEP The Power-down mode is entered by executing the SLEEP instruction. If enabled, the Watchdog Timer is cleared (but keeps running), the PD bit (STATUS<3>) is cleared, the TO bit (STATUS<4>) is set, and the oscillator driver is turned off ...

Page 49

... EEPROM memory may be read, but only the Data EEPROM memory may be programmed. not been FIGURE 8-19: TYPICAL IN-SYSTEM SERIAL PROGRAMMING CONNECTION External Connector Signals + CLK Data I/O PIC16C84 can be serially to V (see PIC16C84 EEPROM IHH To Normal Connections PIC16CXX MCLR/V PP RB6 RB7 Normal Connections DS30445C-page 49 ...

Page 50

... PIC16C84 NOTES: DS30445C-page 50 1997 Microchip Technology Inc. ...

Page 51

... Register bit field In the set of i User defined term (font is courier) talics 1998 Microchip Technology Inc. PIC16C84 The instruction set is highly orthogonal and is grouped into three basic categories: • Byte-oriented operations • Bit-oriented operations • Literal and control operations All instructions are executed within one single instruc- tion cycle, unless a conditional test is true or the pro- gram counter is changed as a result of an instruction ...

Page 52

... PIC16C84 TABLE 9-2 PIC16CXX INSTRUCTION SET Mnemonic, Description Operands BYTE-ORIENTED FILE REGISTER OPERATIONS ADDWF f, d Add W and f ANDWF f, d AND W with f CLRF f CLRW - COMF f, d Complement f DECF f, d Decrement f DECFSZ f, d Decrement f, Skip if 0 INCF f, d Increment f INCFSZ f, d Increment f, Skip if 0 ...

Page 53

... Operands: Operation: Status Affected: Encoding: dfff ffff Description: . Words: Cycles Cycle Activity: Write to data destination Example PIC16C84 AND Literal with W [ label ] ANDLW 255 (W) .AND. (k) ( 1001 kkkk kkkk The contents of W register are AND’ed with the eight bit literal 'k'. The . result is placed in the W register ...

Page 54

... PIC16C84 BCF Bit Clear f [ label ] BCF Syntax: f,b Operands 127 Operation: 0 (f<b>) Status Affected: None Encoding: 01 00bb bfff Description: Bit 'b' in register 'f' is cleared Words: 1 Cycles Cycle Activity Decode Read Process register 'f' Example BCF FLAG_REG, 7 Before Instruction FLAG_REG = 0xC7 After Instruction ...

Page 55

... Words Cycles: Process No-Operat Q Cycle Activity: data ion 1st Cycle Q3 Q4 No-Opera No-Operat 2nd Cycle tion ion Example PIC16C84 Call Subroutine [ label ] CALL 2047 (PC)+ 1 TOS, k PC<10:0>, (PCLATH<4:3>) PC<12:11> None 10 0kkk kkkk kkkk Call Subroutine. First, return address (PC+1) is pushed onto the stack. The eleven bit immediate address is loaded into PC bits < ...

Page 56

... PIC16C84 CLRF Clear f Syntax: [ label ] CLRF f Operands 127 Operation: 00h ( Status Affected: Z Encoding: 00 0001 1fff Description: The contents of register 'f' are cleared and the Z bit is set. Words: 1 Cycles Cycle Activity Decode Read Process register 'f' Example CLRF FLAG_REG Before Instruction FLAG_REG After Instruction ...

Page 57

... Cycles: Q Cycle Activity: 0x13 If Skip: 0x13 0xEC Example ffff . Q3 Q4 Write to data destination 0x01 0 0x00 1 PIC16C84 Decrement f, Skip label ] DECFSZ f 127 d [0,1] ( (destination); skip if result = 0 None 00 1011 dfff ffff The contents of register 'f' are decre- mented the result is placed in the W register the result is placed back in register 'f' ...

Page 58

... PIC16C84 GOTO Unconditional Branch Syntax: [ label ] GOTO k Operands 2047 Operation: k PC<10:0> PCLATH<4:3> PC<12:11> Status Affected: None Encoding: 10 1kkk Description: GOTO is an unconditional branch. The eleven bit immediate value is loaded into PC bits <10:0>. The upper bits of PC are loaded from PCLATH<4:3>. GOTO is a two cycle instruction. ...

Page 59

... Q Cycle Activity: instruc- CY Example Q3 Q4 Process Write to data destination Q3 Q4 No-Operati tion on CNT, 1 LOOP PIC16C84 Inclusive OR Literal with W [ label ] IORLW 255 (W) .OR 1000 kkkk kkkk The contents of the W register is OR’ed with the eight bit literal 'k'. The . result is placed in the W register ...

Page 60

... PIC16C84 IORWF Inclusive OR W with f [ label ] Syntax: IORWF Operands 127 d [0,1] Operation: (W) .OR. (f) (destination) Status Affected: Z Encoding: 00 0100 dfff Description: Inclusive OR the W register with regis- ter 'f the result is placed in the W register the result is placed back in register 'f'. Words: 1 Cycles Cycle Activity: ...

Page 61

... Encoding: Description No-Operat tion ion Words: Cycles: Q Cycle Activity: 1st Cycle 2nd Cycle Example 0010 PIC16C84 Return from Interrupt [ label ] RETFIE None TOS PC, 1 GIE None 00 0000 0000 1001 Return from Interrupt. Stack is POPed and Top of Stack (TOS) is loaded in the PC ...

Page 62

... PIC16C84 RETLW Return with Literal in W Syntax: [ label ] RETLW k Operands 255 Operation: k (W); TOS PC Status Affected: None Encoding: 11 01xx Description: The W register is loaded with the eight bit literal 'k'. The program counter is loaded from the top of the stack (the return address). This is a two cycle instruction ...

Page 63

... Description: Words: Cycles Cycle Activity: Process Write to data destination Example 1110 0110 0 1110 0110 1100 1100 1 PIC16C84 Rotate Right f through Carry [ label ] RRF f 127 d [0,1] See description below C 00 1100 dfff ffff The contents of register 'f' are rotated one bit to the right through the Carry Flag ...

Page 64

... PIC16C84 SLEEP [ label ] Syntax: SLEEP Operands: None Operation: 00h WDT, 0 WDT prescaler Status Affected: TO, PD Encoding: 00 0000 Description: The power-down status bit cleared. Time-out status bit set. Watchdog Timer and its prescaler are cleared. The processor is put into SLEEP mode with the oscillator stopped. See Section 14 ...

Page 65

... Q4 Q Cycle Activity: Process Write to data destination Example TRIS Syntax: Operands: Operation: Status Affected: None Encoding: Description: Words: Cycles: Example PIC16C84 Swap Nibbles label ] SWAPF f 127 d [0,1] (f<3:0>) (destination<7:4>), (f<7:4>) (destination<3:0>) None 00 1110 dfff ffff The upper and lower nibbles of register 'f' are exchanged ...

Page 66

... PIC16C84 XORLW Exclusive OR Literal with W [ label ] Syntax: XORLW k Operands 255 Operation: (W) .XOR Status Affected: Z Encoding: 11 1010 Description: The contents of the W register are XOR’ed with the eight bit literal 'k'. The result is placed in the W regis- ter. Words: 1 Cycles Cycle Activity Decode Read ...

Page 67

... PICSTART Plus supports all PIC12CXXX, PIC14C000, PIC16C5X, PIC16CXXX and PIC17CXX devices with pins. Larger pin count devices such as the PIC16C923 and PIC16C924 may be supported with an adapter socket. has been PIC16C84 through Pentium and max for maximum reliability. It has PIC14C000, PIC16C5X, ...

Page 68

... PIC16C84 10.6 PICDEM-1 Low-Cost PICmicro Demonstration Board The PICDEM simple board which demonstrates the capabilities of several of Microchip’s microcontrol- lers. The microcontrollers supported are: PIC16C5X (PIC16C54 to PIC16C58A), PIC16C61, PIC16C62X, PIC16C71, PIC16C8X, PIC17C42, PIC17C43 and PIC17C44. All necessary hardware and software is included to run basic demo programs. The users can ...

Page 69

... EE OQ Microchips HCS Secure Data Products. The HCS eval- uation kit includes an LCD display to show changing codes, a decoder to decode transmissions, and a pro- gramming interface to program test transmitters. demon- PIC16C84 – Application Code and secure serials. Disk is included to aid in trade- DS30445A - page 69 ...

Page 70

... PIC16C84 TABLE 10-1: DEVELOPMENT TOOLS FROM MICROCHIP Products Emulator DS30445A - page 70 Tools Software Programmers Boards Demo 1997 Microchip Technology Inc. ...

Page 71

... ELECTRICAL CHARACTERISTICS FOR PIC16C84 Absolute Maximum Ratings † Ambient temperature under bias.............................................................................................................- +125 C Storage temperature .............................................................................................................................. - +150 C Voltage on V with respect to V ............................................................................................................ -0.3 to +7. (2) Voltage on MCLR with respect to V Voltage on all other pins with respect to V (1) Total power dissipation .....................................................................................................................................800 mW Maximum current out of V pin ...

Page 72

... Freq: 200 kHz max. The shaded sections indicate oscillator selections which are tested for functionality, but not for MIN/MAX specifications recommended that the user select the device type that ensures the specifications required. DS30445C-page 72 PIC16C84- 4. 2.0V to 6.0V ...

Page 73

... DC CHARACTERISTICS: PIC16C84-04 (Commercial, Industrial) PIC16C84-10 (Commercial, Industrial) DC Characteristics Power Supply Pins Sym Characteristic Parame- ter No. D001 V Supply Voltage DD D001A D002 V RAM Data Retention DR (1) Voltage D003 V V start voltage to POR DD ensure internal Power-on Reset signal D004 S V rise rate to ensure ...

Page 74

... PIC16C84 11.2 DC CHARACTERISTICS PIC16LC84-04 (Commercial, Industrial) DC Characteristics Power Supply Pins Sym Characteristic Parameter No. D001 V Supply Voltage DD D002 V RAM Data Retention DR (1) Voltage D003 V V start voltage to POR DD ensure internal Power-on Reset signal D004 S V rise rate to ensure VDD DD internal Power-on Reset signal ...

Page 75

... Note oscillator configuration, the OSC1/CLKIN pin is a Schmitt Trigger input not recommended that the PIC16C84 be driven with external clock in RC mode. 2: The leakage current on the MCLR pin is strongly dependent on the applied voltage level. The specified levels represent normal operating conditions. Higher leakage current may be measured at different input voltages. 3: Negative current is defi ...

Page 76

... PIC16C84 11.4 DC CHARACTERISTICS: PIC16C84-04 (Commercial, Industrial) PIC16C84-10 (Commercial, Industrial) PIC16LC84-04 (Commercial, Industrial) DC Characteristics All Pins Except Power Supply Pins Sym Characteristic Parameter No. Capacitive Loading Specs on Output Pins D100 C OSC2/CLKOUT pin OSC2 D101 C All I/O pins and OSC2 IO (RC mode) Data EEPROM Memory ...

Page 77

... Microchip Technology Inc. T Time os,osc OSC1 ost oscillator start-up timer pwrt power-up timer rbt RBx pins t0 T0CKI wdt watchdog timer P Period R Rise V Valid Z Hi-impedance XTAL DD (High XTAL DD (Low I/O Port Measurement Points Load Condition 2 Pin PIC16C84 2.0 V (High) DD 0.2 V (Low DS30445C-page 77 ...

Page 78

... PIC16LC84-04 ns XT, RC osc PIC16LC84-04 ns XT, RC osc PIC16C84- osc PIC16C84- osc PIC16LC84- osc PIC16LC84- osc PIC16C84- osc PIC16LC84- osc PIC16C84- osc PIC16C84- osc PIC16LC84- osc PIC16LC84- osc PIC16C84- osc PIC16LC84- osc PIC16C84- osc PIC16C84- osc PIC16LC84- osc PIC16C84-10 1997 Microchip Technology Inc. ...

Page 79

... PIC16C84 — PIC16LC84 — to Port out valid — PIC16C84 0.30T + PIC16LC84 0.30T + PIC16C84 — PIC16LC84 — TBD TBD PIC16C84 — PIC16LC84 — PIC16C84 — PIC16LC84 — PIC16C84 20 * PIC16LC84 55 * PIC16C84 20 * PIC16LC84 OSC PIC16C84 new value Typ† Max Units Conditions Note 1 ...

Page 80

... PIC16C84 FIGURE 11-5: RESET, WATCHDOG TIMER, OSCILLATOR START-UP TIMER AND POWER-UP TIMER TIMING V DD MCLR Internal POR 33 PWRT Time-out 32 OSC Time-out Internal RESET Watchdog Timer RESET I/O Pins TABLE 11-5 RESET, WATCHDOG TIMER, OSCILLATOR START-UP TIMER AND POWER-UP TIMER REQUIREMENTS Parameter ...

Page 81

... Microchip Technology Inc Min Typ† Max Units Conditions No Prescaler 0. — CY With Prescaler 50 * — — No Prescaler 0. — CY With Prescaler 50 * — — — PIC16C84 — ns — ns 2.0V V 3.0V DD — ns 3.0V V 6.0V DD — ns — ns 2.0V V 3.0V DD — ns 3.0V V 6.0V DD — prescale value (2, 4, ...

Page 82

... PIC16C84 NOTES: DS30445C-page 82 1997 Microchip Technology Inc. ...

Page 83

... DC & AC CHARACTERISTICS GRAPHS/TABLES FOR PIC16C84 The graphs and tables provided in this section are for design guidance and are not tested or guaranteed. In some graphs or tables, the data presented are outside specified operating range (i.e., outside specified V range). This is for information only and devices are guaranteed to operate properly only within the specified range. ...

Page 84

... PIC16C84 FIGURE 12-2: TYPICAL RC OSCILLATOR FREQUENCY vs. V 5.5 5.0 4.5 4.0 3.5 3.0 2.5 2.0 1.5 1.0 0.5 0.0 2.0 DS30445C-page 84 (Cext = 20 pF) DD Rext = 3.3k Rext = Rext = 10k Rext = 100k 2.5 3.0 3.5 4.0 4.5 5.0 5.5 V (Volts) DD 6.0 1997 Microchip Technology Inc. ...

Page 85

... Microchip Technology Inc. (Cext = 100 pF) DD Rext = 3.3k Rext = 5k Rext = 10k Rext = 100k 2.5 3.0 3.5 4.0 4.5 5.0 5.5 V (Volts) DD (Cext = 300 pF Rext = 3.3k Rext = 5k Rext = 10k Rext = 100k 2.5 3.0 3.5 4.0 4.5 5.0 5.5 V (Volts) DD PIC16C84 6.0 6.0 DS30445C-page 85 ...

Page 86

... PIC16C84 FIGURE 12-5: TYPICAL I vs 2.0 2.5 FIGURE 12-6: TYPICAL I vs 2.0 2.5 DS30445C-page 86 WATCHDOG DISABLED (25˚C) DD 3.0 3.5 4.0 4.5 V (Volts) DD WATCHDOG ENABLED (25˚C) DD 3.0 3.5 4.0 4.5 V (Volts) DD 5.0 5.5 6.0 5.0 5.5 6.0 1997 Microchip Technology Inc. ...

Page 87

... Watchdog Timer logic which increases with lower temperature. At -40 C, the latter dominates explaining the apparently anomalous behavior. 1997 Microchip Technology Inc. WATCHDOG DISABLED DD 3.0 3.5 4.0 4.5 V (Volts) DD WATCHDOG ENABLED* DD 3.0 3.5 4.0 4.5 V (Volts) DD PIC16C84 5.0 5.5 6.0 5.0 5.5 6.0 DS30445C-page 87 ...

Page 88

... PIC16C84 FIGURE 12-9: V (INPUT THRESHOLD VOLTAGE) OF I/O PINS vs 2.0 1.8 1.6 1.4 1.2 1.0 0.8 0.6 2.5 3.0 FIGURE 12-10: V (INPUT THRESHOLD VOLTAGE) OF OSC1 INPUT (IN XT, HS, AND LP MODES 3.4 3.2 3.0 2.8 2.6 2.4 2.2 2.0 1.8 1.6 1.4 1.2 1 ...

Page 89

... FIGURE 12-11 MCLR, T0CKI and OSC1 (IN RC MODE) vs 5.0 4.5 4 min (- + 3.5 3.0 2.5 2.0 1.5 1.0 0.5 0.0 2.0 2.5 3.0 1997 Microchip Technology Inc max (- + typ ( typ ( min (- + 3.5 4.0 4.5 V (Volts) DD PIC16C84 DD , max (- +85 C) 5.0 5.5 6.0 DS30445C-page 89 ...

Page 90

... PIC16C84 FIGURE 12-12: TYPICAL I vs. FREQ (EXT CLOCK, 25˚C) DD 10,000 1,000 100 6.0V 5.5V 5.0V 4.5V 4.0V 3.5V 3.0V 2.5V 2.0V 10 10k 100k FIGURE 12-13: MAXIMUM I vs. FREQ (EXT CLOCK, -40˚ TO +85˚C) DD 10,000 1,000 6.0V 5.5V 5.0V 4.5V 4.0V 100 3 ...

Page 91

... Microchip Technology Inc. DD Typ Min 3.0 3.5 4.0 4.5 V (Volts) DD Max @ -40 C 3.0 3.5 4.0 V (Volts) DD PIC16C84 5.0 5.5 6.0 DD Typ @ 25 C Min @ 85 C 4.5 5.0 5.5 DS30445C-page 91 ...

Page 92

... PIC16C84 FIGURE 12-16: TRANSCONDUCTANCE (gm OSCILLATOR vs. V 250 225 200 175 150 125 100 2.0 2.5 FIGURE 12-17: TRANSCONDUCTANCE (gm OSCILLATOR vs. V 2000 1800 1600 1400 1200 1000 800 600 400 200 0 2.0 2.5 DS30445C-page 92 Max @ -40 C 3.0 3.5 4.0 4.5 V (Volts) DD Max @ - ...

Page 93

... Max @ -40 C -16 -18 0.0 0.5 FIGURE 12-19 -10 -15 -20 -25 Typ @ 25 C -30 -35 -40 -45 0.0 0.5 1.0 1997 Microchip Technology Inc. 1.0 1.5 2.0 V (Volts) OH Min @ 85 C 1.5 2.0 2.5 3.0 3.5 V (Volts) OH PIC16C84 2.5 3.0 Max @ -40 C 4.0 4.5 5.0 DS30445C-page 93 ...

Page 94

... PIC16C84 FIGURE 12-20 0.0 0.5 FIGURE 12-21 0.0 0.5 DS30445C-page 94 Max. -40 C Typ Min. +85 C 1.0 1.5 2.0 V (Volts) OL Max @ -40 C 1.0 1.5 2.0 V (Volts) OL 2.5 3.0 Typ @ 25 C Min @ +85 C 2.5 3.0 1997 Microchip Technology Inc. ...

Page 95

... All capacitance values are typical part to part variation of 25% (three standard deviations) should be taken into account. 1997 Microchip Technology Inc. 3.0 3.5 4.0 4.5 5.0 V (Volts) DD Typical Capacitance (pF) 18L PDIP 5.0 5.0 17.0 4.0 4.3 3.2 PIC16C84 5.5 6.0 6.5 18L SOIC 4.3 4.3 17.0 3.5 3.5 2.8 DS30445C-page 95 ...

Page 96

... PIC16C84 NOTES: DS30445C-page 96 1997 Microchip Technology Inc. ...

Page 97

... D 0.890 0.895 0.900 ‡ 0.245 0.255 0.265 E E1 0.230 0.250 0.270 eB 0.310 0.349 0.387 PIC16C84 MILLIMETERS MIN NOM MAX 7.62 18 2.54 0.33 0.46 0.58 1.40 1.52 1.65 0.00 0.13 0.25 0.13 0.25 0.38 2.79 3.94 3.94 1.91 2 ...

Page 98

... PIC16C84 13.2 K04-051 18-Lead Plastic Small Outline (SO) – Wide, 300 mil Units Dimension Limits Pitch p Number of Pins n Overall Pack. Height A Shoulder Height A1 Standoff A2 ‡ Molded Package Length D ‡ Molded Package Width E Outside Dimension E1 Chamfer Distance X Shoulder Radius R1 Gull Wing Radius R2 Foot Length ...

Page 99

... (data in/out). 1997 Microchip Technology Inc. APPENDIX B: CODE COMPATIBILITY To convert code written for PIC16C5X to PIC16C84, the user should take the following steps: 1. Remove any program memory page select operations (PA2, PA1, PA0 bits) for CALL, GOTO. 2. Revisit any computed jump operations (write add to PC, etc ...

Page 100

... APPENDIX C: WHAT’S NEW IN THIS DATA SHEET No new information has been added to this data sheet. For information on upgrade devices from the PIC16C84, please refer to the PIC16F8X data sheet. DS30445C-page 100 APPENDIX D: WHAT’S CHANGED IN THIS DATA SHEET Here’s what’s changed in this data sheet: 1 ...

Page 101

... APPENDIX E: CONVERSION CONSIDERATIONS - PIC16C84 TO PIC16F83/F84 AND PIC16CR83/CR84 Considerations for converting from the PIC16C84 to the PIC16F84 are listed in the table below. These con- siderations apply to converting from the PIC16C84 to the PIC16F83 (same as PIC16F84 except for program Difference The polarity of the PWRTE bit has been reversed ...

Page 102

... PIC16C84 NOTES: DS30445C-page 102 1997 Microchip Technology Inc. ...

Page 103

... In-Circuit Serial Programming ...................................... 35, 49 INDF ................................................................................... 39 Instruction Format .............................................................. 51 Instruction Set ADDLW ...................................................................... 53 ADDWF ...................................................................... 53 ANDLW ...................................................................... 53 ANDWF ...................................................................... 53 BCF ............................................................................ 54 BSF ............................................................................ 54 BTFSC ....................................................................... 54 BTFSS ....................................................................... 55 CALL .......................................................................... 55 CLRF .......................................................................... 56 CLRW ........................................................................ 56 1997 Microchip Technology Inc. PIC16C84 CLRWDT ................................................................... 56 COMF ........................................................................ 57 DECF ......................................................................... 57 DECFSZ .................................................................... 57 GOTO ........................................................................ 58 INCF .......................................................................... 58 INCFSZ ...................................................................... 59 IORLW ....................................................................... 59 IORWF ....................................................................... 60 MOVF ........................................................................ 60 MOVLW ..................................................................... 60 MOVWF ..................................................................... 60 NOP ........................................................................... 61 OPTION ..................................................................... 61 RETFIE ...................................................................... 61 RETLW ...................................................................... 62 RETURN ...

Page 104

... PIC16C84 PCL .............................................................................. 17, 39 PCLATH ....................................................................... 17 .......................................................................... 14, 38, 43 PICDEM-1 Low-Cost PICmicro Demo Board ..................... 68 PICDEM-2 Low-Cost PIC16CXX Demo Board .................. 68 PICDEM-3 Low-Cost PIC16CXXX Demo Board ................ 68 PICMASTER In-Circuit Emulator ..................................... 67 PICSTART Plus Entry Level Development System ........ 67 Pinout Descriptions .............................................................. 9 POR ................................................................................... 40 Oscillator Start-up Timer (OST) ........................... 35, 40 Power-on Reset (POR) .................................. 35, 39, 40 Power-up Timer (PWRT) ...

Page 105

... International Business Machines Corp. Pentium is a trade- mark of Intel Corporation. Windows is a trademark and MS-DOS, Microsoft Windows are registered trademarks of Microsoft Corporation. CompuServe is a registered trademark of CompuServe Incorporated. All other trademarks mentioned herein are the property of their respective companies. Preliminary PIC16C84 DS30445C-page 105 ...

Page 106

... Telephone: (_______) _________ - _________ Application (optional): Would you like a reply? Y Device: PIC16C84 Questions: 1. What are the best features of this document? 2. How does this document meet your hardware and software development needs you find the organization of this data sheet easy to follow? If not, why? 4 ...

Page 107

... BBS or WWW site can be found in the On-Line Support section of this data sheet.) 1997 Microchip Technology Inc. /XX XXX Examples: Package Pattern a) PIC16C84 -04/P 301 = Commercial temp., PDIP package, 4MHz, normal V limitis, QTP pattern #301. (3) b) PIC16LC84 - 04I/SO = Industrial temp., (3) SOIC package, 200kHz, Extended V limits ...

Page 108

... Information contained in this publication regarding device applications and the like is intended for suggestion only and may be superseded by updates. No representation or warranty is given and no liability is assumed by Microchip Technology Incorporated with respect to the accuracy or use of such information, or infringement of patents or other intellectual property rights arising from such use or otherwise. Use of Microchip’s products as critical components in life support systems is not authorized except with express written approval by Microchip ...

Related keywords