ST20-C1 STMICROELECTRONICS [STMicroelectronics], ST20-C1 Datasheet - Page 95

no-image

ST20-C1

Manufacturer Part Number
ST20-C1
Description
Instruction Set Reference Manual
Manufacturer
STMICROELECTRONICS [STMicroelectronics]
Datasheet
biquad
Code: 21 F7
Description: Execute a step of a biquad IIR filter on vectors of 16-bit values. Areg
points to the C coefficient vector, Breg points to the X input data vector and Creg
points to the Y results vector. Areg must be word-aligned and Breg and Creg half-
word aligned. biquad increments Breg and Creg by 2 bytes and performs the five
multiply accumulates Y[2] = X[0].C[0] + X[1].C[1] + X[2].C[2] + Y[0].C[3] + Y[1].C[4].
Definition:
Status Register:
Comments:
See also: mac, smacloop, umac
if ( overflow )
else if ( underflo w )
else
{
}
where
May set underflow or overflow.
Areg must be word-aligned.
Breg and Creg must be half-word aligned, and must either be both word-aligned
or neither word-aligned.
This instruction may take 8 memory accesses, which will affect interrupt latency.
Chapter 5.
if (Status
if (Status
sixteen [Creg + 4]
Breg
Creg
acc = 1 << 22
– the value of acc is calculated to 48-bit precision
if (Status
else
underflo w
overflow
Breg + 2
Creg + 2
mac_scale
set ) Status
set ) Status
acc >>
+ ((sixteen[Areg] << shift)
+ ((sixteen[Areg+2] << shift) sixteen[Breg+2])
+ ((sixteen[Areg+4] << shift) sixteen[Breg+4])
+ ((sixteen[Areg+6] << shift) sixteen[Creg])
+ ((sixteen[Areg+8] << shift) sixteen[Creg+2])
= 3) shift = 9
arith
underflo w
shift = 4
overflow
23
set
set
Status
biquad IIR filter step
8 Instruction Set Reference
mac_scale
sixteen[Breg])
95/205

Related parts for ST20-C1