Instruction Syntax and Addressing Modes
4-21
Assembly Language Instructions
However, xFLAG instructions use {flagadrs} addressing modes. This includes
global (dma6) and relative (R6 + 6–bit offset). Both take only one clock cycle.
Possible sources of confusion: Consider the following code,
ram0
equ 0x0000 *2 ;RAM word zero
ram1
equ 0x0001 *2 ;RAM word one
ram2
equ 0x0002 *2 ;RAM word two
STAG
*ram1
MOV
A0,*ram1
;TAG bit is set in STAT register
RTAG
*ram1
SFLAG *ram1
;This sets the TAG bit of ram2!
MOV
A0,*ram1
;TAG bit is not set in STAT register!
MOV
TF1,*ram1
;TF1 bit in STAT is set!?
Explanation: The first three instructions perform as you would expect. The
TAG bit is set at the RAM variable, ram1. The TAG bit is set in the STAT register
when the MOV instruction executes. Finally, ram1’s TAG bit is cleared.
The next two instructions are problematic. When SFLAG sets the tag bit, it will
set the tag bit for the second word location, ram2. This does not set the TAG
bit for ram1. What is worse is that the value in ram1 must be less than 64
(dma6) since this is global addressing for SFLAG. To access TAG bits for high-
er RAM, the R6 (PAGE) register is needed.
The last instruction is also confusing. Why is TF1 set in the STAT even though
ram1’s TAG bit is not set? The answer is that this MOV instruction considers
the {src} argument to be a word value instead of the usual byte value. Thus,
this MOV instruction operates on ram2 rather than on ram1.
Содержание MSP50C614
Страница 1: ...MSP50C614 Mixed Signal Processor User s Guide SPSU014 January 2000 Printed on Recycled Paper ...
Страница 6: ...vi ...
Страница 92: ...3 22 ...
Страница 300: ...Instruction Set Summay 4 208 Assembly Language Instructions ...
Страница 314: ...Software Emulator 5 14 Figure 5 13 Project Menu Figure 5 14 Project Open Dialog ...
Страница 325: ...Software Emulator 5 25 Code Development Tools Figure 5 25 EPROM Programming Dialog ...
Страница 331: ...Software Emulator 5 31 Code Development Tools Figure 5 31 Context Sensitive Help System ...
Страница 368: ...5 68 ...
Страница 394: ...7 12 ...
Страница 400: ...Architecture A 6 Figure A 3 MSP50C605 100 Pin PJM Package MSP50C605 100 PIN PJM PLASTIC PACKAGE 1 80 81 100 30 31 50 51 ...
Страница 402: ...A 8 ...
Страница 412: ...Packaging B 10 ...
Страница 414: ...C 2 C 1 MSP50C605 Data Sheet This appendix contains the data sheet for the MSP50C605 mixed signal pro cessor ...