⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 wm.h

📁 linux下wii的鼠标驱动
💻 H
字号:
/* * Authors: Tyler Vodak and Will Faught * CPE 454 * Project * * Name: WiiDriver.h * Description: Header file for WiimoteDriver.c * Usage: none * * Modified: * 	5/16/07		TCV and WF	Original Write * */#define WII_NAME	"wm"#define WII_MOD_NAME "Wiimote Driver"#define BTN_DOWN 1#define BTN_UP 0#define SCROLL_LEN 1/*set if y axis inverted*/#define Y_AXIS_INV 1static void mouse_move(struct input_dev *i_wii,int x,int y);static void mouse_click(struct input_dev *i_wii,unsigned int button,int value);static void mouse_wheel(struct input_dev *i_wii,int val);static ssize_t wiidriver_write(struct file *fp,const char *buf,size_t count,				loff_t *pos);static ssize_t wiidriver_read(struct file *fp,char *buf,size_t count,				loff_t *pos);static int wiidriver_release(struct inode *inode,struct file *file);static int wiidriver_open(struct inode *inode,struct file *file);static void wiidev_close (struct input_dev *n_dev);static int wiidev_open (struct input_dev *n_dev);static int wiidev_set (struct input_dev *input_wii);static int __init wiidriver_init(void);static void __exit wiidriver_exit(void);/* file_operations struct specifying functions to call when doing read,write, * etc. on the wii device file */struct file_operations wiidriver_fops = {	.owner = THIS_MODULE,	.open = wiidriver_open,	.release = wiidriver_release,	.read = wiidriver_read,	.write = wiidriver_write,};/*  * miscdevice struct for the wiimote */struct miscdevice wii_dev = {	.fops = &wiidriver_fops,	.minor = MISC_DYNAMIC_MINOR,	.name = WII_NAME,};

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -