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

📄 flashintel.h

📁 OMAP1030 处理器的ARM 侧硬件测试代码 OMAP1030 是TI的双核处理器
💻 H
📖 第 1 页 / 共 2 页
字号:
//
// LIMITATIONS :    Setup the MIF block before access to flash 
//---------------------------------------------------------------------
UWORD16 FLASH_FlashIntelReadStatus (UWORD32 Address);

//---------------------------------------------------------------------
// NAME        : FLASH_FlashIntelClearStatus
//              
// DESCRIPTION : clear the status register of the flash
//              
//              
// PARAMETERS  :    Address,         Flash Address
//              
// RETURN VALUE:    none
//
// LIMITATIONS :    Setup the MIF block before access to flash 
//---------------------------------------------------------------------
void FLASH_FlashIntelClearStatus (UWORD32 Address);

//---------------------------------------------------------------------
// NAME        : FLASH_FlashIntelPairReadId
//              
// DESCRIPTION : Get the Manufacturer id or the device id
//              
// SYNOPSYS    : UWORD32 FLASH_FlashIntelPairReadId(UWORD32 Address, BOOL IdRequest)
//
//              
// PARAMETERS  :    Address,         Base Address of the flash package
//                  IdRequest        MANUFACTERER_ID_REQ or DEV16MBITBOTTOM_ID_REQ
//              
// RETURN VALUE:    UWORD32          the half MSB contains the status of the MSB flash package
//                                   the half LSB contains the status of the LSB flash package
//
// LIMITATIONS :    Setup the MIF block before access to flash 
//---------------------------------------------------------------------
UWORD32 FLASH_FlashIntelPairReadId(UWORD32 Address, BOOL IdRequest);

//---------------------------------------------------------------------
// NAME        : FLASH_FlashIntelReadId
//              
// DESCRIPTION : Get the Manufacturer id or the device id
//              
// SYNOPSYS    : UWORD16 FLASH_FlashIntelPairReadId(UWORD32 Address, BOOL IdRequest)
//
//              
// PARAMETERS  :    Address,         Base Address of the flash package
//                  IdRequest        MANUFACTERER_ID_REQ or DEV16MBITBOTTOM_ID_REQ
//              
// RETURN VALUE:    UWORD16          contains the status of the flash package
//                                   
// LIMITATIONS :    Setup the MIF block before access to flash 
//---------------------------------------------------------------------
UWORD16 FLASH_FlashIntelReadId(UWORD32 Address, BOOL IdRequest);

//---------------------------------------------------------------------
// NAME        : FLASH_SetFlashProgrammVoltage
//               
// DESCRIPTION : Set the voltage of Vpp on the flash
//               
// SYNOPSYS    : void FLASH_SetFlashProgrammVoltage(BOOL VoltageLevel)
//               
// PARAMETERS  : VoltageLevel                 PROGRAM_LEVEL or PROTECT_LEVEL
//               
//               
// RETURN VALUE: None
//               
// LIMITATIONS : None
//---------------------------------------------------------------------
void FLASH_SetFlashProgrammVoltage(BOOL VoltageLevel);

//---------------------------------------------------------------------
// NAME        : FLASH_FlashIntelProgramPair
//               
// DESCRIPTION : Programme a word in the flash pair
//               
// SYNOPSYS    : void FLASH_FlashIntelProgramPair(UWORD32 write_address, UWORD32 write_value)
//               
// PARAMETERS  : write_address            Address where the user wants to write
//               write_value              Value the user wants to store
//               
//               
// RETURN VALUE: IS_OK or NOT_OK
//               
// LIMITATIONS : MIF block must be initialized before use of that function
// 				  Authorize the flash write must be done in EMIF Interface 
//					  by function MIF_MifSetWriteProtect(WRITE_AUTHORIZED);              
//---------------------------------------------------------------------
BOOL FLASH_FlashIntelProgramPair(UWORD32 write_address, UWORD32 write_value);

