📄 zc030x.h
字号:
/* This declare the commonspace structures *//* Zc030x - Driver file - Zc030x *//* This file is under GPL *//* Copyright: Martin Braun Cyril Russo -------------------------------------------*/#ifndef h_Zc030x_h#define h_Zc030x_h/* Include IOCTL declaration */#include <linux/ioctl.h>/* IOCtl to try to get the sensor type */#define ZCIDSENSOR _IOWR('v', 0xFD8, struct sensor_list)#define ZCI2CREGISTERMAP _IOWR('v', 0xFD9, struct register_map)/* Declare the userspace/kernelspace structure */struct sensor_list { int id; /* ID of the sensor (supposed unique) */ char name[24]; /* Name of the sensor */ int minwidth; /* Minimum width of the picture */ int minheight; /* Minimum height of the picture */ int maxwidth; /* Maximum width of the picture */ int maxheight; /* Maximum height of the picture */ /* This is a signature of the sensor, made from I2C read-only registers - This is not accessible from user space */ const struct signature * i2c_sig;};/* Define the register type */#define RM_Unused 0#define RM_ReadOnly 1#define RM_WriteOnly 2#define RM_ReadWrite 3/* Declare the register map structure */struct register_map{ int addr; int value; int mode;};#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -