dsp56800e Freescale Semiconductor, Inc, dsp56800e Datasheet - Page 24

no-image

dsp56800e

Manufacturer Part Number
dsp56800e
Description
16-bit Digital Signal Controller Core
Manufacturer
Freescale Semiconductor, Inc
Datasheet
Example 5-17 Signed Division Without Remainder . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-24
Example 5-18 Multiplication of 2 Unsigned Words . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-28
Example 5-19 64-Bit Addition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-29
Example 5-20 64-Bit Subtraction. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-29
Example 5-21 Fractional Single-Precision Times Double-Precision—Both Signed . . . . . . . . 5-30
Example 5-22 Multiplying Two Fractional Double-Precision Values. . . . . . . . . . . . . . . . . . . 5-32
Example 5-23 Multiplying Two Signed Long Integers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-33
Example 5-24 Multiplying Two Unsigned Long Integers . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-34
Example 5-25 Multiplying Two Signed Long Integers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-35
Example 5-26 Multiplying Signed 16-Bit Word with Signed 32-Bit Long . . . . . . . . . . . . . . . 5-36
Example 5-27 Normalizing with the NORM Instruction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-37
Example 5-28 Normalizing with a Shift Instruction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-37
Example 5-29 Demonstrating the Data Limiter—Positive Saturation . . . . . . . . . . . . . . . . . . . 5-40
Example 5-30 Demonstrating the Data Limiter—Negative Saturation . . . . . . . . . . . . . . . . . . 5-41
Example 5-31 Demonstrating the MAC Output Limiter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-42
Example 5-32 Example Code for Two’s-Complement Rounding . . . . . . . . . . . . . . . . . . . . . . 5-46
Example 5-33 Example Code for Convergent Rounding. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-47
Example 6-1 Accessing Bytes with the MOVE.B Instruction . . . . . . . . . . . . . . . . . . . . . . . . 6-10
Example 6-2 Addressing Mode Examples for Long Memory Accesses . . . . . . . . . . . . . . . . 6-11
Example 6-3 Accessing Elements in a Data Structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-11
Example 6-4 Comparison of MOVE.BP and MOVE.B Instructions. . . . . . . . . . . . . . . . . . . 6-15
Example 6-5 Accessing Elements in an Array of Bytes . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-16
Example 6-6 Invalid Use of the Modulo Addressing Mode . . . . . . . . . . . . . . . . . . . . . . . . . 6-28
Example 6-7 Adding Positive Offset to a Modulo Pointer . . . . . . . . . . . . . . . . . . . . . . . . . . 6-28
Example 6-8 Adding “–2” to a Modulo Pointer. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-28
Example 6-9 Correct Usage - Offset Values Satisfying Restriction . . . . . . . . . . . . . . . . . . . 6-29
Example 6-10 Initializing the Circular Buffer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-31
Example 6-11 Accessing the Circular Buffer. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-31
Example 6-12 Accessing the Circular Buffer with Post-Update by Three . . . . . . . . . . . . . . . 6-32
Example 7-1 Examples of Byte Masks in BRSET and BRCLR Instructions . . . . . . . . . . . . . 7-3
Example 7-2 Using a Mask to Operate on Bits 7–4 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-3
Example 7-3 Testing Bits in an Operand . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-4
Example 7-4 Branching on Bits in an Operand . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-5
Example 7-5 Clearing Bits in an Operand . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-5
Example 7-6 Logical Operations on Bytes in Memory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-7
Example 7-7 Logical Operations on Bytes Using Word Pointers . . . . . . . . . . . . . . . . . . . . . . 7-8
Example 7-8 Bit-Manipulation Operations Using Complex Addressing Modes. . . . . . . . . . . 7-8
xxiv
DSP56800E Core Reference Manual
Freescale Semiconductor

Related parts for dsp56800e