亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? main.c

?? 此為ADSP_BF533_EZ_KIT中AD924作DA用時的驅動程序
?? C
字號:
/*****************************************************************************************/
//
// Name: 	BF533 EZ-KIT interface to the AD9744 DAC Evaluation Board 
//
/*****************************************************************************************

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

File Name:				Main.c

Date Modified:			06/05/03		KU		Rev 1.0

Software:       		VisualDSP++3.1

Hardware:				BF533 EZ-KIT Board	Rev. 1.1
						Extender Card	Rev. 1.3
						AD9744 Evaluation Board

Hardware Setup:			Boards:
							Connect the Expander Board to the EZ-KIT 
							Connect the AD9744 Evaluation board to the Expander Board via the HSC connector (J4). Use the provided ribbon cable
                        Settings of the switches on the Expander Board:
							SW1 :	1	OFF
									2	OFF
									3	OFF
									4	OFF
									5	OFF
									6	OFF

							SW2 :	1	OFF
									2	OFF
									3	OFF
									4	OFF
									5	OFF
									6	ON
							
						Settings of the switches on the EZ-Kit:
                        		default settings
                        DAC clock source:
                           			there are several ways to provide a clock to the DAC. Please refer to the 
                           			documentation for the AD9744. In this example, a 32MHz oscillator was 
                           			inserted into socket U7 of the Expander board and the resulting clock signal 
                           			on Pin 33 of connector J4 is the clock input for the AD9744 board.
                           			
DAC clock requirements:
						The DAC clock frequency must be smaller the SCLK/2. You can change SCLK by writing to the PLLDIV register if required.
						The default setting for the EX-Kit rev1.1. board is SCLK = 54MHz.  For this example, SCLK has been changed to 90MHz by 
						setting PLLDIV to 3.

DATA formats:
						The data transmitted over the PPI interface is LEFT aligned, signed (1.15 format). The lower bits are ignored 
						by the DAC.
						
Purpose:				Writes continous streams of data to the DAC. The data is transmitted from a memory buffer ("sPPI_TxBuffer") 
						via the PPI	interface of the ADSP-BF533. A double buffering scheme is implemented so that data in one 
						half is available for "re-fill" while the other half is being transmitted out via DMA operations.
						A flag ("Ping_Pong") indicates which half is available for the new data.
						A variety of predefined output signals are #defined in system.h. In the case of SINES being defined, you may 
						also define amplitude and frequency. The sinevalues are then precalculated.
						You may insert your own code into the interruptible portion of the main loop. The execution time of this 
						additional code must be smaller then the period of DMA interrupts, i.e. the time for transmitting 
						one half of the buffer.
						
******************************************************************************************/


#include "system.h"
#include <math.h>
#include "sysreg.h"
#include "ccblkfn.h"

int initFlags();

// Declare Exception Handler
EX_EXCEPTION_HANDLER(ex_handler);


// GLOBAL vectors

// Declare the DMA output buffer
volatile short sPPI_TxBuffer[Number_of_DAC_channels * Number_of_Samples * 2];

// Declare the Pointers to beginning of each Channel Frame
// each points to the beginning of the channel frame in sPPI_TxBuffer (the first half)
// beginning of second half = DAC_channel_ptrs_begin + Number_of_DAC_channels * Number_of_Samples
short *DAC_channel_ptrs_begin[Number_of_DAC_channels];


// set up DMA descriptors (sequence = 1st half, then second half, then repeat)
// small descriptor model, only start address needs to be fetched
tDMA_descriptor DMA_TX_second; // declaration
section("L1_data_a") tDMA_descriptor DMA_TX_first = {&DMA_TX_second, sPPI_TxBuffer};
section("L1_data_a") tDMA_descriptor DMA_TX_second = {&DMA_TX_first, (sPPI_TxBuffer + sizeof(sPPI_TxBuffer)/sizeof(sPPI_TxBuffer[0])/2)};



// GLOBAL scalars

// flag to indicate which half of the output buffer has been transmitted and can be worked on by the user
// i.e. points to the half that DMA is NOT using
short Ping_Pong = 0;			// 0 = first half, 1 = second half

// semaphore to indicated that a half has been transmitted 
short DMA_completed_Transmission = 0;

// store IMAKS register when interrupts are disabled
int interruptLatch;





/*****************************************************************************************
 USER CODE
******************************************************************************************/