//---------------------------------------------------------------------
// NAME        : FLASH_FlashIntelProgram
//               
// DESCRIPTION : Programme a word in the flash pair
//               
// SYNOPSYS    : void FLASH_FlashIntelProgramPair16(UWORD32 write_address, UWORD32 write_value)
//               
// PARAMETERS  : write_address            Address where the user wants to write
//               write_value              Value the user wants to store
//               
// RETURN VALUE: IS_OK or NOT_OK
//               
// LIMITATIONS : Mif Interface must be initialized
// 				  Authorize the flash write must be done in EMIF Interface 
//					  by function MIF_MifSetWriteProtect(WRITE_AUTHORIZED);              
//---------------------------------------------------------------------
BOOL FLASH_FlashIntelProgram(UWORD32 write_address, UWORD16 write_value);

//---------------------------------------------------------------------
// NAME        : FLASH_FlashIntelEraseBlockPair
//               
// DESCRIPTION : Erase the block memory which contains the address specified
//               
// SYNOPSYS    : BOOL FLASH_FlashIntelEraseBlockPair(UWORD32 erase_address)
//               
// PARAMETERS  : erase_address            specify the block to erase
//               
// RETURN VALUE: YES if succeed NO if fail
//               
// LIMITATIONS : Mif Interface must be initialized
// 				  Authorize the flash write must be done in EMIF Interface 
//					  by function MIF_MifSetWriteProtect(WRITE_AUTHORIZED);              
//---------------------------------------------------------------------
BOOL FLASH_FlashIntelEraseBlockPair(UWORD32 erase_address);

//---------------------------------------------------------------------
// NAME        : FLASH_FlashIntelEraseBlock
//               
// DESCRIPTION : Erase the block memory which contains the address specified
//               
// SYNOPSYS    : BOOL FLASH_FlashIntelEraseBlock(UWORD32 erase_address)
//               
// PARAMETERS  : erase_address  specify the block to erase
//               
// RETURN VALUE: IS_OK if succeed NOT_OK if fail
//               
// LIMITATIONS : MIf block must be initialized
// 				  Authorize the flash write must be done in EMIF Interface 
//					  by function MIF_MifSetWriteProtect(WRITE_AUTHORIZED);              
//---------------------------------------------------------------------
BOOL FLASH_FlashIntelEraseBlock(UWORD32 erase_address);

//---------------------------------------------------------------------
// NAME        : FLASH_FlashIntelReadDataPair
//               
// DESCRIPTION : Read a 32 bits word in the flash pair
//               
// SYNOPSYS    : UWORD32 FLASH_FlashIntelReadDataPair(UWORD32 read_address)
//               
// PARAMETERS  : read_address           place where to read the data in 
//               
//               
// RETURN VALUE: UWORD32                Value read
//               
// LIMITATIONS : Mif block must be initialized
//---------------------------------------------------------------------
UWORD32 FLASH_FlashIntelReadDataPair(UWORD32 read_address);

//---------------------------------------------------------------------
// NAME        : FLASH_FlashIntelReadData
//               
// DESCRIPTION : Read a 32 bits word in the flash pair
//               
// SYNOPSYS    : UWORD32 FLASH_FlashIntelReadData(UWORD32 read_address)
//               
// PARAMETERS  : read_address           place where to read the data in 
//               
//               
// RETURN VALUE: UWORD32                Value read
//               
// LIMITATIONS : Mif block must be initialized
//---------------------------------------------------------------------
UWORD16 FLASH_FlashIntelReadData(UWORD32 read_address);


//---------------------------------------------------------------------
// NAME        : FLASH_FlashIntelPairReadArray
//               
// DESCRIPTION : Set the read array command in the flash pair
//               
// SYNOPSYS    : void FLASH_FlashIntelPairReadArray(UWORD32 read_address)
//               
// PARAMETERS  : read_address           An address in the flash 
//               
//               
// RETURN VALUE: None
//               
// LIMITATIONS : Mif block must be initialized
//---------------------------------------------------------------------
void FLASH_FlashIntelPairReadArray(UWORD32 write_address);


