tim.h
来自「for mips adm5120 uclibc-0.9.19 toolchain」· C头文件 代码 · 共 92 行
H
92 行
#ifndef __IDT_TIM_H__#define __IDT_TIM_H__/******************************************************************************* * * Copyright 2002 Integrated Device Technology, Inc. * All rights reserved. * * Timer register definition. * * File : $Id: tim.h,v 1.1 2004/10/15 12:47:26 brianc Exp $ * * Author : ryan.holmQVist@idt.com * Date : 20011005 * Update : * $Log: tim.h,v $ * Revision 1.1 2004/10/15 12:47:26 brianc * Readd the file * * Revision 1.1.1.1 2004/03/29 00:54:44 daniell * Initialized the project * * Revision 1.2 2003/07/30 18:20:38 stevel * MR: 1-2IQL9 * * Add IDT and ATI Xilleon LSP's, and update related drivers. * * Revision 1.1.2.1 2003/02/15 00:06:01 stevel * New IDT board support: 79EB438 and 79RP355. Also support for * boot from PROM on 79S334A, 79EB355, 79RP355, and 79EB438. * * Revision 1.2 2002/06/06 18:34:05 astichte * Added XXX_PhysicalAddress and XXX_VirtualAddress * * Revision 1.1 2002/05/29 17:33:25 sysarch * jba File moved from vcode/include/idt/acacia * * ******************************************************************************/enum{ TIM0_PhysicalAddress = 0x18028000, TIM_PhysicalAddress = TIM0_PhysicalAddress, // Default TIM0_VirtualAddress = 0xb8028000, TIM_VirtualAddress = TIM0_VirtualAddress, // Default} ;enum{ TIM_Count = 3,} ;struct TIM_CNTR_s{ unsigned int count ; unsigned int compare ; unsigned int ctc ; //use CTC_} ;typedef struct TIM_s{ struct TIM_CNTR_s tim [TIM_Count] ; unsigned int rcount ; //use RCOUNT_ unsigned int rcompare ; //use RCOMPARE_ unsigned int rtc ; //use RTC_} volatile * TIM_t ;enum{ CTC_en_b = 0, CTC_en_m = 0x00000001, CTC_to_b = 1, CTC_to_m = 0x00000002, RCOUNT_count_b = 0, RCOUNT_count_m = 0x0000ffff, RCOMPARE_compare_b = 0, RCOMPARE_compare_m = 0x0000ffff, RTC_ce_b = 0, RTC_ce_m = 0x00000001, RTC_to_b = 1, RTC_to_m = 0x00000002, RTC_rqe_b = 2, RTC_rqe_m = 0x00000004, } ;#endif // __IDT_TIM_H__
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?