section("L1_code") void main() {
	
	int i = 0;

	sysreg_write(reg_SYSCFG, 0x32);		//Initialize System Configuration Register
	
	//Change SCLK to be CCLK/3 = 90MHz.
	*((short *)PLL_DIV) = 3;
	
	// init exception handler
	register_handler(ik_exception,ex_handler);

	// initialise SDRAM controller	
	InitSDRAM();

// Routes the DAC clock to the PPI interface
// MUX's U25 and U26 on the EZ-KIT are set through writes to the IO port of the Flash Memory U5
// This is not required if hardware other than the EZ-Kit is used
#ifdef EZ_KIT
	InitFlash();
#endif

	// Reset the DMA semaphores
	Ping_Pong = 0;
	DMA_completed_Transmission = 0;

	
	//initialise transmission buffer
	for(i=0; i<Number_of_DAC_channels * Number_of_Samples * 2; i++) {
		sPPI_TxBuffer[i] = 0;
#ifdef LINEAR
		sPPI_TxBuffer[i] = (i+1) * 16384 /(Number_of_DAC_channels * Number_of_Samples);
#else
	#ifdef SINES
		sPPI_TxBuffer[i] = (signed short)(AMPLITUDE * sin((FREQ_RATIO)*6.283*i/Number_of_Samples));
	#endif
#endif
	}
	
 	// configure the programmable flags
	initFlags();
	
	// initialise Hardware (the order is important!!)
	InitPPI_Timer();
	InitPPI();
	InitInterrupts();
	StartPPI();					// really only enables the timer to generate the frame syncs

	
	// MAIN loop
	// waits indefinetely for interrupts from DMA
	// When an interrupt has occured, the flag indicated which half the main loop can put data into
	while(1) {

		// sync to interrupt through semaphore
		// make this un-interruptible
		asm("cli %0;" : "=d" (interruptLatch)); asm("ssync;");
		// Check for the semaphore, and process if semaphore indicates completion
		if (DMA_completed_Transmission == 1)  {
				DMA_completed_Transmission = 0;	 // reset the semaphore
		} 		// if
		asm("sti %0;" : : "d" (interruptLatch)); asm("ssync;");

		// insert interruptible code here
		//	variable Ping_Pong indicates which half is "free" and can be filled with new data

		
	}			// while(1)

}				// main


int initFlags() {
	// Configure the flags 4-15 as outputs
	*((short *)FIO_DIR) = *((short *)FIO_DIR) & (0xFFF0);
	*((short *)FIO_DIR) = *((short *)FIO_DIR) | (0xFFF0);
	
	// Deassert the output flags
  	*pFIO_FLAG_C = (0xFFF0);
	asm("ssync;");
	return 0;
}



