4 #include <linux/ioctl.h>
5 //#include "kd_imgsensor.h"
7 #define DW9714AF_MAGIC 'A'
8 //IOCTRL(inode * ,file * ,cmd ,arg )
14 unsigned long u4CurrentPosition
;
16 unsigned long u4MacroPosition
;
18 unsigned long u4InfPosition
;
25 } stDW9714AF_MotorInfo
;
32 //APERTURE , won't be supported on most devices.
34 //FILTER_DENSITY, won't be supported on most devices.
36 //FOCAL_LENGTH, lens optical zoom setting. won't be supported on most devices.
38 //FOCAL_DISTANCE, current focus distance, lens to objects.
40 //OPTICAL_STABILIZATION_MODE
44 //Optical axis angle, optical axis is perpendicular to LCM, usually is {0,0}.
45 float OpticalAxisAng
[2];
46 //Optical axis position (mm), usually is {0,0,0}.
53 float InfoAvalibleMinFocusDistance
;
54 float InfoAvalibleApertures
;
55 float InfoAvalibleFilterDensity
;
56 u16 InfoAvalibleOptStabilization
;
57 float InfoAvalibleFocalLength
;
58 float InfoAvalibleHypeDistance
;
59 }stDW9714AF_MotorMETAInfo
;
63 //S means "set through a ptr"
64 //T means "tell by a arg value"
65 //G means "get by a ptr"
66 //Q means "get by return a value"
67 //X means "switch G and S atomically"
68 //H means "switch T and Q atomically"
69 #define DW9714AFIOC_G_MOTORINFO _IOR(DW9714AF_MAGIC,0,stDW9714AF_MotorInfo)
71 #define DW9714AFIOC_T_MOVETO _IOW(DW9714AF_MAGIC,1,unsigned long)
73 #define DW9714AFIOC_T_SETINFPOS _IOW(DW9714AF_MAGIC,2,unsigned long)
75 #define DW9714AFIOC_T_SETMACROPOS _IOW(DW9714AF_MAGIC,3,unsigned long)
77 #define DW9714AFIOC_G_MOTORMETAINFO _IOR(DW9714AF_MAGIC,4,stDW9714AF_MotorMETAInfo)