"google,kevin", "google,gru", "rockchip,rk3399";
};
+&ap_i2c_tp {
+ trackpad@4a {
+ compatible = "atmel,maxtouch";
+ reg = <0x4a>;
+ pinctrl-names = "default";
+ pinctrl-0 = <&trackpad_int_l>;
+ interrupt-parent = <&gpio1>;
+ interrupts = <4 IRQ_TYPE_LEVEL_LOW>;
+ linux,gpio-keymap = <KEY_RESERVED
+ KEY_RESERVED
+ KEY_RESERVED
+ BTN_LEFT>;
+ };
+};
+
/* GPIO overrides for -r0; in same order as parent */
&pp3000 {
"google,gru", "rockchip,rk3399";
};
+&ap_i2c_tp {
+ trackpad@4a {
+ compatible = "atmel,maxtouch";
+ reg = <0x4a>;
+ pinctrl-names = "default";
+ pinctrl-0 = <&trackpad_int_l>;
+ interrupt-parent = <&gpio1>;
+ interrupts = <4 IRQ_TYPE_LEVEL_LOW>;
+ linux,gpio-keymap = <KEY_RESERVED
+ KEY_RESERVED
+ KEY_RESERVED
+ BTN_LEFT>;
+ };
+};
+
/* PINCTRL: always below everything else */
&pinctrl {
* OTHER DEALINGS IN THE SOFTWARE.
*/
+#include <dt-bindings/input/input.h>
#include <dt-bindings/pwm/pwm.h>
#include "rk3399.dtsi"
};
ap_i2c_tp: &i2c5 {
+ status = "okay";
+
/*
* Note strange pullup enable. Apparently this avoids leakage but
* still allows us to get nice 4.7K pullups for high speed i2c
*/
pinctrl-0 = <&i2c5_xfer &ap_i2c_tp_pu_en>;
- status = "okay";
+ clock-frequency = <400000>;
- // TODO: bus speed
- // ...with no speed, it should just use 100kHz
- // TODO: rise / fall times?
-
- // TODO: Add the proper touchpanel reference...
+ /* These are relatively safe rise/fall times; TODO: measure */
+ i2c-scl-falling-time-ns = <50>;
+ i2c-scl-rising-time-ns = <300>;
};
ap_i2c_audio: &i2c8 {
};
};
- touchpanel {
+ trackpad {
ap_i2c_tp_pu_en: ap-i2c-tp-pu-en {
rockchip,pins = <3 12 RK_FUNC_GPIO &pcfg_output_high>;
};
+
+ trackpad_int_l: trackpad-int-l {
+ rockchip,pins = <1 4 RK_FUNC_GPIO &pcfg_pull_up>;
+ };
};
backlight-enable {