PIC16C5X clock oscillator

Publisher:脑力舞者Latest update time:2015-04-24 Source: laoguKeywords:PIC16C5X Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere
  
The PIC16C5X series has four oscillator options: standard crystal/ceramic oscillator (XT), low frequency low power oscillator (LP), high speed oscillator (HS) and resistor-capacitor oscillator (RC). In EPROM-type microcontrollers and microcontrollers with the suffix RC, the oscillator circuit can be selected by programming the configuration bit EPROM. The oscillator in the QTP microcontroller is set at the factory and can be tested by specific methods.

    [1]. Quartz crystal oscillator.

    In the XT, HS or LP mode of the PIC16C5X microcontroller, OSC1 and OSC2 require an external quartz crystal or ceramic oscillator, as shown in the figure below. The HS oscillator requires a series resistor Rs, and the value of Rs ranges from 100 ohms to 1k ohms.

 
    When the microcontroller uses a quartz crystal oscillator or a ceramic oscillator, the capacitor used and the frequency generated are different. A large capacitor value is conducive to oscillation stability, but it prolongs the start-up time.

    When using a ceramic oscillator, the selected capacitor capacity and the generated oscillation frequency are shown in Table 1. When using a quartz oscillator, the selected capacitor capacity and the generated oscillation frequency are shown in Table 2.
 
  Table 1 Ceramic oscillators and matching capacitors
Oscillator Type Ceramic oscillator frequency Capacitance (C1=C2)/pF
XT 455kHz 150-330
2.0MHz 20-330
4.0MHz 20-330
HS 8.0MHz 20-330
 
    [2]. RC oscillator.

    For applications where timing accuracy is not required, RC oscillators can significantly reduce costs. The frequency of the RC oscillator is related to the power supply voltage VDD, the external resistor REXT, the external capacitor CEXT, and the operating temperature. Due to inconsistencies in parameters during the manufacturing process, the frequency of the oscillator may be different for each microcontroller. In addition, the different lead distribution capacitances of different packaging methods will also affect the oscillation frequency, which is particularly obvious when the value of the external capacitor CEXT is small. Users also need to consider the errors of the external resistors REXT and CEXT used.
 
  Table 2 Quartz crystal oscillator and matching capacitor
Oscillator Type Oscillator frequency Capacitance C1/pF Capacitance C2/pF
LP 32kHz 15-30 15
XT 100kHz 15-30 200-200
200kHz 15-30 100-200
455kHz 15-30 15-100
1MHz 15-30 15-30
2MHz 15 15
4MHz 15 15
HS 4MHz 15 15
8MHz 15 15
20MHz 15 15
 
    Figure 2 is the wiring diagram of the RC oscillation circuit. When the value of the external resistor REXT is less than 2.2kΩ, the oscillator may not work stably or even fail to oscillate. When the resistance REXT is too large (such as greater than 1MΩ), the oscillator is easily affected by noise, humidity and leakage interference and becomes unstable. We recommend that the value range of REXT be 5-100kΩ.

    The oscillator can work without an external capacitor, but in order to prevent interference and improve stability, it is recommended to use a capacitor of more than 20pF. When using a small capacitor, the oscillation frequency will change due to the influence of the distributed capacitance of the printed board and the package leads. Table 3 shows the oscillation frequency at different resistance and capacitance values. When RC oscillates, OSC2 is output as CLKOUT (CLKOUT=fOSC/4).
  Table 3 Oscillation frequency of RC oscillator with different resistance and capacitance
CEXT/pF REXT/kΩ Average oscillation frequency
fOSC@5V,25℃
20 3.3 4.973MHz ±27%
5 3.82MHz ±21%
10 2.22MHz ±21%
100 262.15kHz ±31%
100 3.3 1.63MHz ±13%
5 1.19MHz ±13%
100 684.64kHz ±18%
100 71.56kHz ±25%
300 3.3 660kHz ±10%
5 484.1kHz ±14%
100 267.63kHz ±15%
100 29.44kHz ±19%
 
    [3]. External oscillation.

    In the PIC16C5X microcontroller, an external oscillator source can also be used to provide a clock source. The external clock is input into the microcontroller from the OSC1 terminal, and OSC2 is left empty. The external clock is only used for microcontrollers with HS, XT and LP oscillators. See Figure 3.

Keywords:PIC16C5X Reference address:PIC16C5X clock oscillator

Previous article:PIC16C5X Low Power Mode
Next article:PIC16C5X I/O Ports

Recommended ReadingLatest update time:2024-11-16 13:23

Time Domain Clock Jitter Analysis (Part 1)
In this three-part series, Part 1 focuses on how to accurately estimate the jitter of a clock source and how to combine it with the aperture jitter of the ADC. In Part 2, this combined jitter will be used to calculate the SRN of the ADC, which will then be compared with actual measurements. Part 3 will show how to f
[Analog Electronics]
Time Domain Clock Jitter Analysis (Part 1)
Internal clock switching of stm8s
The internal 128K low-speed clock of stm8s105k6 needs to be used, and the debugging is not very smooth, so I would like to record it. Switch from the internal 16M clock to the internal 128K clock, the configuration is as follows: void Clk_Config(void) {   CLK_CKDIVR= 0x00; //System clock 1 division   while(!(CLK_I
[Microcontroller]
Internal clock switching of stm8s
STM8S three clock source configuration HSE\HSI\LSI configuration
1. About the HSE clock configuration as the main clock static void CLK_Config(void) {     CLK_DeInit(); // Initialization     CLK_HSECmd(ENABLE); //Enable HSE    CLK_ClockSwitchConfig(CLK_SWITCHMODE_AUTO, CLK_SOURCE_HSE, DISABLE,                                 CLK_CURRENTCLOCKSTATE_DISABLE); //Switch HSE and turn o
[Microcontroller]
STM8S three clock source configuration HSE\HSI\LSI configuration
Calendar clock program written in C512
********************************************************************************************************* *                                      FORMAT CURRENT TIME INTO STRING * * Description : Formats the current time into an ASCII string. * Arguments     : mode     is the format type: *                        1    
[Microcontroller]
The STM32F30X clock is initialized to HSI 64Mhz and uses PLLCLK as the system clock
void SYSCLK_Config_HSI_64Mhz(void)   {       __IO uint32_t StartUpCounter = 0, HSIStatus = 0;          /* SYSCLK, HCLK, PCLK2 and PCLK1 configuration ---------------------------*/           /* Enable HSI */           RCC- CR |= ((uint32_t)RCC_CR_HSION);              /* Wait till HSI is ready and if Time out is reached
[Microcontroller]
51 MCU frequency division, machine cycle, clock cycle, state cycle
​​​​(1) Oscillation period = clock period: refers to the period of the oscillation source that provides the clock pulse signal for the microcontroller. (2) State cycle: Each state cycle is twice the clock cycle, which is obtained by dividing the oscillation cycle by two. Detailed explanation: In the 8051 microcontroll
[Microcontroller]
Why does STM32 have to configure the clock first and then the GPIO?
All registers require a clock to be configured. The registers are composed of D flip-flops. Only when the clock is sent can the flip-flops be rewritten.   Any peripheral of any MCU needs a clock, and the same is true for 8051. In order to allow users to better understand power consumption, STM32 sets a switch for th
[Microcontroller]
s3c6410 clock initialization
Today, I encountered a problem when I wrote the bootloader to initialize the clock. I wrote it down. For easy understanding, I have screenshots for most of them. Let me explain that the pictures are from the data manual. I also hope that the comrades who read this article will refer to the data manual more to unders
[Microcontroller]
s3c6410 clock initialization
Latest Microcontroller Articles
  • Download from the Internet--ARM Getting Started Notes
    A brief introduction: From today on, the ARM notebook of the rookie is open, and it can be regarded as a place to store these notes. Why publish it? Maybe you are interested in it. In fact, the reason for these notes is ...
  • Learn ARM development(22)
    Turning off and on interrupts Interrupts are an efficient dialogue mechanism, but sometimes you don't want to interrupt the program while it is running. For example, when you are printing something, the program suddenly interrupts and another ...
  • Learn ARM development(21)
    First, declare the task pointer, because it will be used later. Task pointer volatile TASK_TCB* volatile g_pCurrentTask = NULL;volatile TASK_TCB* vol ...
  • Learn ARM development(20)
    With the previous Tick interrupt, the basic task switching conditions are ready. However, this "easterly" is also difficult to understand. Only through continuous practice can we understand it. ...
  • Learn ARM development(19)
    After many days of hard work, I finally got the interrupt working. But in order to allow RTOS to use timer interrupts, what kind of interrupts can be implemented in S3C44B0? There are two methods in S3C44B0. ...
  • Learn ARM development(14)
  • Learn ARM development(15)
  • Learn ARM development(16)
  • Learn ARM development(17)
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号