added support for LIS3LV02DQ 3-axis accelerometer. int data =
tilt(int); where tilt(1) is x-axis, tilt(2) is y-axis, tilt(3) is z-axis git-svn-id: http://picoc.googlecode.com/svn/trunk@254 21eae674-98b7-11dd-bd71-f92a316d2d60
This commit is contained in:
parent
7c2ce7290a
commit
88d904ada8
|
@ -283,18 +283,18 @@ void Cvpix(struct ParseState *Parser, struct Value *ReturnValue, struct Value **
|
|||
x = Param[0]->Val->Integer;
|
||||
y = Param[1]->Val->Integer;
|
||||
ix = vpix((unsigned char *)FRAME_BUF, x, y);
|
||||
Iy1 = ((ix>>16) & 0x000000FF); // Y1
|
||||
Iu1 = ((ix>>24) & 0x000000FF); // U
|
||||
Iv1 = ((ix>>8) & 0x000000FF); // V
|
||||
Iy1 = ((ix>>16) & 0x000000FF); // Y1
|
||||
Iu1 = ((ix>>24) & 0x000000FF); // U
|
||||
Iv1 = ((ix>>8) & 0x000000FF); // V
|
||||
}
|
||||
|
||||
void Cvmean(struct ParseState *Parser, struct Value *ReturnValue, struct Value **Param, int NumArgs)
|
||||
{
|
||||
vmean((unsigned char *)FRAME_BUF);
|
||||
vmean((unsigned char *)FRAME_BUF);
|
||||
Iy1 = mean[0];
|
||||
Iu1 = mean[1];
|
||||
Iv1 = mean[2];
|
||||
}
|
||||
}
|
||||
|
||||
// search for blob by color, index; return center point X,Y and width Z
|
||||
void Cvblob(struct ParseState *Parser, struct Value *ReturnValue, struct Value **Param, int NumArgs) {
|
||||
|
@ -676,7 +676,7 @@ void Cnnlearnblob (struct ParseState *Parser, struct Value *ReturnValue, struct
|
|||
bloby1[0], bloby2[0], imgWidth, imgHeight);
|
||||
nnpack8x8(ix);
|
||||
nndisplay(ix);
|
||||
}
|
||||
}
|
||||
|
||||
/* list of all library functions and their prototypes */
|
||||
struct LibraryFunction PlatformLibrary[] =
|
||||
|
|
Loading…
Reference in a new issue