03.08.2013 Views

Embedded Software and Motor Control Libraries for PXR40xx

Embedded Software and Motor Control Libraries for PXR40xx

Embedded Software and Motor Control Libraries for PXR40xx

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

}<br />

// ##############################################################<br />

// Available only if single precision floating point<br />

// implementation selected as default<br />

// ##############################################################<br />

// output should be 0.3025<br />

fltOut = MLIB_Mac (fltIn1, fltIn2, fltIn3);<br />

4.146 Function MLIB_MacSat_F32<br />

This function implements the multiply accumulate function saturated if necessary.<br />

4.146.1 Declaration<br />

tFrac32 MLIB_MacSat_F32(register tFrac32 f32In1, register tFrac32 f32In2, register tFrac32<br />

f32In3);<br />

4.146.2 Arguments<br />

Table 4-183. MLIB_MacSat_F32 arguments<br />

Type Name Direction Description<br />

register tFrac32 f32In1 input Input value to be add.<br />

register tFrac32 f32In2 input First value to be multiplied.<br />

register tFrac32 f32In3 input Second value to be multiplied.<br />

4.146.3 Return<br />

Multiplied second <strong>and</strong> third input value with adding of first input value. The output value<br />

is saturated if necessary.<br />

4.146.4 Description<br />

Chapter 4 API References<br />

This inline function returns the multiplied second <strong>and</strong> third input value with adding of<br />

first input value. The input values as well as output value is considered as 32-bit<br />

fractional values. The output saturation is implemented in this function, thus in case the<br />

output value is outside the (-1, 1) interval, the output value is limited to the boundary<br />

value.<br />

<strong>Embedded</strong> <strong>Software</strong> <strong>and</strong> <strong>Motor</strong> <strong>Control</strong> <strong>Libraries</strong> <strong>for</strong> <strong>PXR40xx</strong>, Rev. 1.0<br />

Freescale Semiconductor, Inc. 607

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!