📄 cfft_izc.asm
字号:
;============================================================================
;
; File Name : cfft_izc.asm
;
; Originator : Digital Control Systems Group
; Texas Instruments
;
; Description : This file contains source code to zero the imaginary parts of
; the complex input to the FFT module.
;
; Date : 26/4/2001 (dd/mm/yyyy)
;===========================================================================
; Routine Type : C Callable
;
; Description :
; void FFTC_izc(FFTxxxC_handle)
; This function zeros the imaginary part of the complex input, in the case of
; Complex FFT modules.
;
;======================================================================
; COMPLEX FFT MODULES
;----------------------------------------------------------------------
;typedef struct {
; int *ipcbptr;
; int *magptr;
; int peakmag;
; int peakfrq;
; int normflag;
; int size;
; int *winptr;
; void (*init)(void);
; void (*izero)(void *);
; void (*calc)(void *);
; void (*mag)(void *);
; void (*win)(void *);
; }FFTxxxC;
;======================================================================
; Function Local Frame
;======================================================================
; |_______|
; |_______|<- Stack Pointer (FP+1) <---AR1
; |_______|<- Reg to Reg Tfr (FP) <---AR4
; |_______|<- Old FP (AR0) (FP-1)
; |_______|<- Return Address of the Caller (FP-2)
; |_______|<- Module Handle (FP-3)
;
;======================================================================
__FFTC_izero_frs .set 00001h ; Local frame size for this routine
.def _FFTC_izero ;
_FFTC_izero:
POPD *+ ; Store the Return Address in stack
SAR AR0,*+ ; Store the Caller's Frame Pointer
SAR AR1,*
LAR AR2,*
LAR AR0,#__FFTC_izero_frs
LAR AR4,*0+,AR2 ; Create Local frame
SBRK #3 ; ARP=AR2, AR2=FP-3->FFTxxxC_handle
LAR AR2,* ; ARP=AR2, AR2=FFTxxxC_handle->ipcbptr
; Fill the imaginary part of the samples with ZERO
LAR AR3,*,AR3 ; ARP=AR3, AR3=ipcbptr
MAR *+,AR2 ; ARP=AR2, AR2->ipcbptr, AR3=ipcbptr+1
ADRK #5 ; ARP=AR2, AR2->size
LACL *,AR4 ; ARP=AR4, AR4=FP, ACCL=size
SUB #1 ; ARP=AR4, AR4=FP, ACCL=size-1
SACL * ; ARP=AR4, AR4=FP, (FP)=size-1
LAR AR0,#2 ; ARP=AR4, AR4=FP, AR0=2
LACL #0
RPT *,AR3
SACL *0+
MAR *,AR1
SBRK #(__FFTC_izero_frs+1) ; Clear the local frame
LAR AR0,*- ; Retrive Caller's frame pointer
PSHD * ; Push the return address to TOS
RET
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -