SW006013 Microchip Technology, SW006013 Datasheet - Page 226

MPLAB C Compiler For DsPIC DSCs

SW006013

Manufacturer Part Number
SW006013
Description
MPLAB C Compiler For DsPIC DSCs
Manufacturer
Microchip Technology
Series
DsPIC30F/33Fr
Type
MPLAB® C Compilerr
Datasheet

Specifications of SW006013

Supported Families
DsPIC30F, DsPIC33F
Core Architecture
DsPIC
Kit Contents
Software And Docs
Mcu Supported Families
DsPIC30F And DsPIC33F
Tool Function
Compiler
Tool Type
Compiler
Processor Series
dsPIC
Lead Free Status / RoHS Status
na
For Use With/related Products
dSPIC DSCs
Lead Free Status / Rohs Status
Lead free / RoHS Compliant
DS51456E-page 222
_Q16norm
Description:
Include:
Prototype:
Argument:
Return Value:
_Q16power
Description:
Include:
Prototype:
Argument:
Return Value:
_Q16random
Description:
Include:
Prototype:
Argument:
Return Value:
Remarks:
_Q16reciprocal
Description:
Include:
Prototype:
Argument:
Return Value:
This function finds the normalized value of a Q16 value.
<libq.h>
_Q16 _Q16norm(_Q16 x);
x
ranges from -2147483648 to 2147483647.
This function returns the square root value of x in Q16 format. This
value ranges from 1073741824 to 2147483647 for a positive number
and -2147483648 to -1073741824 for a negative number.
This function finds the power result, given the base value x and the
power value y.
<libq.h>
_Q16 _Q16power(_Q16 x, _Q16 y);
x
ranges from 0 to 2147483647.
y
ranges from 0 to 2147483647.
This function returns the value of x to the power of y in Q16 format.
This value ranges from 0 to 2147483647.
This function generates pseudo random number with a period of
2147483648. This function uses the _Q16randomSeed variable as a
random seed value.
<libq.h>
_Q16 _Q16random(void);
None.
This function returns the generated random number in Q16 format. The
value of this output ranges from -2147483648 to 2147483647.
RndNum(n) = (RndNum(n-1) * RAN_MULT) + RAN_INC
SEED VALUE = 21845, RAN_MULT = 1664525, and RAN_INC =
1013904223.
This function returns the reciprocal of a Q16 value.
<libq.h>
_Q16 _Q16reciprocal(_Q16 x);
x
ranges from -2147483648 to 2147483647.
This function returns the reciprocal of x in Q16 format. The value of this
output ranges from -2147483648 to 2147483647.
a fixed point number in Q16 format. The value of this argument
a fixed point number in Q16 format. The value of this argument
a fixed point number in Q16 format. The value of this argument
a fixed point number in Q16 format. The value of this argument
© 2008 Microchip Technology Inc.

Related parts for SW006013