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

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

?? device.c

?? intel strata flash TE28Fxx系列的源代碼 nor flash
?? C
?? 第 1 頁 / 共 3 頁
字號:
/*************************************************************************
 *** Intel Confidential                                      
 *** Copyright (C) Intel Corporation 2000                 
 *** All Rights Reserved.                                    
 *** --------------------------------------------------------------------
 ***
 *** Project Name: Flash Templates
 ***
 *** Module Name: Device
 ***
 *** File: Device.C - J3 device specific template source file
 ***
 *** File Revision: $Revision: 6 $, $JustDate:  5/11/00 $, $Author: Kalowry $
 ***
 *** Purpose:
 ***
 ***    The purpose of this file is to implement the J3 device specific
 ***    functionality for the J3 template package.  This module
 ***    implements only those functions which have J3 device specific
 ***    implementations.  The remaining functions which complete
 ***    the template application programmers interface are implemented
 ***    by the template.c source module.
 ***
 *** $NoKeywords: $
 *************************************************************************/
/*
***************************************************************
* INTEL OEM SOFTWARE LICENSE AGREEMENT
* BETWEEN INTEL CORPORATION AND OEM/Licensee ("You")
*  (Rev 10/04/99)
*
* BY USING THIS SOFTWARE, YOU ("You" or "Licensee") ARE AGREEING 
* TO BE BOUND BY THE TERMS OF THIS AGREEMENT.  DO NOT USE THE 
* SOFTWARE UNTIL YOU HAVE CAREFULLY READ AND AGREED TO THE 
* FOLLOWING TERMS AND CONDITIONS.  IF YOU DO NOT AGREE TO THE 
* TERMS OF THIS AGREEMENT, PROMPTLY RETURN THE SOFTWARE AND ANY 
* ACCOMPANYING ITEMS. LICENSEE MUST BE AN ORIGINAL EQUIPMENT 
* MANUFACTURER ("OEM") SYSTEM DEVELOPER TO ACQUIRE ANY RIGHTS 
* IN THE SOFTWARE UNDER THIS LICENSE AGREEMENT.
*
* LICENSE: Intel Corporation ("Intel") grants the Licensee the 
* non-exclusive right to use the software program ("Software") 
* in source and / or object code form on the terms set forth 
* below.  Licensee will not use, copy, modify, rent, sell or 
* transfer the Software or any portion thereof, except as 
* provided in this Agreement.  
*
* USE RESTRICTION:
* THIS ROYALTY FREE LICENSE ALLOWS LICENSEE TO USE THE SOFTWARE 
* WITH INTEL FLASH PRODUCTS ONLY. USE OF THE SOFTWARE WITH ANY 
* OTHER FLASH PRODUCTS IS EXPRESSLY PROHIBITED UNLESS AND UNTIL 
* LICENSEE APPLIES FOR, AND IS GRANTED, IN INTEL'S SOLE DISCRETION.
* A SEPARATE WRITTEN SOFTWARE LICENSE AGREEMENT BETWEEN LICENSEE 
* AND INTEL IS NECESSARY BEFORE ANY SUCH USE.
*
* LICENSEE MAY:
* 1. Copy the Software for support, backup or archival purposes;
* 2. Install or distribute the Software in object code form only;
* 3. Install, use, modify, distribute, and/or make or have made 
* Derivatives based on the Software subject to the terms and 
* conditions in this Agreement;
* 4. Modify and/or use Software source code that Intel provides to
* the Licensee, provided that Licensee does not remove or modify 
* the "Compatibility" module, if any, in the Software or in any 
* Derivatives and subject to the other restrictions contained 
* herein;
* 5. Allow authorized contractors ("Subcontractors") engaged by 
* the Licensee for the sole purpose of product development work to
* have access to the Software solely for that purpose. 
* Subcontractors do NOT acquire any of the Licensee rights to the 
* Software provided in this Agreement.
*
* RESTRICTIONS:  
* LICENSEE IS NOT ALLOWED TO: 
* 1.  Copy, disclose or distribute the Software, in whole or in 
* part, except as provided for in this Agreement;
* 2.  Remove or modify the "Compatibility" module, if any, in 
* the Software or in any Derivatives;
* 3.  Decompile or reverse engineer any Software delivered in 
* object code form.
*
* LICENSEE MUST:
* Execute the "Compatibility" module if provided with the 
* Software.
*
* TRANSFER:  Except as provided above, Licensee may not 
* transfer or disclose the Software to any other party.
*
* OWNERSHIP AND COPYRIGHT OF SOFTWARE: Title to the Software 
* and all copies thereof remain with Intel.  The Software is 
* copyrighted and is protected by United States and 
* international copyright laws.  Licensee will not remove 
* the copyright notice from the Software.  Licensee agrees 
* to prevent the unauthorized copying of the Software.
*
* DERIVATIVES: "Derivatives" are any work that is based upon the 
* Software, such as a revision, modification, translation, or 
* compilation in which the Software is recast, transformed or 
* adapted; any adaptation, subset, addition, improvement or 
* combination of or including the Software; and any new material, 
* information or data derived from the Software, including new 
* material which may be protectable by copyright, patent or other
* proprietary rights.  Licensee is not required to provide Intel 
* with a copy of the source or object code for any Derivatives 
* created by Licensee. Licensee may use, market, sell, and/or 
* distribute Derivatives in object code form only at Licensee's own
* risk and expense.  Licensee may use, but may not market, sell or 
* distribute, source code for any Derivatives, subject to the Use 
* Restriction and other restrictions contained in this Agreement. 
* Title to Derivatives, other than the portion(s) of the 
* Derivatives consisting of any portion of the Software, shall 
* remain with Licensee.
*
* CONFIDENTIALITY: Licensee will maintain the confidentiality of 
* the source code for the Software with at least the same degree 
* of care that Licensee uses to protect Licensee's own confidential 
* and proprietary information, but with no less than a reasonable 
* degree under the circumstances. Disclosure of source code will 
* only be made to Licensee's employees on a need-to-know basis. 
* Subject to the licenses granted hereunder, Licensee shall 
* maintain the Software source code and all other proprietary 
* information relating to the Software in confidence and shall 
* not disclose to others any such source code or other Intel 
* proprietary information relating to the Software. Any 
* Subcontractors to whom Licensee discloses the source code for 
* the Software must sign a written confidentiality agreement 
* which contains terms regarding the Software no less restrictive 
* than those set forth in this Agreement.
*
* WARRANTY:  The Software is provided "AS IS". Intel warrants 
* that the media on which the Software is furnished will be free 
* from defects in material and workmanship for a period of one 
* year upon receipt. 
*
* THE ABOVE WARRANTIES ARE THE ONLY WARRANTIES OF ANY KIND GIVEN 
* BY INTEL UNDER THIS AGREEMENT. INTEL SPECIFICALLY DISCLAIMS ANY 
* OTHER WARRANTIES, EXPRESS OR IMPLIED, INCLUDING WARRANTIES OF 
* MERCHANTABILITY, NONINFRINGEMENT OR FITNESS FOR ANY PARTICULAR 
* PURPOSE.
*
* LIMITATION OF LIABILITY: NEITHER INTEL NOR ITS VENDORS OR AGENTS 
* SHALL BE LIABLE FOR ANY LOSS OF PROFITS, LOSS OF USE, LOSS OF 
* DATA, INTERRUPTION OF BUSINESS, NOR FOR INDIRECT, SPECIAL, 
* INCIDENTAL OR CONSEQUENTIAL DAMAGES OF ANY KIND WHETHER UNDER 
* THIS AGREEMENT OR OTHERWISE, EVEN IF ADVISED OF THE POSSIBILITY 
* OF SUCH DAMAGES.
*
* TERMINATION OF THIS LICENSE: Intel reserves the right to conduct 
* or have conducted audits to verify Licensee's compliance with 
* this Agreement.  Intel may terminate this Agreement at any 
* time if Licensee is in breach of any of its terms and conditions.
* Upon termination, Licensee will immediately destroy, and certify 
* in writing the destruction of, the Software and return all copies 
* of the Software and documentation to Intel.
*
* U.S. GOVERNMENT RESTRICTED RIGHTS: The Software and documentation
* were developed at private expense and are provided with 
* "RESTRICTED RIGHTS".  Use, duplication or disclosure by the 
* Government is subject to restrictions as set forth in 
* FAR52.227-14 and DFAR252.227-7013 et seq. or its successor.
*
* EXPORT LAWS: The distribution and export/re-export of the 
* Software shall be in compliance with the laws, regulations, 
* orders or other restrictions of the U.S. Export Administration 
* Regulations.
*
* APPLICABLE LAW: This Agreement is governed by the laws of the 
* State of Delaware and the United States, including patent and
* copyright laws.  Any claim arising out of this Agreement will be 
* brought in Delaware.  
*
* Intel reserves the right to use and/or include Licensee's name
* in public relations activities and marketing material after the 
* product is publicly announced.
*****************************************************************
*/
/* Page Break  */
/* Include Files */

