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

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

?? sst39vf640xb.cpp

?? 單片機驅動SST公司16位Nor flash器件SST640X的源代碼
?? CPP
?? 第 1 頁 / 共 3 頁
字號:
/*                                                                      */
/* Output:                                                              */
/*          None                                                        */
/************************************************************************/
void SecID_Query(WORD *SST_SecID, WORD *User_SecID)
{
    WORD index;
         //  Issue the SecID Entry code to 39VF640X
    *sysAddress(0x555) = 0x00AA;  // write data 0x00AA to device addr 0x555
    *sysAddress(0x2AA) = 0x0055;  // write data 0x0055 to device addr 0x2AA
    *sysAddress(0x555) = 0x0088;  // write data 0x0088 to device addr 0x555
    Delay_150_Nano_Seconds();      // insert delay time = Tida

    	//  Perform all Security ID operations here:
    	//  	SST programmed segment is from address 000000H--000007H,
    	//  	User programmed segment is from address 000010H--000017H.

    for (index = 0x0000; index <= 0x0007; index++)
    {
    	 *SST_SecID = *sysAddress(index);
         ++SST_SecID;
         *User_SecID = *sysAddress(index+0x0010);
         ++User_SecID;
	// Security query data is stored in user-defined memory space.
    }
        // Issue the Sec ID Exit code thus returning the 39VF640X
        // to the read operating mode
    *sysAddress(0x555) = 0x00AA;  // write data 0x00AA to device addr 0x555
    *sysAddress(0x2AA) = 0x0055;  // write data 0x0055 to device addr 0x2AA
    *sysAddress(0x555) = 0x00F0;  // write data 0x00F0 to device addr 0x555
    Delay_150_Nano_Seconds();      // insert delay time = Tida
}


/************************************************************************/
/* PROCEDURE:   Erase_One_Sector                                        */
/*                                                                      */
/* This procedure can be used to erase a total of 2048 words.           */
/*                                                                      */
/* Input:                                                               */
/*      Dst     DESTINATION address where the erase operation starts    */
/*                                                                      */
/* Output:                                                              */
/*          return TRUE:  indicates success in sector-erase             */
/*          return FALSE: indicates failure in sector-erase             */
/************************************************************************/
int Erase_One_Sector(Uint32 Dst)
{
	Uint32 DestBuf = Dst;
   int  ReturnStatus;

	//  Issue the Sector Erase command to 39VF640X
	*sysAddress(0x555) = 0x00AA;     // write data 0x00AA to device addr 0x555
	*sysAddress(0x2AA) = 0x0055;     // write data 0x0055 to device addr 0x2AA
	*sysAddress(0x555) = 0x0080;     // write data 0x0080 to device addr 0x555
	*sysAddress(0x555) = 0x00AA;     // write data 0x00AA to device addr 0x555
	*sysAddress(0x2AA) = 0x0055;     // write data 0x0055 to device addr 0x2AA
	*sysAddress(DestBuf) = 0x0050;    // write data 0x0050 to device sector addr

   ReturnStatus = Check_Toggle_Ready(DestBuf);	// wait for TOGGLE bit ready

   return ReturnStatus;
}


/************************************************************************/
/* PROCEDURE:   Erase_One_Block                                         */
/*                                                                      */
/* This procedure can be used to erase a total of 32K words.            */
/*                                                                      */
/* Input:                                                               */
/*      Dst     DESTINATION address where the erase operation starts    */
/*                                                                      */
/* Output:                                                              */
/*          return TRUE:  indicates success in block-erase              */
/*          return FALSE: indicates failure in block-erase              */
/************************************************************************/
int Erase_One_Block (Uint32 Dst)
{
   Uint32 DestBuf = Dst;
   int ReturnStatus;

    //  Issue the Block Erase command to 39VF640X
	*sysAddress(0x555) = 0x00AA;     // write data 0x00AA to device addr 0x555
	*sysAddress(0x2AA) = 0x0055;     // write data 0x0055 to device addr 0x2AA
	*sysAddress(0x555) = 0x0080;     // write data 0x0080 to device addr 0x555
	*sysAddress(0x555) = 0x00AA;     // write data 0x00AA to device addr 0x555
	*sysAddress(0x2AA) = 0x0055;     // write data 0x0055 to device addr 0x2AA
	*sysAddress(DestBuf) = 0x0030;    // write data 0x0030 to device sector addr

   ReturnStatus = Check_Toggle_Ready(DestBuf);	  	// wait for TOGGLE bit ready

   return ReturnStatus;
}


/************************************************************************/
/* PROCEDURE:   Erase_Entire_Chip                                       */
/*                                                                      */
/* This procedure can be used to erase the entire chip.                 */
/*                                                                      */
/* Input:                                                               */
/*      NONE                                                            */
/*                                                                      */
/* Output:                                                              */
/*      NONE                                                            */
/************************************************************************/
int Erase_Entire_Chip(void)
{
   //  Issue the Chip Erase command to 39VF640X
	*sysAddress(0x555) = 0x00AA;     // write data 0x00AA to device addr 0x555
	*sysAddress(0x2AA) = 0x0055;     // write data 0x0055 to device addr 0x2AA
	*sysAddress(0x555) = 0x0080;     // write data 0x0080 to device addr 0x555
	*sysAddress(0x555) = 0x00AA;     // write data 0x00AA to device addr 0x555
	*sysAddress(0x2AA) = 0x0055;     // write data 0x0055 to device addr 0x2AA
	*sysAddress(0x555) = 0x0010;     // write data 0x0010 to device addr 0x555

   //Delay_50_Milli_Seconds();       	// Delay Tsce time
   if (Check_Data_Polling (0,0xFFFF))
   	return TRUE;
   else
    return FALSE;
}


/************************************************************************/
/* PROCEDURE:   Program_One_Word                                        */
/*                                                                      */
/* This procedure can be used to program ONE word of data to the        */
/* 39VF640X.                                                            */
/*                                                                      */
/* NOTE:  It is necessary to first erase the sector containing the      */
/*        word to be programmed.                                	*/
/*                                                                      */
/* Input:                                                               */
/*           SrcWord The WORD which will be written to the 39VF640XB    */
/*           Dst     DESTINATION address which will be written with the */
/*                   data passed in from Src                            */
/*                                                                      */
/* Output:                                                              */
/*          return TRUE:  indicates success in word-program             */
/*          return FALSE: indicates failure in word-program             */
/************************************************************************/
int Program_One_Word (WORD *SrcWord,   Uint32 Dst)
{
    Uint32 DestBuf = Dst;
    WORD *SourceBuf = SrcWord;
    int ReturnStatus;

    *sysAddress(0x555) = 0x00AA; // write data 0x00AA to device addr 0x555
    *sysAddress(0x2AA) = 0x0055; // write data 0x0055 to device addr 0x2AA
    *sysAddress(0x555) = 0x00A0; // write data 0x00A0 to device addr 0x555
    *sysAddress(DestBuf) = *SourceBuf; // transfer the WORD to destination

    ReturnStatus = Check_Toggle_Ready(DestBuf); // wait for TOGGLE bit ready

    return ReturnStatus;
}


/************************************************************************/
/* PROCEDURE:   Program_One_Sector                                      */
/*                                                                      */
/* This procedure can be used to program a total of 2048 words of data  */
/* to the SST39VF640X.                                                  */
/*                                                                      */
/* NOTES: 1. It is necessary to first erase the sector before the	*/
/*        programming.                                			*/
/*        2. This sample code assumes the destination address passed	*/
/*        from the calling function is the starting address of the	*/
/*        sector.							*/
/*                                                                      */
/* Input:                                                               */
/*           Src     SOURCE address containing the data which will be   */
/*                   written to the 39VF640XB                            */
/*           Dst     DESTINATION address which will be written with the */
/*                   data passed in from Src                            */
/*                                                                      */
/* Output:                                                              */
/*          return TRUE:  indicates success in sector-program           */
/*          return FALSE: indicates failure in sector-program           */
/************************************************************************/
int Program_One_Sector (WORD *Src, Uint32 Dst)
{

    WORD *SourceBuf;
    Uint32 DestBuf;
    int Index, ReturnStatus;

    SourceBuf = Src;
    DestBuf = Dst;
    ReturnStatus = Erase_One_Sector(DestBuf);	// erase the sector first
    if (!ReturnStatus)
    	return ReturnStatus;

    for (Index = 0; Index < SECTOR_SIZE; Index++)
    { 	// transfer data from source to destination
	ReturnStatus = Program_One_Word( SourceBuf, DestBuf);
	++DestBuf;
	++SourceBuf;

        if (!ReturnStatus)
    	   return ReturnStatus;
    }

    return ReturnStatus;
}


/************************************************************************/
/* PROCEDURE:   Program_One_Block                                       */
/*                                                                      */
/* This procedure can be used to program a total of 32k words of data   */
/* to the SST39VF640XB.                                                  */
/*                                                                      */
/* NOTES: 1. It is necessary to first erase the block before the	*/
/*        programming.                                			*/
/*        2. This sample code assumes the destination address passed	*/
/*        from the calling function is the starting address of the	*/
/*        block.							*/
/*									*/
/* Input:                                                               */
/*           Src     SOURCE address containing the data which will be   */
/*                   written to the 39VF640X                            */
/*           Dst     DESTINATION address which will be written with the */
/*                   data passed in from Src                            */
/*                                                                      */
/* Output:                                                              */
/*          return TRUE:  indicates success in block-program            */
/*          return FALSE: indicates failure in block-program            */
/************************************************************************/
int Program_One_Block (WORD *Src, Uint32 Dst)
{
    WORD *SourceBuf;
    Uint32 DestBuf;
    int Index, ReturnStatus;

    SourceBuf = Src;
    DestBuf = Dst;
    ReturnStatus = Erase_One_Block(DestBuf);	// erase the block first
    if (!ReturnStatus)
    	return ReturnStatus;

    for (Index = 0; Index < BLOCK_SIZE; Index++)

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
欧美精品一区二区蜜臀亚洲| 91精品国产综合久久香蕉的特点 | 久久亚洲一区二区三区明星换脸| 欧美网站大全在线观看| 91免费国产在线| 91玉足脚交白嫩脚丫在线播放| 成人小视频在线观看| 国产精品资源网站| 国产精品自产自拍| 国产99久久久久| 高清免费成人av| 91在线观看高清| 91福利视频网站| 欧美日韩国产在线观看| 欧美人妖巨大在线| 欧美精品免费视频| 欧美一区二区三区在| 日韩精品中文字幕在线不卡尤物| 日韩一区二区三区电影在线观看| 日韩欧美久久一区| 久久伊人中文字幕| 国产女主播视频一区二区| 国产女同性恋一区二区| 久久国产精品72免费观看| 天天色综合天天| 国产白丝精品91爽爽久久| 麻豆91在线播放免费| 亚洲国产精品一区二区www在线| 国产欧美1区2区3区| 亚洲精品国产第一综合99久久| 26uuu精品一区二区三区四区在线| 4438亚洲最大| 日韩丝袜情趣美女图片| 亚洲精品成人悠悠色影视| 日韩欧美高清一区| 国产欧美视频一区二区三区| 国产精品成人免费在线| 亚洲国产综合色| 久久国产精品72免费观看| 国产福利一区二区三区视频| 色94色欧美sute亚洲线路一ni| 欧美日产国产精品| 久久一二三国产| 亚洲乱码国产乱码精品精的特点 | 欧美日韩情趣电影| 精品久久人人做人人爽| 国产精品欧美久久久久无广告| 一级精品视频在线观看宜春院| 蜜桃av一区二区| 风间由美性色一区二区三区| 欧美日韩精品一区二区三区| 久久久久久亚洲综合影院红桃 | 暴力调教一区二区三区| 欧美日韩亚洲综合在线| 久久婷婷综合激情| 亚洲国产视频一区| 国产精品一区专区| 欧美丰满少妇xxxxx高潮对白| 国产夜色精品一区二区av| 亚洲影视在线播放| 国产乱理伦片在线观看夜一区| 在线欧美日韩国产| 国产欧美1区2区3区| 免费观看久久久4p| 99久久精品免费看| 一区二区三区欧美在线观看| 国产一区在线精品| 欧美伦理影视网| 亚洲人一二三区| 国产伦精一区二区三区| 91精品国产综合久久精品麻豆| 国产精品理论在线观看| 紧缚奴在线一区二区三区| 欧美日韩久久久一区| 久久精品亚洲精品国产欧美| caoporen国产精品视频| 国产精品三级av在线播放| 久久99精品久久久久久久久久久久| 91久久精品一区二区三| 国产午夜精品久久| 久久成人免费网| 日韩欧美一级二级三级久久久| 亚洲成人黄色小说| 欧亚洲嫩模精品一区三区| 婷婷国产v国产偷v亚洲高清| 精品视频在线免费| 中文字幕一区三区| 国产伦精品一区二区三区视频青涩| 7777精品伊人久久久大香线蕉的| 亚洲婷婷综合久久一本伊一区| 国产精品中文欧美| 欧美r级在线观看| 日本中文在线一区| 欧美美女视频在线观看| 亚洲制服欧美中文字幕中文字幕| 国产91精品一区二区麻豆亚洲| 欧美精品一区二区三区在线 | 亚洲天堂精品在线观看| 国产大片一区二区| 久久精品亚洲一区二区三区浴池| 美女尤物国产一区| 日韩一级在线观看| 青椒成人免费视频| 91精品国产91久久综合桃花| 五月婷婷久久丁香| 欧美精品久久久久久久多人混战| 午夜亚洲国产au精品一区二区| 中文字幕高清一区| 国产乱子伦一区二区三区国色天香| 欧美v亚洲v综合ⅴ国产v| 免费在线观看不卡| 欧美电视剧在线看免费| 麻豆精品久久久| www一区二区| 国产毛片精品国产一区二区三区| 国产婷婷色一区二区三区四区 | 7777精品伊人久久久大香线蕉的| 日精品一区二区三区| 91精品黄色片免费大全| 久久99最新地址| 国产视频一区二区在线| www.视频一区| 亚洲人成网站在线| 欧美天天综合网| 青青国产91久久久久久| 欧美成人vr18sexvr| 国产精品99久| 亚洲欧美日韩一区二区 | 久久日一线二线三线suv| 粉嫩久久99精品久久久久久夜| 亚洲丝袜美腿综合| 欧美日韩一区 二区 三区 久久精品| 日本sm残虐另类| 久久综合久久鬼色中文字| 成人视屏免费看| 亚洲国产成人va在线观看天堂| 日韩免费高清av| 成人视屏免费看| 午夜久久久久久久久| 久久青草欧美一区二区三区| 一本久道中文字幕精品亚洲嫩| 日日噜噜夜夜狠狠视频欧美人| 久久麻豆一区二区| 色吊一区二区三区| 精品一二线国产| 亚洲欧美激情小说另类| 精品国偷自产国产一区| 99国产精品久久久| 日韩综合小视频| 国产精品传媒视频| 这里只有精品99re| 成人av中文字幕| 蜜臀av性久久久久蜜臀av麻豆| 日韩一区中文字幕| 4hu四虎永久在线影院成人| 丁香网亚洲国际| 日韩制服丝袜av| 国产精品毛片高清在线完整版| 91精品欧美久久久久久动漫| 国产宾馆实践打屁股91| 偷拍亚洲欧洲综合| 国产精品久久免费看| 欧美一级片在线看| 色综合 综合色| 国内精品免费**视频| 色猫猫国产区一区二在线视频| 久久国产精品第一页| 亚洲综合在线第一页| 国产日产亚洲精品系列| 这里只有精品视频在线观看| 色婷婷综合在线| 国产福利一区二区三区视频在线 | 亚洲乱码精品一二三四区日韩在线| 欧美videos大乳护士334| 日本乱人伦一区| 成人深夜福利app| 国产一区二区三区精品视频| 日本麻豆一区二区三区视频| 一区二区成人在线观看| 国产精品少妇自拍| 欧美成人a在线| 欧美日韩精品一区二区三区蜜桃| 91丨九色丨国产丨porny| 国产盗摄女厕一区二区三区| 久久69国产一区二区蜜臀| 亚洲小说欧美激情另类| 国产精品乱码一区二区三区软件| 欧美一级电影网站| 欧美人牲a欧美精品| va亚洲va日韩不卡在线观看| 高清不卡一区二区| 青娱乐精品视频| 亚洲丰满少妇videoshd| 亚洲精品国产无天堂网2021| 精品国产123| 91麻豆精品国产91久久久久| 国产伦精品一区二区三区视频青涩 | 欧美日韩夫妻久久| 99久久国产综合精品麻豆| 欧美日韩在线一区二区|