drv_delay.c

来自「该模板使用于周立功公司研发的EasyARM2100系列开发板」· C语言 代码 · 共 45 行

C
45
字号
/******************************************************************************
  Copyright (C), 2007-2008, wanyi Tech. Co., Ltd.
  FileName		:drv_delay.c
  Author		:kevin 
  modify		:       
  Version 		:1.0          
  Date			:2007-6-28
  Description	:auto design for driver delay function       
  Function List	:void delay(unsigned int time)
******************************************************************************/
#include "\inc\system.h"








/******************************************************************************
  Function:       // void delay(unsigned int time)
  Description:    // for set delay time
  Calls:          // none
  Called By:      // more
  Table Accessed: // none
  Table Updated:  // none
  Input:          // time-->delay time
  Output:         // none
  Return:         // void
  Others:         // none
******************************************************************************/
int delay(unsigned int time)
{
	unsigned char i;
	unsigned int j;
	for(j=0;j<time;j++)
	{
		for(i=0;i<9;i++)				//2.5us
		{
		}
	}
	return(0);
}
//=============================================================================

⌨️ 快捷键说明

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