#include "template.h"


/*
 * Global Functions
 */ 


/****************************************************************************
 *
 * TMPL_EraseAllBlocks
 *
 * Description:   
 *
 *    This procedure is called to erase all data blocks on the flash 
 *    device.  See the flash device datasheet for specific details on
 *    the block erase command.
 *
 * Parameters:
 *
 *    IN      returnSR - flag to indicate whether the device status register
 *                       value should be returned by this function.
 *
 * Returns:   
 *
 *    TMPL_Status - includes function return status defined by enum
 *                  TMPL_CommandStat and optionally the flash device
 *                  status register value.
 *
 * Assumptions:
 *
 *    NONE
 *
 ***************************************************************************/
TMPL_Status TMPL_EraseAllBlocks ( UINT8 returnSR )
{

	TMPL_Status stat;
	UINT16 block;

	for ( block=0; block < TMPL_TOTAL_NUMBLOCKS; block++ )
	{
		stat = TMPL_EraseBlock( block, returnSR );

		if ( stat.Result != StatCompleted )
		{
			return( stat );
		}
	}

	return( stat );

}


/****************************************************************************
 *
 * TMPL_EraseSuspend
 *
 * Description:   
 *
 *    This procedure is called to issue the erase suspend command to
 *    the flash device.  See the flash device datasheet for specific details 
 *    on this command.
 *
 * Parameters:
 *
 *    IN      blocknum - the block number on the device.
 *
 *    IN      returnSR - flag to indicate whether the device status register
 *                       value should be returned by this function.
 *
 * Returns:   
 *
 *    TMPL_Status - includes function return status defined by enum 
 *                  TMPL_CommandStat and optionally the flash device 
 *                  status register value.
 *
 * Assumptions:
 *
 *    When this function is called the device is currently in the erase 
 *    mode for the block identified.
 *
 ***************************************************************************/
TMPL_Status TMPL_EraseSuspend ( UINT16 blocknum, 
                                UINT8  returnSR )
{

	TMPL_Status stat;
	UINT32      blockaddr;
	TMPL_FDATA  status;

	stat = TMPL_GetBlockAddress( blocknum, &blockaddr );

	if ( stat.Result != StatCompleted )
	{
		return( stat );
	}

	if ( returnSR )
	{
		TMPL_ClearStatus();
	}

	TMPL_WriteF( blockaddr, TMPL_BLOCK_SUSPEND );

	if ( !TMPL_WaitUntilReady( TMPL_PROGRAM_TIMEOUT ) )
	{
		stat.Result = StatTimeout;
	}
	else
	{
		stat.Result = StatCompleted;
	}

	if ( returnSR )
	{
		stat.SR = TMPL_ReadStatus();
	}

	/* return device to read array mode */
	TMPL_WriteF( TMPL_BASE_FLASH_ADDRESS, TMPL_READ_ARRAY );

	return( stat );
   
}


#if X_16
/****************************************************************************
 *
 * TMPL_ExtendedQuery
 *
 * Description:   
 *
 *    This procedure is called to retrieve the extended query
 *    data from the flash device.  See the flash device datasheet for
 *    specific details on this command.
 *
 * Parameters:
 *
 *    OUT      *extquery - pointer to extended query structure
 *
 * Returns:   
 *
 *    TMPL_Status - includes function return status defined by enum 
 *                  TMPL_CommandStat
 *
 * Assumptions:
 *
 *    NONE
 ***************************************************************************/
TMPL_Status TMPL_ExtendedQuery ( struct TMPL_ExtQueryData *extquery )
{

	TMPL_Status           stat;
	struct TMPL_QueryData query;
	TMPL_FDATA            item;
	UINT32                addr;
	UINT32                longitem;
	UINT32                i;
	UINT32                offset;

	stat = TMPL_Query( &query );

	if ( stat.Result != StatCompleted )
	{
		return( stat );
	}

	offset = query.ExtTablePtr;

	TMPL_WriteF( TMPL_BASE_FLASH_ADDRESS, TMPL_READ_QUERY );

	/* read extended query string */ 
	for ( i=0; i < 3; i++ )
	{
		stat = TMPL_GetQueryAddress( offset, &addr );

		if ( stat.Result != StatCompleted )
		{
			return( stat );
		}

		TMPL_ReadF( addr, &item );
		item &= 0xff;
		extquery->ExtQueryStr[i] = (char)item;
		offset++;
	}
	extquery->ExtQueryStr[3] = '\0'; /* null terminate string */

	/* read major version number */
	stat = TMPL_GetQueryAddress( offset, &addr );

	if ( stat.Result != StatCompleted )
	{
		return( stat );
	}

	TMPL_ReadF( addr, &item );
	item &= 0xff;
	extquery->MajorVersionNum = (UINT8)item;
	offset++;

	/* read minor version number */
	stat = TMPL_GetQueryAddress( offset, &addr );

	if ( stat.Result != StatCompleted )
	{
		return( stat );
	}

	TMPL_ReadF( addr, &item );
	item &= 0xff;
	extquery->MinorVersionNum = (UINT8)item;
	offset++;

	extquery->OptionalFeature = 0;
	for ( i=0; i < 4; i++ )
	{
		stat = TMPL_GetQueryAddress( offset, &addr );

		if ( stat.Result != StatCompleted )
		{
			return( stat );
		}

		TMPL_ReadF( addr, &item );
		item &= 0xff;
		longitem = (UINT32)((UINT32)item << (8*i));
		extquery->OptionalFeature = (UINT32)( extquery->OptionalFeature | longitem );
		offset++;
	}

	/* read after suspend functions */
	stat = TMPL_GetQueryAddress( offset, &addr );

	if ( stat.Result != StatCompleted )
	{
		return( stat );
	}

	TMPL_ReadF( addr, &item );
	item &= 0xff;
	extquery->AfterSuspendFunctions = (UINT8)item;
	offset++;

	/* read vendor id */
	extquery->BlockLockStatus = 0;
	for ( i=0; i < 2; i++ )
	{
		stat = TMPL_GetQueryAddress( offset, &addr );

		if ( stat.Result != StatCompleted )
		{
			return( stat );
		}

		TMPL_ReadF( addr, &item );
		item &= 0xff;
		item = item << (8*i);
		extquery->BlockLockStatus = (UINT16)( extquery->BlockLockStatus | item );
		offset++;
	}

	/* read vcc optimum */
	stat = TMPL_GetQueryAddress( offset, &addr );

	if ( stat.Result != StatCompleted )
	{
		return( stat );
	}

	TMPL_ReadF( addr, &item );
	item &= 0xff;
	extquery->VccOptimum = (UINT8)item;
	offset++;

	/* read vpp optimum */
	stat = TMPL_GetQueryAddress( offset, &addr );

	if ( stat.Result != StatCompleted )
	{
		return( stat );
	}

	TMPL_ReadF( addr, &item );
	item &= 0xff;
	extquery->VppOptimum = (UINT8)item;
	offset++;

	stat.Result = StatCompleted;

	/* return device to read array mode */
	TMPL_WriteF( TMPL_BASE_FLASH_ADDRESS, TMPL_READ_ARRAY );

	return( stat );

}
#endif /* X_16 */


/****************************************************************************
 *

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产精品1区2区3区在线观看| 欧美色男人天堂| 色综合视频一区二区三区高清| 4438x亚洲最大成人网| 国产精品久久久久影视| 久久成人免费日本黄色| 91福利在线免费观看| 国产嫩草影院久久久久| 美国欧美日韩国产在线播放| 在线免费观看一区| 中文字幕中文字幕在线一区| 国产精品99久久久久久似苏梦涵| 91精品在线麻豆| 亚洲香肠在线观看| 色综合视频在线观看| 国产精品欧美综合在线| 国产高清在线观看免费不卡| 精品伦理精品一区| 蜜臀99久久精品久久久久久软件| 欧美伦理电影网| 图片区日韩欧美亚洲| 欧美手机在线视频| 亚洲国产精品久久久久婷婷884 | 18成人在线观看| 国产精品一区二区久久精品爱涩| 69精品人人人人| 日韩制服丝袜av| 7777精品伊人久久久大香线蕉的| 视频一区二区三区在线| 91.com视频| 久久国产剧场电影| 日韩美女在线视频| 国产精品一级黄| 久久久久久99久久久精品网站| 国产乱子伦一区二区三区国色天香| 日韩精品一区在线| 国产精品系列在线观看| 国产日韩精品一区二区三区在线| 懂色av一区二区三区蜜臀| 国产免费久久精品| 色婷婷亚洲精品| 视频一区二区国产| 久久精品欧美日韩精品| 成人一二三区视频| 一区二区三区高清| 日韩一级免费一区| 国产成人免费网站| 亚洲精品久久久蜜桃| 欧美老年两性高潮| 国产综合色视频| 综合欧美亚洲日本| 在线观看91精品国产麻豆| 免费观看在线综合色| 国产日韩欧美a| 欧美最新大片在线看| 九九精品一区二区| 亚洲欧洲日韩女同| 欧美男女性生活在线直播观看| 精品一区二区三区在线观看 | 日韩三级精品电影久久久| 国产美女视频91| 亚洲精品中文字幕乱码三区| 欧美精品在线观看播放| 国产在线视频一区二区| 亚洲精品少妇30p| 欧美一级片在线观看| 国产成人av自拍| 视频一区欧美精品| 国产精品另类一区| 91精品福利在线一区二区三区| 国产一区二区在线看| 亚洲大片精品永久免费| 久久综合999| 欧美视频在线观看一区二区| 国产乱淫av一区二区三区| 天天色 色综合| 中文字幕一区二区视频| 欧美一级日韩一级| 在线亚洲一区观看| 国产suv精品一区二区6| 午夜精品福利在线| 亚洲三级小视频| 国产日韩欧美电影| 欧美mv和日韩mv的网站| 欧美日韩电影一区| 色婷婷国产精品综合在线观看| 国模冰冰炮一区二区| 日韩精品欧美精品| 亚洲一二三四区不卡| 亚洲欧洲www| 欧美国产一区在线| 精品国产乱码久久久久久免费| 欧美日韩三级视频| 91久久久免费一区二区| 91网站最新地址| 成人免费高清在线| 国产精品一级片| 国产精品一区二区不卡| 韩国三级中文字幕hd久久精品| 五月婷婷久久综合| 图片区日韩欧美亚洲| 亚洲美女屁股眼交3| 日韩一区欧美一区| 国产精品蜜臀在线观看| 国产精品免费久久| 国产精品久久午夜| 欧美高清在线一区二区| 国产目拍亚洲精品99久久精品| 久久精品欧美一区二区三区不卡| 精品sm捆绑视频| 2020国产精品久久精品美国| 精品久久五月天| 欧美不卡一区二区三区四区| 日韩欧美成人激情| 欧美成人精品高清在线播放| 精品欧美黑人一区二区三区| 日韩欧美国产综合在线一区二区三区| 欧美日韩国产天堂| 日韩一区二区在线观看视频播放| 欧美浪妇xxxx高跟鞋交| 欧美高清视频在线高清观看mv色露露十八| 欧美在线啊v一区| 欧美日韩精品是欧美日韩精品| 欧美日韩一区在线| 欧美一级二级在线观看| 欧美精品一区二区精品网| 久久久亚洲精品石原莉奈| 欧美国产禁国产网站cc| 亚洲精品午夜久久久| 亚洲电影第三页| 美女被吸乳得到大胸91| 国产精品一二三四五| 成人性生交大片免费看视频在线 | 国产成人精品免费在线| 国产成人aaa| 在线免费观看不卡av| 欧美日韩久久久| 久久久五月婷婷| 亚洲精品视频一区二区| 琪琪一区二区三区| 国产成人综合在线播放| 日本丶国产丶欧美色综合| 欧美剧在线免费观看网站| 日韩视频一区在线观看| 欧美激情一区二区三区蜜桃视频 | 亚洲欧美日韩国产一区二区三区| 亚洲你懂的在线视频| 蜜桃视频在线观看一区二区| 国产一区高清在线| 欧美曰成人黄网| 久久精品夜夜夜夜久久| 亚洲精品日日夜夜| 久久99久久久欧美国产| 99久久99久久精品国产片果冻| 欧美一级国产精品| 亚洲欧美色图小说| 国产美女精品人人做人人爽| 欧美日韩亚洲综合在线| 亚洲国产精品t66y| 青青草伊人久久| 色视频欧美一区二区三区| 久久久三级国产网站| 日韩有码一区二区三区| 91网上在线视频| 久久青草欧美一区二区三区| 午夜精品久久久久久久99樱桃| 成年人午夜久久久| xf在线a精品一区二区视频网站| 亚洲一级二级三级在线免费观看| 国产成人免费网站| 日韩欧美一区电影| 五月天国产精品| 色域天天综合网| 国产欧美1区2区3区| 毛片av中文字幕一区二区| 91亚洲精华国产精华精华液| 久久色视频免费观看| 日韩精品1区2区3区| 日本高清不卡一区| 国产精品黄色在线观看| 国产一区二区不卡老阿姨| 日韩美女视频在线| 天堂精品中文字幕在线| 欧美日本一区二区在线观看| 18涩涩午夜精品.www| 不卡电影一区二区三区| 日本一区二区在线不卡| 国产一区二区精品在线观看| 91精品免费观看| 午夜欧美电影在线观看| 欧美高清视频在线高清观看mv色露露十八| 亚洲另类在线视频| 欧洲色大大久久| 亚洲一区二区精品久久av| 在线免费av一区| 一区二区三区高清在线| 欧美日本在线一区| 奇米精品一区二区三区在线观看| 制服丝袜亚洲色图| 美洲天堂一区二卡三卡四卡视频|