upsd_cfg.c
来自「upsd 3200序列的usb驱动」· C语言 代码 · 共 52 行
C
52 行
/*---------------------------------------------------------------*/
/* UPSD_CFG.C */
/* This module contains all the defines for uPSD Configuration */
/* --------------------------------------------------------------*/
/*---------------------------------------------------------------------------
Copyright (c) 2002 ST Microelectronics
This example demo code is provided as is and has no warranty,
implied or otherwise. You are free to use/modify any of the provided
code at your own risk in your applications with the expressed limitation
of liability (see below) so long as your product using the code contains
at least one uPSD products (device).
LIMITATION OF LIABILITY: NEITHER STMicroelectronics NOR ITS VENDORS OR
AGENTS SHALL BE LIABLE FOR ANY LOSS OF PROFITS, LOSS OF USE, LOSS OF DATA,
INTERRUPTION OF BUSINESS, NOR FOR INDIRECT, SPECIAL, INCIDENTAL OR
CONSEQUENTIAL DAMAGES OF ANY KIND WHETHER UNDER THIS AGREEMENT OR
OTHERWISE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
--------------------------------------------------------------------------*/
//-- Includes ----------------------------------------------------------------
#include "general.h"
#include "upsd3200.h"
#include "upsd_hardware.h" // extended registers in uPSD
#include "upsd_cfg.h" // All defines for uPSD Configuration
/*---------------------------------------------------------------*/
/* This module contains all the constants */
/* for uPSD libraryConfiguration */
/* --------------------------------------------------------------*/
//-- Constants values for ipLIBs ----------------------------------------------
//USB
const uchar code cUSCL_value = (uchar)((((OSC*10L/2L)/(USB_clk_in*1000L))+5)/10) - 1;
/*---------------------------------------------------------------*/
/* This module contains all extened I/O devices */
/* for uPSD including PSD module regs in XDATA */
/* --------------------------------------------------------------*/
//-- Assign memory location for PSD module regs in XDATA -----------------------
PSD_REGS UPSD_xreg _at_ PSD_REG_ADDR;
//-- Assign memory location for user I/O devices -------------------------------
#include "lcd_io.h"
DISPLAY LCD_reg _at_ LCD_BASE_ADDR;
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?