⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 lpc_lib_pll.h

📁 使用embest IDE开发工具开发的基于LPC2294 的触摸屏开发
💻 H
字号:

/*
***********************************************************************

       Embest Info&Tech Co., Ltd.  All rights reserved.
                     www.embedinfo.com

***********************************************************************

---------------- file information -------------------------------------

file name: lpc_lib_pll.h
version  : v0
author   : peter pan / panqan@hotmail.com
begin    : 2006-02-10
finish   : 2006-02-10
define   : lpc pll control head file

notes    :

---------------- modify information -----------------------------------
version  :
modify   :
begin    :
finish   :
define   :
-----------------------------------------------------------------------
*/


// (--------------------- compiler condition --------------------------
#ifndef  lpc_lib_pll_h
#define  lpc_lib_pll_h



// --------------------- compiler condition --------------------------)



/*-------------------------------------------------------------------*/
/*                       include files                               */
/*---------------------------------------------------------------- --*/
#include	"..\..\com\type_redefine.h"
#include	"..\..\com\lpc22xx_register.h"

/*-------------------------------------------------------------------*/
/*                       local function declare                      */
/*-------------------------------------------------------------------*/
void  lpc_init_pll_manual();
void  lpc_init_pll_auto();


/*-------------------------------------------------------------------*/
/*                       variable define                             */
/*-------------------------------------------------------------------*/

/*
// for lpc_init_pll_manual()
#define     PLL_VPBDIV      0x02            // VPB = 1/2 CCLK
#define     PLL_CFG         0x23            // 4 multiple
#define     MAM_TIM         0x03            // read code 2 clock
*/

/*
// for lpc_init_pll_manual()
#define     PLL_VPBDIV      0x00            // VPB = CCLK
#define     PLL_CFG         0x43            // M=4 multiple
                                            // P=4
#define     MAM_TIM         0x03            // read code 2 clock
*/



// for lpc_init_pll_manual()
#define     PLL_VPBDIV      0x11            // VPB = CCLK
#define     PLL_CFG         0x61            // M=2 multiple
                                            // P=8
#define     MAM_TIM         0x03            // read code 2 clock

#define	 	PCLKF 			20000000        //


/*
// for lpc_init_pll_manual()
#define     PLL_VPBDIV      0x00            // VPB = CCLK/4
#define     PLL_CFG         0x25            // M=6 multiple
                                            // P=2
#define     MAM_TIM         0x03            // read code 2 clock
*/







/*
// for lpc_init_pll_auto()
// Fosc、Fcclk、Fcco、Fpclk
#define     Fosc            10000000        //crystal,10MHz~25MHz
#define     Fcclk          (Fosc * 4)       //Fosc * N,<=60MHZ
#define     Fcco           (Fcclk * 4)      //Fcclk* N,[156MHz~320MHz]
#define     Fpclk          (Fcclk / 4) * 4  //(Fcclk/4) * [1~4]
*/


// for lpc_init_pll_auto()
// Fosc、Fcclk、Fcco、Fpclk
#define     Fosc            10000000        //crystal,10MHz~25MHz
#define     Fcclk          (Fosc * 4)       //Fosc * N,<=60MHZ
                                            //Fcclk/Fosc=M
                                            
#define     Fcco           (Fcclk * 7)      //Fcclk* N,[156MHz~320MHz]
                                            //Fcco=Fcclk*2*P
                                            
#define     Fpclk          (Fcclk/4) * 4    //(Fcclk/4) * [1~4]




/*-------------------------------------------------------------------*/
/*                       extern function declare                     */
/*-------------------------------------------------------------------*/

/*--- define in XXX.c ---
extern  void    XXX();
*/


/*-------------------------------------------------------------------*/
/*                       extern variable declare                     */
/*-------------------------------------------------------------------*/

/*--- USED in XXX() ---
XXX SSS; // used inXXX()
*/



/*-------------------------------------------------------------------*/
/*                       function code                               */
/*-------------------------------------------------------------------*/


/**********************************************************************
* name  :    xxxxx
* func  :    xxxxx
* para  :    xxxx
* ret   :    xxxx

* glob  :    xxxx
* inc   :

* author:
* date  :

* modify:
* comment:
**********************************************************************/
/*void  xxx(xxx xxx)
      {
      }
*/


#endif  //lpc_lib_pll_h

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -