当前位置: 首页> 健康> 母婴 > 移动互联网应用程序指的是什么_青岛网站建设开发外包_厦门seo外包平台_网络营销培训

移动互联网应用程序指的是什么_青岛网站建设开发外包_厦门seo外包平台_网络营销培训

时间:2025/7/12 19:58:24来源:https://blog.csdn.net/baidu_37552881/article/details/144875839 浏览次数:0次
移动互联网应用程序指的是什么_青岛网站建设开发外包_厦门seo外包平台_网络营销培训

/*

  • Driver for ELAN eKTF2127 i2c touchscreen controller
  • For this driver the layout of the Chipone icn8318 i2c
  • touchscreencontroller is used.
  • This program is free software; you can redistribute it and/or modify
  • it under the terms of the GNU General Public License as published by
  • the Free Software Foundation; either version 2 of the License, or
  • (at your option) any later version.
  • Author:
    */

#include <linux/gpio/consumer.h>
#include <linux/interrupt.h>
#include <linux/i2c.h>
#include <linux/input.h>
#include <linux/input/mt.h>
#include <linux/input/touchscreen.h>
#include <linux/module.h>
#include <linux/of.h>
#include <linux/delay.h>

/* Packet header defines (first byte of data send / received) */
#define EKTF2127_NOISE 0x40
#define EKTF2127_RESPONSE 0x52
#define EKTF2127_REQUEST 0x53
#define EKTF2127_HELLO 0x55
#define EKTF2127_REPORT 0x5d
#define EKTF2127_CALIB_DONE 0x66

/* Register defines (second byte of data send / received) */
#define EKTF2127_ENV_NOISY 0x41
#define EKTF2127_HEIGHT 0x60
#define EKTF2127_WIDTH 0x63

/* 2 bytes header + 5 * 3 bytes coordinates + 3 bytes pressure info + footer */
#define EKTF2127_TOUCH_REPORT_SIZE 21
#define EKTF2127_MAX_TOUCHES 5

struct ektf2127_ts {
struct i2c_client *client;
struct input_dev *input;
struct gpio_desc *power_gpios;
struct touchscreen_properties prop;
};

static void ektf2127_parse_coordinates(const u8* buf, unsigned int touch_count,
struct input_mt_pos *touches)
{
int index = 0;
int i;

for (i = 0; i < touch_count; i++) {
关键字:移动互联网应用程序指的是什么_青岛网站建设开发外包_厦门seo外包平台_网络营销培训

版权声明:

本网仅为发布的内容提供存储空间,不对发表、转载的内容提供任何形式的保证。凡本网注明“来源:XXX网络”的作品,均转载自其它媒体,著作权归作者所有,商业转载请联系作者获得授权,非商业转载请注明出处。

我们尊重并感谢每一位作者,均已注明文章来源和作者。如因作品内容、版权或其它问题,请及时与我们联系,联系邮箱:809451989@qq.com,投稿邮箱:809451989@qq.com

责任编辑: