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

📄 fastcopy.a51

📁 U盘控制器USB97C223的固件代码,对2kPAGE NAND FLASH 有很好的支持.
💻 A51
字号:
;/*============================================================================
;  ____________________________________________________________________________
;                                ______________________________________________
;   SSSS  M   M          CCCC          Standard Microsystems Corporation
;  S      MM MM   SSSS  C                    Austin Design Center
;   SSS   M M M  S      C                 11000 N. Mopac Expressway
;      S  M   M   SSS   C                Stonelake Bldg. 6, Suite 500
;  SSSS   M   M      S   CCCC                Austin, Texas 78759
;                SSSS            ______________________________________________
;  ____________________________________________________________________________
;
;  Copyright(C) 1999, Standard Microsystems Corporation
;  All Rights Reserved.
;
;  This program code listing is proprietary to SMSC and may not be copied,
;  distributed, or used without a license to do so.  Such license may have
;  Limited or Restricted Rights. Please refer to the license for further
;  clarification.
;  ____________________________________________________________________________
;
;  Notice: The program contained in this listing is a proprietary trade
;  secret of SMSC, Hauppauge, New York, and is copyrighted
;  under the United States Copyright Act of 1976 as an unpublished work,
;  pursuant to Section 104 and Section 408 of Title XVII of the United
;  States code. Unauthorized copying, adaption, distribution, use, or
;  display is prohibited by this law.
;  ____________________________________________________________________________
;
;  Use, duplication, or disclosure by the Government is subject to
;  restrictions as set forth in subparagraph(c)(1)(ii) of the Rights
;  in Technical Data and Computer Software clause at DFARS 52.227-7013.
;  Contractor/Manufacturer is Standard Microsystems Corporation,
;  80 Arkay Drive, Hauppauge, New York, 1178-8847.
;  ____________________________________________________________________________
;  ____________________________________________________________________________
;
;  fastcopy.a51 - Fast Memcopy function.
;  ____________________________________________________________________________
;
;  comment
;  ____________________________________________________________________________
;
;  Revision History
;  Date      Who  Comment
;  ________  ___  _____________________________________________________________
;  02/11/03  sbs   A low level fast copy fuction , primarily designed to handle the SD 1.1 bug for
;                         210, the Macro used in  the previous versions takes 1.2k of valuable code space
;                         this function helps maintain a smilar copy speed with very little code space. 
;  03/20/03  ds    The assembly code was starting off at the wrong address to copy. This caused it to copy
;                   65 bytes instead of 64. This also overwrote the data in the immediate next xdata location.And
;                   hence caused a series of bugs in 210, 1.1 speed testing. Fixed it..Sigh!
;  03/20/03  ds    Fixed the above issue by modifying the buffer size temp_buf, increasing it by one.
;============================================================================*/

;------------------------------------------------------------------------------------------------- 
;These utilities are used to copy a 64 byte buffer(Bulk Pipe), to internal SRAM. fuctions are callable from C and
; pass no parameters.
;------------------------------------------------------------------------------------------------
NAME	NEW
?PR?_sd_copy_buf_to_xdata?NEW            SEGMENT CODE 
?PR?_sd_copy_xdata_to_buf?NEW            SEGMENT CODE 
	EXTRN	XDATA (temp_buf)
	PUBLIC	_sd_copy_xdata_to_buf	 
	PUBLIC	_sd_copy_buf_to_xdata
        
           RSEG  ?PR?_sd_copy_buf_to_xdata?NEW
;----------------------------------------------------------------------------------------
; 
;
;
;-----------------------------------------------------------------------------------------
_sd_copy_buf_to_xdata:
           MOV   DPTR,#(temp_buf+040h)
LOOP:  MOV   A,09fH
           MOVX  @DPTR,A
           DJNZ  DPL,LOOP
           RET  	
;----------------------------------------------------------------------------------------
;
;
;
;-----------------------------------------------------------------------------------------
            RSEG  ?PR?_sd_copy_xdata_to_buf?NEW
_sd_copy_xdata_to_buf:
             MOV DPTR,#(temp_buf+040h)
LOOP1:  MOVX A,@DPTR        
             MOV 09fH,A
             DJNZ  DPL,LOOP1  
             RET  	
             END
;----------------------------eof                            

⌨️ 快捷键说明

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