PIC & S12X MICROCONTROLLER
R.PRASATH Page 2
The internal oscillator selection is to
synchronize the clock
with the external oscillator, theinternal oscillator types are;
Low Power crystal (LP), crystal (XT), High speed crystal (HS), Resistor/Capacitor (RC)
timing insensitive and low cost applications
we will use RC oscillator option whichgenerates the frequency according to the values of REXT and CEXT.20.
Power on Reset (POR)
pulse is generated when VDD rise is in range 1.2 to 1.7v.21.
Power up timer (PWRT)
provides a 72 ms nominal timeout generated using internal RCoscillator after POR. It is designed so as to maintain reset until power supply stabilizes.22.
Oscillator Start up timer (OST)
provides a 1024 Oscillator cycle delay using external oscillatorafter the PWRT.23.
Brown out Reset (BOR)
will reset the device when VDD falls below VBOR (4v) for a certain timeinterval (TBOR).24.
Watch dog timer
is a free running On chip RC oscillator which does not depend upon externalcomponents will reset the device when WDT overflow was occurred. We can prevent WDT resetby clearing the WDT (
) before it expires.25.
Using WDT we can realize periodic interrupt from the range
18ms to 2.3 seconds
The methods to wake up the device from sleep mode(low current power down mode) are;
External Reset input on MCLR pin
WDT overflow reset.
Interrupt from INT pin, PORTB read change interrupt, EEPROM write complete
Timer is used to generate accurate
pulses and delay
parallely without disturbing the exec speed.28.
difference between timer and counter
is, Timer counts the internal clock pulses generatedto execute the instructions and counter counts the external clock pulse given to count thearrivals of the event.29.
Prescalar Assignment (PSA) bit in Option register
we can assign the prescalar values foreither Timer0 or WDT.30.
synchronized counter mode
, external clock pulse is synchronized with internal phaseclocks. So during Sleep it won’t work because of shut down of internal clock generation.31.
Asynchronous counter mode
, counter continues to increment asynchronous withinternal phase clocks. So during sleep it will work because of the absence of synchronization.32.
The Current value of the 16 bit timer1 (TMRH: TMRL) is captured to CCPR1 (CCPR1H:CCPR1L)and interrupts can be generated, when a signal is detected in RC2/CCP1 pin .(