Texas Instruments TMS320F20x/F24x DSP manual Preliminary, Assembly Source for Algorithms, A-26

Models: TMS320F20x/F24x DSP

1 108
Download 108 pages 2.5 Kb
Page 78
Image 78
A-26

Assembly Source for Algorithms

PRELIMINARY

SPLK #0000h,SPAD2

***********The next instruction is for F240 only*************

.if

F24X = 1

;Assemble for F24X only.

OUT

SPAD2,F24X_ACCS

;Enable F240 flash reg mode.

 

 

;SPAD1 is dummy value.

.endif

 

 

*************************************************************

.if

F24X = 0

;Assemble for F206 only.

LACC

FL_ST

 

SUB

#4000h

 

BCND

reg1,geq

;if address>= 4000h,set

 

 

;set reg mode for flash1 array

OUT

SPAD2,F_ACCESS0

;Change mode of flash0.

RET

 

 

reg1 OUT

SPAD2,F_ACCESS1

;Change mode of flash1.

.endif

 

 

RET

 

;RETURN TO CALLING SEQUENCE

.page

****************************************************

*ARRAY Sets MODE bit of F_ACCESS0/1 to access **

* the flash array.**

****************************************************

.sect ºARYº

ARRAY

SPLK #0001h,SPAD2

***********The next instruction is for F240 only*************

.if

F24X = 1

;Assemble for F240 only.

IN

SPAD1,F24X_ACCS

;Enable F240 flash array mode.

 

 

;SPAD1 is dummy value.

.endif

 

 

*************************************************************

.if

F24X = 0

;Assemble for F206 only.

LACC

FL_ST

 

SUB

#4000h

 

BCND

ary1,geq

;if address>= 4000h,set

 

 

;set reg mode for flash1 array

OUT

SPAD2,F_ACCESS0

;Change mode of flash0.

RET

 

 

ary1 OUT

SPAD2,F_ACCESS1

;Change mode of flash1.

.endif

 

 

RET

 

;RETURN TO CALLING SEQUENCE

.end

A-26

PRELIMINARY

Page 78
Image 78
Texas Instruments TMS320F20x/F24x DSP manual Preliminary, Assembly Source for Algorithms, A-26