mirror of
https://github.com/LuckfoxTECH/luckfox-pico.git
synced 2026-01-18 03:28:19 +01:00
ubuntu:debug submodule lose
This commit is contained in:
committed by
luckfox-eng33
parent
ac4c9c0906
commit
6cf97cc3f9
@@ -312,7 +312,14 @@
|
||||
/***************************** PINCTRL ********************************/
|
||||
// SPI
|
||||
&spi0 {
|
||||
pinctrl-0 = <&spi0m0_clk &spi0m0_miso &spi0m0_mosi &spi0m0_cs0>;
|
||||
pinctrl-0 = <&spi0m0_clk &spi0m0_miso &spi0m0_mosi &spi0m0_cs0>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
spidev@0 {
|
||||
compatible = "rockchip,spidev";
|
||||
spi-max-frequency = <50000000>;
|
||||
reg = <0>;
|
||||
};
|
||||
};
|
||||
// I2C
|
||||
&i2c3 {
|
||||
|
||||
@@ -42,13 +42,9 @@
|
||||
/**********SPI**********/
|
||||
/* SPI0_M0 */
|
||||
&spi0 {
|
||||
status = "okay";
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
status = "disabled";
|
||||
spidev@0 {
|
||||
compatible = "rockchip,spidev";
|
||||
spi-max-frequency = <50000000>;
|
||||
reg = <0>;
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
|
||||
#include "rv1103.dtsi"
|
||||
#include "rv1106-evb.dtsi"
|
||||
#include "rv1103-luckfox-pico-mini-ipc.dtsi"
|
||||
#include "rv1103-luckfox-pico-ipc.dtsi"
|
||||
|
||||
/ {
|
||||
model = "Luckfox Pico Mini B";
|
||||
@@ -54,13 +54,9 @@
|
||||
/**********SPI**********/
|
||||
/* SPI0_M0 */
|
||||
&spi0 {
|
||||
status = "okay";
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
status = "disabled";
|
||||
spidev@0 {
|
||||
compatible = "rockchip,spidev";
|
||||
spi-max-frequency = <50000000>;
|
||||
reg = <0>;
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
@@ -54,13 +54,9 @@
|
||||
/**********SPI**********/
|
||||
/* SPI0_M0 */
|
||||
&spi0 {
|
||||
status = "okay";
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
status = "disabled";
|
||||
spidev@0 {
|
||||
compatible = "rockchip,spidev";
|
||||
spi-max-frequency = <50000000>;
|
||||
reg = <0>;
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
@@ -42,13 +42,9 @@
|
||||
/**********SPI**********/
|
||||
/* SPI0_M0 */
|
||||
&spi0 {
|
||||
status = "okay";
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
status = "disabled";
|
||||
spidev@0 {
|
||||
compatible = "rockchip,spidev";
|
||||
spi-max-frequency = <50000000>;
|
||||
reg = <0>;
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
@@ -295,7 +295,14 @@
|
||||
/*****************************PINCTRL********************************/
|
||||
// SPI
|
||||
&spi0 {
|
||||
pinctrl-0 = <&spi0m0_clk &spi0m0_miso &spi0m0_mosi &spi0m0_cs0>;
|
||||
pinctrl-0 = <&spi0m0_clk &spi0m0_miso &spi0m0_mosi &spi0m0_cs0>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
spidev@0 {
|
||||
compatible = "rockchip,spidev";
|
||||
spi-max-frequency = <50000000>;
|
||||
reg = <0>;
|
||||
};
|
||||
};
|
||||
// I2C
|
||||
&i2c0 {
|
||||
@@ -310,9 +317,9 @@
|
||||
pinctrl-0 = <&i2c3m1_xfer &i2c3m0_xfer>;
|
||||
};
|
||||
|
||||
&i2c4 {
|
||||
pinctrl-0 = <&i2c4m0_xfer>;
|
||||
};
|
||||
// &i2c4 {
|
||||
// pinctrl-0 = <&i2c4m0_xfer>;
|
||||
// };
|
||||
|
||||
// UART
|
||||
&uart0 {
|
||||
|
||||
@@ -56,21 +56,26 @@
|
||||
panel: panel {
|
||||
compatible = "simple-panel";
|
||||
backlight = <&backlight>;
|
||||
//reset-gpios = <&gpio0 RK_PA1 GPIO_ACTIVE_LOW>;
|
||||
//reset-delay-ms = <200>;
|
||||
enable-gpios = <&gpio0 RK_PA1 GPIO_ACTIVE_HIGH>;
|
||||
enable-delay-ms = <20>;
|
||||
status = "okay";
|
||||
|
||||
bus-format = <MEDIA_BUS_FMT_RGB666_1X18>;
|
||||
width-mm = <85>;
|
||||
height-mm = <85>;
|
||||
|
||||
reset {
|
||||
reset-gpios = <&gpio0 RK_PA1 GPIO_ACTIVE_LOW>;
|
||||
reset-delay-ms = <200>;
|
||||
status = "okay";
|
||||
};
|
||||
enable {
|
||||
enable-gpios = <&gpio0 RK_PA1 GPIO_ACTIVE_HIGH>;
|
||||
enable-delay-ms = <20>;
|
||||
status = "okay";
|
||||
};
|
||||
display-timings {
|
||||
native-mode = <&timing0>;
|
||||
|
||||
timing0: timing0 {
|
||||
clock-frequency = <16500000>;
|
||||
clock-frequency = <0>;
|
||||
hactive = <0>;
|
||||
vactive = <0>;
|
||||
hback-porch = <0>;
|
||||
@@ -82,7 +87,7 @@
|
||||
hsync-active = <0>;
|
||||
vsync-active = <0>;
|
||||
de-active = <0>;
|
||||
pixelclk-active = <0>;
|
||||
pixelclk-active = <1>;
|
||||
};
|
||||
};
|
||||
|
||||
@@ -487,9 +492,9 @@
|
||||
&i2c2 {
|
||||
pinctrl-0 = <&i2c2m0_xfer>;
|
||||
};
|
||||
&i2c3 {
|
||||
pinctrl-0 = <&i2c3m0_xfer &i2c3m1_xfer &i2c3m2_xfer>;
|
||||
};
|
||||
// &i2c3 {
|
||||
// pinctrl-0 = <&i2c3m0_xfer &i2c3m1_xfer &i2c3m2_xfer>;
|
||||
// };
|
||||
// &i2c4 {
|
||||
// pinctrl-0 = <&i2c4m0_xfer &i2c4m1_xfer &i2c4m2_xfer>;
|
||||
// };
|
||||
|
||||
@@ -54,13 +54,9 @@
|
||||
|
||||
/**********SPI**********/
|
||||
&spi0 {
|
||||
status = "okay";
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
status = "disabled";
|
||||
spidev@0 {
|
||||
compatible = "rockchip,spidev";
|
||||
spi-max-frequency = <50000000>;
|
||||
reg = <0>;
|
||||
};
|
||||
};
|
||||
|
||||
@@ -89,12 +85,6 @@
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
/**********PWM**********/
|
||||
/* PWM5_M1 */
|
||||
&pwm1 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
/**********RTC**********/
|
||||
&rtc {
|
||||
status = "okay";
|
||||
|
||||
@@ -102,10 +102,6 @@
|
||||
};
|
||||
};
|
||||
|
||||
/**********TP**********/
|
||||
&i2c3 {
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
/**********SPI**********/
|
||||
&spi0 {
|
||||
@@ -114,3 +110,4 @@
|
||||
spi-max-frequency = <50000000>;
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
@@ -53,11 +53,6 @@
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
/**********TP**********/
|
||||
&i2c3 {
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
/**********SPI**********/
|
||||
&spi0 {
|
||||
status = "disabled";
|
||||
|
||||
@@ -144,7 +144,7 @@ CONFIG_KEYBOARD_ADC=y
|
||||
CONFIG_KEYBOARD_GPIO=y
|
||||
# CONFIG_INPUT_MOUSE is not set
|
||||
CONFIG_INPUT_TOUCHSCREEN=y
|
||||
CONFIG_TOUCHSCREEN_GOODIX=y
|
||||
CONFIG_TOUCHSCREEN_GOODIX=m
|
||||
CONFIG_TOUCHSCREEN_EDT_FT5X06=y
|
||||
# CONFIG_SERIO is not set
|
||||
# CONFIG_VT is not set
|
||||
|
||||
@@ -963,8 +963,6 @@ static int goodix_read_version(struct goodix_ts_data *ts)
|
||||
{
|
||||
int error;
|
||||
u8 buf[6];
|
||||
//u8 reg_data[6];
|
||||
//int i = 0;
|
||||
char id_str[GOODIX_ID_MAX_LEN + 1];
|
||||
|
||||
error = goodix_i2c_read(ts->client, GOODIX_REG_ID, buf, sizeof(buf));
|
||||
@@ -981,6 +979,7 @@ static int goodix_read_version(struct goodix_ts_data *ts)
|
||||
|
||||
dev_info(&ts->client->dev, "ID %s, version: %04x\n", ts->id,
|
||||
ts->version);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -1060,15 +1059,11 @@ static int goodix_configure_dev(struct goodix_ts_data *ts)
|
||||
input_set_abs_params(ts->input_dev, ABS_MT_WIDTH_MAJOR, 0, 255, 0, 0);
|
||||
input_set_abs_params(ts->input_dev, ABS_MT_TOUCH_MAJOR, 0, 255, 0, 0);
|
||||
|
||||
|
||||
|
||||
dev_dbg(&ts->client->dev, "(%d, %d, %d)", ts->prop.max_x, ts->prop.max_y, ts->max_touch_num);
|
||||
/* Read configuration and apply touchscreen parameters */
|
||||
goodix_read_config(ts);
|
||||
dev_dbg(&ts->client->dev, "(%d, %d, %d)", ts->prop.max_x, ts->prop.max_y, ts->max_touch_num);
|
||||
|
||||
/* Try overriding touchscreen parameters via device properties */
|
||||
touchscreen_parse_properties(ts->input_dev, true, &ts->prop);
|
||||
dev_dbg(&ts->client->dev, "(%d, %d, %d)", ts->prop.max_x, ts->prop.max_y, ts->max_touch_num);
|
||||
|
||||
if (!ts->prop.max_x || !ts->prop.max_y || !ts->max_touch_num) {
|
||||
dev_err(&ts->client->dev,
|
||||
@@ -1133,17 +1128,9 @@ static void goodix_config_cb(const struct firmware *cfg, void *ctx)
|
||||
{
|
||||
struct goodix_ts_data *ts = ctx;
|
||||
int error;
|
||||
int i;
|
||||
|
||||
if (cfg) {
|
||||
/* send device configuration to the firmware */
|
||||
|
||||
while(i < cfg->size)
|
||||
{
|
||||
dev_dbg(&ts->client->dev, "reg %d: %#x\n", i, cfg->data[i]);
|
||||
i ++;
|
||||
}
|
||||
|
||||
error = goodix_send_cfg(ts, cfg->data, cfg->size);
|
||||
if (error)
|
||||
goto err_release_cfg;
|
||||
@@ -1243,11 +1230,8 @@ reset:
|
||||
|
||||
ts->chip = goodix_get_chip_data(ts->id);
|
||||
|
||||
ts->load_cfg_from_disk = 0;
|
||||
if (ts->load_cfg_from_disk) {
|
||||
/* update device config */
|
||||
|
||||
dev_dbg(&client->dev, "Configure from Disk\n");
|
||||
ts->cfg_name = devm_kasprintf(&client->dev, GFP_KERNEL,
|
||||
"goodix_%s_cfg.bin", ts->id);
|
||||
if (!ts->cfg_name)
|
||||
@@ -1265,7 +1249,6 @@ reset:
|
||||
|
||||
return 0;
|
||||
} else {
|
||||
dev_dbg(&client->dev, "Configure from Device\n");
|
||||
error = goodix_configure_dev(ts);
|
||||
if (error)
|
||||
return error;
|
||||
|
||||
Reference in New Issue
Block a user