應(yīng)用調(diào)試-----輸入模擬器之編寫測(cè)試模擬功能
====================================================================
觸摸屏驅(qū)動(dòng)源碼:
#include "linux/errno.h"
#include "linux/kernel.h"
#include "linux/module.h"
#include "linux/slab.h"
#include "linux/input.h"
#include "linux/init.h"
#include "linux/serio.h"
#include "linux/delay.h"
#include "linux/platform_device.h"
#include "linux/clk.h"
#include "asm/io.h"
#include "asm/irq.h"
#include "asm/uaccess.h"
#include "asm/plat-s3c24xx/ts.h"
#include "asm/arch/regs-adc.h"
#include "asm/arch/regs-gpio.h"
struct s3c_ts_regs {
};
static struct input_dev *s3c_ts_dev;
static volatile struct s3c_ts_regs *s3c_ts_regs;
static struct timer_list ts_timer;
#define MYLOG_BUF_LEN (1024*1024)
#define INPUT_REPLAY 0
#define INPUT_TAG 1
static char *replay_buf;
static int replay_r = 0;
static int replay_w = 0;
static int major = 0;
static struct class *cls;
static struct timer_list replay_timer;
extern int myprintk(const char *fmt, ...);
static ssize_t replay_write(struct file * file, const char __user *buf, size_t size, loff_t *offset)
{
}
// app: ioctl(fd, CMD, ..); //
static int replay_ioctl(struct inode *inode, struct file *file, unsigned int cmd, unsigned long arg)
{