English
Language : 

MC68340AB16E Datasheet, PDF (166/441 Pages) Motorola, Inc – Integrated Processor with DMA User’s Manual
Freescale Semiconductor, Inc.
5.3.3.10 CONDITION TESTS. Conditional program control instructions and the TRAPcc
instruction execute on the basis of condition tests. A condition test is the evaluation of a
logical expression related to the state of the CCR bits. If the result is 1, the condition is
true. If the result is 0, the condition is false. For example, the T condition is always true,
and the EQ condition is true only if the Z-bit condition code is true. Table 5-12 lists each
condition test.
Table 5-12. Condition Tests
Mnemonic
Condition
T
True
F*
False
HI
High
LS
Low or Same
CC
Carry Clear
CS
Carry Set
NE
Not Equal
EQ
Equal
VC
Overflow Clear
VS
Overflow Set
PL
Plus
MI
Minus
GE
Greater or Equal
LT
Less Than
GT
Greater Than
LE
Less or Equal
* Not available for the Bcc instruction.
• = Boolean AND
+ = Boolean OR
N = Boolean NOT
Encoding
0000
0001
0010
0011
0100
0101
0110
0111
1000
1001
1010
1011
1100
1101
1110
1111
Test
1
0
C•Z
C+Z
C
C
Z
Z
V
V
N
N
N •V+ N• V
N• V+ N•V
N • V • Z+ N• V• Z
Z+ N •V+ N•V
5.3.4 Using the TBL Instructions
There are four TBL instructions. TBLS returns a signed, rounded byte, word, or long-word
result. TBLSN returns a signed, unrounded byte, word, or long-word result. TBLU returns
an unsigned, rounded byte, word, or long-word result. TBLUN returns an unsigned,
unrounded byte, word, or long-word result. All four instructions support two types of
interpolation data: an n-element table stored in memory and a two-element range stored in
a pair of data registers. The latter form provides a means of performing surface (3D)
interpolation between two previously calculated linear interpolations.
The following examples show how to compress tables and use fewer interpolation levels
between table entries. Example 1 (see Figure 5-7) demonstrates TBL for a 257-entry
table, allowing up to 256 interpolation levels between entries. Example 2 (see Figure 5-8)
reduces table length for the same data to four entries. Example 3 (see Figure 5-9)
demonstrates use of an 8-bit independent variable with an instruction.
MOTOROLA
MC68340 USER’S MANUAL
5-29
For More Information On This Product,
Go to: www.freescale.com