2 * Raspberry Pi Sense HAT core driver
3 * http://raspberrypi.org
5 * Copyright (C) 2015 Raspberry Pi
7 * Author: Serge Schneider
9 * This program is free software; you can redistribute it and/or modify it
10 * under the terms of the GNU General Public License as published by the
11 * Free Software Foundation; either version 2 of the License, or (at your
12 * option) any later version.
16 #ifndef __LINUX_MFD_RPISENSE_CORE_H_
17 #define __LINUX_MFD_RPISENSE_CORE_H_
19 #include <linux/mfd/rpisense/joystick.h>
20 #include <linux/mfd/rpisense/framebuffer.h>
25 #define RPISENSE_FB 0x00
26 #define RPISENSE_WAI 0xF0
27 #define RPISENSE_VER 0xF1
28 #define RPISENSE_KEYS 0xF2
29 #define RPISENSE_EE_WP 0xF3
31 #define RPISENSE_ID 's'
35 struct i2c_client *i2c_client;
38 struct rpisense_js joystick;
39 struct rpisense_fb framebuffer;
42 struct rpisense *rpisense_get_dev(void);
43 s32 rpisense_reg_read(struct rpisense *rpisense, int reg);
44 int rpisense_reg_write(struct rpisense *rpisense, int reg, u16 val);
45 int rpisense_block_write(struct rpisense *rpisense, const char *buf, int count);