PIC16C662/JW Microchip Technology, PIC16C662/JW Datasheet - Page 45

IC MCU EPROM 4KX14 COMP 40CDIP

PIC16C662/JW

Manufacturer Part Number
PIC16C662/JW
Description
IC MCU EPROM 4KX14 COMP 40CDIP
Manufacturer
Microchip Technology
Series
PIC® 16Cr
Datasheets

Specifications of PIC16C662/JW

Core Processor
PIC
Core Size
8-Bit
Speed
20MHz
Peripherals
Brown-out Detect/Reset, LED, POR, WDT
Number Of I /o
33
Program Memory Size
7KB (4K x 14)
Program Memory Type
EPROM, UV
Ram Size
176 x 8
Voltage - Supply (vcc/vdd)
4 V ~ 6 V
Oscillator Type
External
Operating Temperature
0°C ~ 70°C
Package / Case
40-CDIP (0.600", 15.24mm) Window
Lead Free Status / RoHS Status
Contains lead / RoHS non-compliant
Eeprom Size
-
Data Converters
-
Connectivity
-

Available stocks

Company
Part Number
Manufacturer
Quantity
Price
Part Number:
PIC16C662/JW
Manufacturer:
NS
Quantity:
98
6.3.1
The prescaler assignment is fully under software con-
trol, i.e., it can be changed “on the fly” during program
execution.
EXAMPLE 6-1:
TABLE 6-1:
Address Name
01h
0Bh/8Bh INTCON
81h
85h
Legend: x = unknown, u = unchanged, - = unimplemented locations read as '0'. Shaded cells are not used by Timer0.
1996 Microchip Technology Inc.
Note:
BCF
CLRF
BSF
CLRWDT
MOVLW
MOVWF
BCF
SWITCHING PRESCALER ASSIGNMENT
TMR0
OPTION RBPU INTEDG
TRISA
STATUS, RP0
TMR0
STATUS, RP0
b'xxxx1xxx'
OPTION_REG
STATUS, RP0
To avoid an unintended device RESET, the
following instruction sequence (shown in
Example 6-1) must be executed when
changing the prescaler assignment from
Timer0 to the WDT. This precaution must
be followed even if the WDT is disabled.
REGISTERS ASSOCIATED WITH TIMER0
Timer0 module’s register
CHANGING PRESCALER
(TIMER0 WDT)
Bit 7
GIE
;Bank 0
;Clear TMR0 & Prescaler
;Bank 1
;Clears WDT
;Select new prescale
;value & WDT
;Bank 0
PEIE
Bit 6
TRISA5
T0CS
Bit 5
T0IE
TRISA4 TRISA3 TRISA2 TRISA1 TRISA0 --11 1111
T0SE
INTE
Bit 4
Preliminary
PIC16C64X & PIC16C66X
RBIE
Bit 3
PSA
To change prescaler from the WDT to the Timer0 mod-
ule, use the sequence shown in Example 6-2.
EXAMPLE 6-2:
CLRWDT
BSF
MOVLW
MOVWF
BCF
Bit 2
T0IF
PS2
INTF
Bit 1
PS1
STATUS, RP0 ;Bank 1
b'xxxx0xxx' ;Select TMR0, new
OPTION_REG
STATUS, RP0 ;Bank 0
CHANGING PRESCALER
(WDT TIMER0)
RBIF
Bit 0
PS0
;Clear WDT and
;prescaler
;prescale value and
;clock source
xxxx xxxx
0000 000x
1111 1111
Value on:
POR,
BOR
DS30559A-page 45
other resets
Value on all
uuuu uuuu
--11 1111
0000 000u
1111 1111

Related parts for PIC16C662/JW