User manual

mikroC PRO for dsPIC
MikroElektronika
677
Vectors Library
mikroC PRO for dsPIC30/33 and PIC24 includes a library for working and using vectors. All routines work with fractional
Q15 format.
Library Routines
- Vector_Set
- Vector_Power
- Vector_Subtract
- Vector_Scale
- Vector_Negate
- Vector_Multiply
- Vector_Min
- Vector_Max
- Vector_Dot
- Vector_Correlate
- Vector_Convolve
- Vector_Add
Vector_Set
Prototype
void Vector_Set(unsigned *input, unsigned size, unsigned value);
Description Sets size elements of input to value, starting from the rst element.
Parameters - input: pointer to original vector
- size: number of vector elements
- value: value written to the elements
Returns Nothing.
Requires Nothing.
Example
unsigned vec2[3] = {1,1,1};
Vector_Set(vec2, 3, 0x4000);
Notes - size must be > 0
- Length of input is limited by available RAM