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

📄 config_ppi.asm

📁 lcd color bar example. platform bf537 + lcd card.
💻 ASM
字号:
/*****************************************************************************
**																			**
**	 Project Name: 	LCD Colorbar									**	
**																			**
******************************************************************************

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

File Name:		config_ppi.asm

Date Modified:	10/07/05	GO

Software:       VisualDSP++4.0

Hardware:		ADSP-BF537

Special Connections:  None

Purpose:	Configure PPI port for 16-bit data tx to LCD.
	
				
******************************************************************************/



#include "defBF537.h"

.global _config_ppi;

.section program;

_config_ppi:
	// Configure PORTG for PPI
	P3.L = lo(PORTG_FER);
	P3.H = hi(PORTG_FER);
	R3 = 0xFFFF(z);
	W[P3] = R3.L;
	SSYNC;	
	
	P4.L = lo(PORT_MUX);
	P4.H = hi(PORT_MUX);
	R4 = 0x0000(z);	
	W[P4] = R4.L;
	SSYNC;

	// Configure PORTF for PPICLK, TMR1 and TMR0
	P5.L = lo(PORTF_FER);
	P5.H = hi(PORTF_FER);
	R5 = 0x8300(z);
	W[P5] = R5.L;
	SSYNC;
	
	// Configure PPI for 16 bit
	P0.L = lo(PPI_CONTROL);
	P0.H = hi(PPI_CONTROL);
	//R0.L = 0xb81E;
	R0.L = 0xb91E;
	W[P0] = R0.L;
	SSYNC;	
	//Up to user's preference to delay data or not.  In this case, not.
	//However, note that for TX modes with at least 1 FS, there is a 1 cycle
	//delay beyond the value programmed into this register.
	P1.L = lo(PPI_DELAY);
	P1.H = hi(PPI_DELAY);
	R1 = 143(z);
	W[P1] = R1.L;
	SSYNC;
	
	//Holds one minus the number of samples to write out the PPI per line.
	P2.L = lo(PPI_COUNT);
	P2.H = hi(PPI_COUNT);
	R2 = 639(z);
	W[P2] = R2;
	SSYNC;
_config_ppi.END:	RTS;

⌨️ 快捷键说明

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