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

📄 adv7183_reset.c

📁 Using the ADSP-BF561 Blackfin Processor as a TFT-LCD Controller
💻 C
字号:
/*****************************************************************************
**																			**
**	 Project Name: 	LCD											**	
**																			**
******************************************************************************

(C) Copyright 2005 - Analog Devices, Inc.  All rights reserved.

File Name:		ADV7183_reset.c

Date Modified:	5/1/05		CL		Rev 1.0

Software:       VisualDSP++3.5

Hardware:		ADSP-BF561 EZ-KIT Lite

Special Connections:  None

Purpose:		This file initializes the ADV7183A video decoder.
				
******************************************************************************/


#include "main.h"

/********************************************************************************/
/***** Reset_ADV7183()														*****/
/***** Resets the Video decoder through PF2									*****/
/********************************************************************************/


// specific defines for this module. Not used anywhere else
#define ADV7183_OE_bit 2   					// ADV7183 /OE = PF2
#define ADV7183_RESET_bit 13   				// ADV7183 /reset = PF13
#define ADV7183_Lock   0x00ffffff    		// For startup locktime delay
#define ADV7183_Reset_Delay   0x04000000   	// For delay after reset



void Reset_ADV7183(void )
{ long delay_time;

	// configure OE and RESET flags as output
	*pFIO0_DIR |= (1 << ADV7183_OE_bit) | (1 << ADV7183_RESET_bit);
	ssync();

	// disable outputs
	*pFIO0_FLAG_S = (1 << ADV7183_OE_bit);	// set bit to disable ADV7183 outputs
	ssync();

	// generate reset pulse
	*pFIO0_FLAG_C = (1 << ADV7183_RESET_bit);	// clear bit to reset ADV7183 
	ssync();

	*pFIO0_FLAG_S = (1 << ADV7183_RESET_bit);	// set bit to re-enable ADV7183 
	ssync();

	for (delay_time = 0; delay_time < ADV7183_Reset_Delay; delay_time++)
			asm("nop;");

	// now enable outputs
	*pFIO0_FLAG_C = (1 << ADV7183_OE_bit);	// clear bit to enable ADV7183 outputs
	ssync();

	for (delay_time = 0; delay_time < ADV7183_Lock; delay_time++)
			asm("nop;");
	
}


⌨️ 快捷键说明

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