// Exception handler
// do nothing, just stall
EX_EXCEPTION_HANDLER(ex_handler)
{
	while(1);
}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
色噜噜狠狠成人中文综合| 久久精品国产99| 色综合欧美在线| 亚洲精品精品亚洲| 色久优优欧美色久优优| 亚洲黄色在线视频| 欧美伦理影视网| 麻豆久久一区二区| 国产精品网站导航| 丁香激情综合国产| 一区二区三区四区不卡视频| 欧美日韩国产首页| 精品一二三四区| 国产精品无圣光一区二区| 色香色香欲天天天影视综合网| 亚洲一区二区三区在线看| 欧美一级久久久| 国产成人综合视频| 亚洲午夜久久久久久久久电影院| 欧美理论在线播放| 国产盗摄一区二区三区| 亚洲亚洲精品在线观看| 日韩欧美一区中文| 成人app网站| 爽好久久久欧美精品| 国产日韩v精品一区二区| 91高清在线观看| 麻豆一区二区三区| 综合激情成人伊人| 精品久久久久久最新网址| 97成人超碰视| 免费成人在线播放| 亚洲欧美在线视频观看| 日韩免费高清av| 94-欧美-setu| 老司机一区二区| 一区二区三区不卡视频在线观看 | 国产91丝袜在线播放| 亚洲色图视频网| 日韩欧美美女一区二区三区| 成人高清av在线| 久久99精品久久久久久国产越南 | 粉嫩欧美一区二区三区高清影视| 亚洲午夜免费视频| 亚洲国产高清在线| 欧美成人r级一区二区三区| 91在线小视频| 国内精品伊人久久久久av一坑| 成人免费在线视频观看| 亚洲精品一区在线观看| 欧美日韩一区高清| eeuss鲁一区二区三区| 久久不见久久见中文字幕免费| 亚洲激情图片一区| 亚洲国产高清在线观看视频| 欧美mv日韩mv亚洲| 欧美日韩免费视频| 91丨九色丨黑人外教| 国产成人综合亚洲网站| 日本91福利区| 亚洲第一在线综合网站| 亚洲三级电影网站| 国产精品美女久久久久av爽李琼 | 国产精品素人视频| 久久嫩草精品久久久精品一| 日韩欧美中文字幕制服| 欧美日韩aaa| 在线观看日韩电影| 色天使色偷偷av一区二区| 成人精品电影在线观看| 国产成人在线看| 国产精品一区二区无线| 极品少妇xxxx偷拍精品少妇| 日韩高清不卡一区二区| 秋霞成人午夜伦在线观看| 五月天网站亚洲| 亚洲成人动漫av| 五月天视频一区| 日韩国产在线观看一区| 日韩中文字幕不卡| 日本成人中文字幕在线视频| 奇米一区二区三区| 精品在线视频一区| 国产综合色产在线精品| 国产成人一区二区精品非洲| 成人精品视频网站| 99re视频这里只有精品| 色婷婷国产精品综合在线观看| 91九色最新地址| 欧美女孩性生活视频| 欧美一区二区三区在线| 久久久www成人免费无遮挡大片| 久久蜜桃香蕉精品一区二区三区| 26uuu另类欧美亚洲曰本| 国产精品无圣光一区二区| 亚洲少妇屁股交4| 午夜电影网亚洲视频| 麻豆精品视频在线观看| 韩国女主播成人在线| 成人aaaa免费全部观看| 在线精品视频免费观看| 91精品国产一区二区三区 | 欧美色倩网站大全免费| 日韩一区二区三区视频| 国产欧美一区视频| 一区二区三区精品视频在线| 奇米色777欧美一区二区| 国产老肥熟一区二区三区| 99久久综合99久久综合网站| 欧美亚洲免费在线一区| 欧美大片在线观看一区二区| 亚洲国产精品激情在线观看| 一区二区三区不卡在线观看| 精品亚洲成a人| 99re在线视频这里只有精品| 欧美久久一区二区| 中文字幕中文在线不卡住| 肉色丝袜一区二区| 成人一级视频在线观看| 精品视频一区 二区 三区| 久久久亚洲午夜电影| 亚洲黄色免费电影| 国产在线精品一区二区夜色 | 亚洲第四色夜色| 国产一区二区三区av电影 | 欧美一区二区三区在线观看视频| 国产欧美视频一区二区| 日韩精品一二三四| 99久久综合色| 久久日韩粉嫩一区二区三区| 亚洲国产视频直播| 国产91精品久久久久久久网曝门| 欧美视频一区二| 国产精品超碰97尤物18| 久久精品国产99| 欧美日韩久久久久久| 中文字幕亚洲成人| 国产精品影视网| 欧美日本一区二区在线观看| 国产精品国产三级国产aⅴ无密码| 蜜桃av噜噜一区| 欧美日韩国产在线播放网站| 国产精品嫩草影院com| 国内精品视频一区二区三区八戒| 欧美日韩国产精选| 曰韩精品一区二区| 91网址在线看| 亚洲欧洲无码一区二区三区| 国产一区二区成人久久免费影院| 欧美电影在线免费观看| 亚洲午夜三级在线| 欧美性感一类影片在线播放| 17c精品麻豆一区二区免费| 国产 日韩 欧美大片| 久久九九99视频| 久88久久88久久久| 日韩视频永久免费| 午夜精品一区二区三区电影天堂 | 日本在线不卡视频一二三区| 色94色欧美sute亚洲13| 日韩美女啊v在线免费观看| 成人黄色一级视频| 国产日产欧产精品推荐色 | 亚洲精品久久7777| 91美女福利视频| 亚洲欧洲三级电影| 91啪亚洲精品| 一区二区三区在线视频观看58| 99久久国产综合精品麻豆| 国产精品美女久久久久久2018| 成人久久久精品乱码一区二区三区| 久久女同性恋中文字幕| 国产成人精品网址| 中文字幕中文字幕一区二区| 91网页版在线| 一区二区三区精品久久久| 欧美色图片你懂的| 丝袜美腿成人在线| 精品久久久三级丝袜| 国产成人精品影视| 亚洲欧美二区三区| 欧美日韩性生活| 免费观看在线色综合| 久久香蕉国产线看观看99| 福利一区二区在线| 亚洲男人的天堂一区二区| 欧美日韩亚洲高清一区二区| 免费观看在线综合色| 国产色产综合色产在线视频| 99免费精品在线观看| 香港成人在线视频| 亚洲精品在线免费观看视频| 99久久免费精品高清特色大片| 一区二区三区四区中文字幕| 777亚洲妇女| 成人网页在线观看| 午夜精品久久久久久久| 国产亚洲成aⅴ人片在线观看| 91蜜桃传媒精品久久久一区二区| 亚洲二区视频在线|