//---------------------------------------------------------------------
// NAME        : FLASH_FlashIntelReadArray
//               
// DESCRIPTION : Set the read array command in the flash 
//               
// SYNOPSYS    : void FlashIntelPairRead(UWORD32 read_address)
//               
// PARAMETERS  : read_address           An address in the flash 
//               
//               
// RETURN VALUE: None
//               
// LIMITATIONS : Mif block must be initialized
//---------------------------------------------------------------------
void FLASH_FlashIntelReadArray(UWORD32 write_address);


//---------------------------------------------------------
//NAME        : FLASH_FlashIntelDowloadProgram
//DESCRIPTION : Program flash with array of data
//PARAMETERS  : 
//             UWORD32 FlashBaseAddress : flash address
//					PrgData : pointer on data to be programmed
//					PrgLengthInByte : program size in bytes
//RETURN VALUE: True if Program ok
//LIMITATIONS : flash must be erased 
//---------------------------------------------------------
BOOL FLASH_FlashIntelDowloadProgram(UWORD32 FlashBaseAddress,UWORD16 * PrgData, UWORD32 PrgLengthInByte);

//---------------------------------------------------------
//NAME        : FLASH_IntelStrataFlashEraseDevice
//DESCRIPTION : Erase a whole device (all sectors) of intel strata Flash
//PARAMETERS  : UWORD32 FlashBaseAddress : flash address
//RETURN VALUE: True if erase ok
//LIMITATIONS : none
//---------------------------------------------------------
BOOL FLASH_IntelStrataFlashEraseDevice(UWORD32 flash_base_address);
//---------------------------------------------------------
//NAME        : FLASH_IntelBurstFlashEraseDevice
//DESCRIPTION : Erase a whole device (all sectors) of intel burst Flash 
//					 (16 Mbit top memory map )
//PARAMETERS  : UWORD32 FlashBaseAddress : flash address
//RETURN VALUE: True if erase ok
//LIMITATIONS : device I28F160F3-T
//---------------------------------------------------------
BOOL FLASH_IntelBurstFlashEraseDevice(UWORD32 flash_base_address);


//===============================================================================
// functions defined in flash.asm
//===============================================================================
extern UWORD32 ReadFlashPairRegister(UWORD32 Address1, UWORD32 Data1, UWORD32 Address2);
extern void    WriteFlashPairRegister(UWORD32 Address1, UWORD32 Data1, UWORD32 Address2, UWORD32 Data2);
extern UWORD16 ReadFlashRegister(UWORD32 Address1, UWORD16 Data1, UWORD32 Address2);
extern void    WriteFlashRegister(UWORD32 Address1, UWORD16 Data1, UWORD32 Address2, UWORD16 Data2);
extern UWORD16 ReadFlash(UWORD32 Address1);
extern void    WriteFlash(UWORD32 Address1, UWORD16 Data1);
extern UWORD32 ReadFlashPair(UWORD32 Address1);
extern void    WriteFlashPair(UWORD32 Address1, UWORD32 Data1);
extern void    Read4wordFlashPair(UWORD32 Address1, UWORD32 Address2);
extern void    SwitchIntelFlash2burstmode(UWORD32 Rcdvalue , UWORD32 EmifSlowValue);
extern void    SwitchIntelFlash2burstmodeCS(UWORD32 Rcdvalue , UWORD32 EmifSlowValue,UWORD32 EmifSlowCSAddress);
extern void    SwitchIntelFlash2burst(UWORD32 FlashAddress , UWORD32 EmifSlowCSAddress);

#endif /* _FLASH__HH */

⌨️ 快捷键说明

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