📄 ezkitutilities.h
字号:
/*****************************************************************************
Copyright(c) 2005 Analog Devices, Inc. All Rights Reserved. This software is
proprietary and confidential to Analog Devices, Inc. and its licensors.
******************************************************************************
$RCSfile: ezkitutilities.h,v $
$Revision: 1.2 $
$Date: 2005/10/27 07:49:15 $
Project: Developer Kit
Title: Set up ezkit
Author(s):
Revised by:
Description:
Utility functions for ezkits
References:
None
******************************************************************************
Tab Setting: 4
Target Processor: ADSP-BF5xx
Target Tools Revision: ADSP VisualDSP++ v4.0
******************************************************************************
Modification History:
====================
$Log: ezkitutilities.h,v $
Revision 1.2 2005/10/27 07:49:15 dwu
Changed/added ADI headers
*****************************************************************************/
#ifndef EZKITUTILITIES__H
#define EZKITUTILITIES__H
#include <services/services.h> // system service includes
/*********************************************************************
Enumerations for the first and last buttons and LEDs
*********************************************************************/
#define EZ_FIRST_LED (4) // first LED number
#define EZ_LAST_LED (9) // last LED number
#define EZ_FIRST_BUTTON (4) // first push button
#define EZ_LAST_BUTTON (7) // last push button
/*********************************************************************
Functions provided by the utilities
*********************************************************************/
/*
void ezConfigurePLL (void); // sets processor to 594 MHz CCLK, 118,8 MHz SCLK
void ezConfigureSDRAM (void); // sets up SDRAM for use
void ezConfigureAsync (void); // configures async memory for use
void ezConfigureFlashA (void); // sets up Flash A
void ezEnableVideoEncoder (void); // enables the 7183 video encoder
void ezDisableVideoEncoder (void); // disables the 7183 video encoder
void ezEnableVideoDecoder (void); // enables the 7171 video decoder
void ezDisableVideoDecoder (void); // disables the 7171 video decoder
void ezTurnOnLED (u32 LEDNumber); // turns on an LED
void ezTurnOffLED (u32 LEDNumber); // turns off an LED
void ezToggleLED (u32 LEDNumber); // toggles an LED
u32 ezIsLEDOn (u32 LEDNumber); // test to see if an LED is lit
void ezTurnOnAllLEDs (void); // turns on all LEDs
void ezTurnOffAllLEDs (void); // turns off all LEDs
void ezCycleLEDs (void); // cycles through LEDS
u8 ezGetDisplay (void); // returns the current bit pattern for the LED display
void ezSetDisplay (u8 display); // sets the LED display for the given bit pattern
void ezInitButtons (void); // initialized push buttons
u32 ezIsButtonPushed (u32 ButtonNumber); // is a push button pressed (TRUE - pressed/FALSE - not pressed)
void ezClearButton (u32 ButtonNumber); // clears the push button latch
void ezEnableButtonInterrupt (u32 ButtonNumber); // enables generation of a push button interrupt
void ezDisableButtonInterrupt (u32 ButtonNumber); // enables generation of a push button interrupt
void ezErrorCheck (u32 Result); // lights all LEDS and spins on nonzero value
*/
void ezConfigurePLL (void); // sets processor to 594 MHz CCLK, 118,8 MHz SCLK
void ezConfigureSDRAM (void); // sets up SDRAM for use
void ezConfigureAsync (void); // configures async memory for use
void ezConfigureFlashA (void); // sets up Flash A
//void ezEnableVideoEncoder (void); // enables the 7183 video encoder
//void ezDisableVideoEncoder (void); // disables the 7183 video encoder
void ezEnableVideoDecoder (void); // enables the 7183 video decoder
void ezTurnOnLED (u32 LEDNumber); // turns on an LED
void ezTurnOffLED (u32 LEDNumber); // turns off an LED
void ezToggleLED (u32 LEDNumber); // toggles an LED
u32 ezIsLEDOn (u32 LEDNumber); // test to see if an LED is lit
void ezTurnOnAllLEDs (void); // turns on all LEDs
void ezTurnOffAllLEDs (void); // turns off all LEDs
void ezCycleLEDs (void); // cycles through LEDS
u8 ezGetDisplay (void); // returns the current bit pattern for the LED display
void ezSetDisplay (u8 display); // sets the LED display for the given bit pattern
void ezInitButtons (void); // initialized push buttons
//void ezConfigureFlashA (void); // sets up Flash A
void ezEnableButtonInterrupt (u32 ButtonNumber); // enables generation of a push button interrupt
void ezErrorCheck (u32 Result); // lights all LEDS and spins on nonzero value
void ezDelay (u32 msec);
#define pFlashA_PortA_In ((volatile unsigned char *)0x20270000) // address of flash A port A input data register
#define pFlashA_PortA_Out ((volatile unsigned char *)0x20270004) // address of flash A port A output data register
#define pFlashA_PortA_Dir ((volatile unsigned char *)0x20270006) // address of flash A port A direction register
#define pFlashA_PortB_In ((volatile unsigned char *)0x20270001) // address of flash A port B input data register
#define pFlashA_PortB_Out ((volatile unsigned char *)0x20270005) // address of flash A port B output data register
#define pFlashA_PortB_Dir ((volatile unsigned char *)0x20270007) // address of flash A port B direction register
#define RST_7183 (0x8) //decoder reset bit #3 in flashA portA
#define PPICLK_ADV7183_SELECT (0x10) //decoder clock to PPI bit #4 in flashA portA
#define ADV7183_OE (0x4) //ADV7183 /OE = PF2
#endif // #ifndef EZKITUTILITIES__H
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -