Electronic Components Datasheet Search
  New Zealand  ▼
ALLDATASHEET.CO.NZ

X  

PIC16F18344-I/SS Datasheet(PDF) 83 Page - Microchip Technology

Part # PIC16F18344-I/SS
Description  Full-Featured, Low Pin Count Microcontrollers with XLP
PDF  489 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
Manufacturer  MICROCHIP [Microchip Technology]
Direct Link  http://www.microchip.com
Logo MICROCHIP - Microchip Technology

PIC16F18344-I/SS Datasheet(HTML) 83 Page - Microchip Technology

Back Button PIC16F18344-I/SS Datasheet HTML 79Page - Microchip Technology PIC16F18344-I/SS Datasheet HTML 80Page - Microchip Technology PIC16F18344-I/SS Datasheet HTML 81Page - Microchip Technology PIC16F18344-I/SS Datasheet HTML 82Page - Microchip Technology PIC16F18344-I/SS Datasheet HTML 83Page - Microchip Technology PIC16F18344-I/SS Datasheet HTML 84Page - Microchip Technology PIC16F18344-I/SS Datasheet HTML 85Page - Microchip Technology PIC16F18344-I/SS Datasheet HTML 86Page - Microchip Technology PIC16F18344-I/SS Datasheet HTML 87Page - Microchip Technology Next Button
Zoom Inzoom in Zoom Outzoom out
 83 / 489 page
background image
 2015-2017 Microchip Technology Inc.
DS40001800C-page 83
PIC16(L)F18324/18344
7.3
Clock Switching
The system clock source can be switched between
external and internal clock sources via software using
the New Oscillator Source (NOSC) and New Divider
Selection Request (NDIV) bits of the OSCCON1
register. The following clock sources can be selected:
• External Oscillator (EXTOSC)
• High-Frequency Internal Oscillator (HFINTOSC)
• Low-Frequency Internal Oscillator (LFINTOSC)
• Secondary Oscillator (SOSC)
• EXTOSC with 4x PLL
• HFINTOSC with 2x PLL
7.3.1
NEW OSCILLATOR SOURCE
(NOSC) AND NEW DIVIDER
SELECTION REQUEST (NDIV) BITS
The New Oscillator Source (NOSC) and New Divider
Selection Request (NDIV) bits of the OSCCON1
register select the system clock source and frequencies
that are used for the CPU and peripherals.
When the new values of NOSC<2:0> and NDIV<3:0>
are written to OSCCON1, the current oscillator
selection will continue to operate as the system clock
while waiting for the new source to indicate that it is
stable and ready. In some cases, the newly requested
source may already be in use, and is ready
immediately. In the case of a divider-only change, the
new and old sources are the same and are ready
immediately. The device may enter Sleep while waiting
for the switch as described in Section 7.3.3 “Clock
Switch and Sleep”
.
When the new oscillator is ready, the New Oscillator is
Ready (NOSCR) bit of OSCCON3 and the Clock
Switch Interrupt Flag (CSWIF) bit of PIR3 become set
(CSWIF = 1). If Clock Switch Interrupts are enabled
(CSWIE = 1), an interrupt will be generated at that time.
The Oscillator Ready (ORDY) bit of OSCCON3 can
also be polled to determine when the oscillator is ready
in lieu of an interrupt.
If the Clock Switch Hold (CSWHOLD) bit of OSCCON3
is clear, the oscillator switch will occur when the New
Oscillator Ready bit (NOSCR) is set and the interrupt (if
enabled) will be serviced at the new oscillator setting.
If CSWHOLD is set, the oscillator switch is suspended,
while execution continues using the current (old) clock
source. When the NOSCR bit is set, software should:
• set CSWHOLD = 0 so the switch can complete, or
• copy COSC into NOSC<2:0> to abandon the
switch.
If DOZE is in effect, the switch occurs on the next clock
cycle, whether or not the CPU is operating during that
cycle.
Changing the clock post-divider without changing the
clock source (i.e., changing FOSC from 1 MHz to 2
MHz) is handled in the same manner as a clock source
change, as described previously. The clock source will
already be active, so the switch is relatively quick.
CSWHOLD must be clear (CSWHOLD = 0) for the
switch to complete.
The current COSC and CDIV are indicated in the
OSCCON2 register up to the moment when the switch
actually occurs, at which time OSCCON2 is updated
and ORDY is set. NOSCR is cleared by hardware to
indicate that the switch is complete.
7.3.2
PLL INPUT SWITCH
Switching between the PLL and any non-PLL source is
managed as described above. The input to the PLL is
established when NOSC<2:0> selects the PLL, and
maintained by the COSC setting.
When NOSC<2:0> and COSC select the PLL with
different input sources, the system continues to run
using the COSC setting, and the new source is enabled
per NOSC<2:0>. When the new oscillator is ready (and
CSWHOLD = 0), system operation is suspended while
the PLL input is switched and the PLL acquires lock.
7.3.3
CLOCK SWITCH AND SLEEP
If OSCCON1 is written with a new value and the device
is put to Sleep before the switch completes, the switch
will not take place and the device will enter Sleep
mode.
When the device wakes from Sleep and the
CSWHOLD bit is clear, the device will wake with the
‘new’ clock active, and the Clock Switch Interrupt Flag
bit (CSWIF) will be set.
When the device wakes from Sleep and the
CSWHOLD bit is set, the device will wake with the ‘old’
clock active and the new clock will be requested again.



Html Pages

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100  ...More


Datasheet Download

Go To PDF Page


Link URL



Does ALLDATASHEET help your business so far?  [ DONATE ] 

About Alldatasheet   |   Advertisement   |   Contact us   |   Privacy Policy   |   Link to Datasheet    |   Link Exchange   |   Manufacturer List
All Rights Reserved©Alldatasheet.com


Mirror Sites
English : Alldatasheet.com  |   English : Alldatasheet.net  |   Chinese : Alldatasheetcn.com  |   German : Alldatasheetde.com  |   Japanese : Alldatasheet.jp
Russian : Alldatasheetru.com  |   Korean : Alldatasheet.co.kr  |   Spanish : Alldatasheet.es  |   French : Alldatasheet.fr  |   Italian : Alldatasheetit.com
Portuguese : Alldatasheetpt.com  |   Polish : Alldatasheet.pl  |   Vietnamese : Alldatasheet.vn
Indian : Alldatasheet.in  |   Mexican : Alldatasheet.com.mx  |   British : Alldatasheet.co.uk  |   New Zealand : Alldatasheet.co.nz
Family Site : ic2ic.com  |   icmetro.com