Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 42 additions & 0 deletions boards/nxp/mimxrt700_evk/board.c
Original file line number Diff line number Diff line change
Expand Up @@ -544,6 +544,48 @@
CLOCK_EnableClock(kCLOCK_Acmp0);
RESET_ClearPeripheralReset(kACMP0_RST_SHIFT_RSTn);
#endif

//@HARDCODE @INCOMPLETE(Emilio): Force hardcode for testing

Check failure on line 548 in boards/nxp/mimxrt700_evk/board.c

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

C99_COMMENTS

boards/nxp/mimxrt700_evk/board.c:548 do not use C99 // comments
#if 1

Check warning on line 549 in boards/nxp/mimxrt700_evk/board.c

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

IF_1

boards/nxp/mimxrt700_evk/board.c:549 Consider removing the #if 1 and its #endif
//@NOTE(Emilio): BOARD_InitMipiDsiClock

Check failure on line 550 in boards/nxp/mimxrt700_evk/board.c

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

C99_COMMENTS

boards/nxp/mimxrt700_evk/board.c:550 do not use C99 // comments
POWER_DisablePD(kPDRUNCFG_PPD_MIPIDSI);

Check warning on line 551 in boards/nxp/mimxrt700_evk/board.c

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

LEADING_SPACE

boards/nxp/mimxrt700_evk/board.c:551 please, no spaces at the start of a line
POWER_DisablePD(kPDRUNCFG_APD_MIPIDSI);

Check warning on line 552 in boards/nxp/mimxrt700_evk/board.c

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

LEADING_SPACE

boards/nxp/mimxrt700_evk/board.c:552 please, no spaces at the start of a line
POWER_DisablePD(kPDRUNCFG_PD_VDD2_MIPI);

Check warning on line 553 in boards/nxp/mimxrt700_evk/board.c

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

LEADING_SPACE

boards/nxp/mimxrt700_evk/board.c:553 please, no spaces at the start of a line
POWER_ApplyPD();

Check warning on line 554 in boards/nxp/mimxrt700_evk/board.c

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

LEADING_SPACE

boards/nxp/mimxrt700_evk/board.c:554 please, no spaces at the start of a line

/* Use PLL PFD1 as clock source, 396m. */
CLOCK_AttachClk(kMAIN_PLL_PFD1_to_MIPI_DPHYESC_CLK);

Check warning on line 557 in boards/nxp/mimxrt700_evk/board.c

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

LEADING_SPACE

boards/nxp/mimxrt700_evk/board.c:557 please, no spaces at the start of a line
/* RxClkEsc min 60MHz, TxClkEsc 12 to 20MHz. */
/* RxClkEsc = 396MHz / 6 = 66MHz. */
CLOCK_SetClkDiv(kCLOCK_DivDphyEscRxClk, 6);
/* TxClkEsc = 396MHz / 6 / 4 = 16.5MHz. */
CLOCK_SetClkDiv(kCLOCK_DivDphyEscTxClk, 4);

CLOCK_InitAudioPfd(kCLOCK_Pfd2, 30);

CLOCK_AttachClk(kAUDIO_PLL_PFD2_to_MIPI_DSI_HOST_PHY);

CLOCK_SetClkDiv(kCLOCK_DivDphyClk, 1);


//@NOTE(Emilio): BOARD_InitLcdifPowerReset

Check failure on line 571 in boards/nxp/mimxrt700_evk/board.c

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

C99_COMMENTS

boards/nxp/mimxrt700_evk/board.c:571 do not use C99 // comments
POWER_DisablePD(kPDRUNCFG_SHUT_MEDIA_MAINCLK);
POWER_DisablePD(kPDRUNCFG_APD_LCDIF);
POWER_DisablePD(kPDRUNCFG_PPD_LCDIF);
POWER_ApplyPD();

CLOCK_EnableClock(kCLOCK_Lcdif);
RESET_ClearPeripheralReset(kLCDIF_RST_SHIFT_RSTn);


//@NOTE(Emilio): Clock code in BOARD_InitLcdif

Check failure on line 581 in boards/nxp/mimxrt700_evk/board.c

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

C99_COMMENTS

boards/nxp/mimxrt700_evk/board.c:581 do not use C99 // comments
CLOCK_InitMainPfd(kCLOCK_Pfd2, 17);
CLOCK_SetClkDiv(kCLOCK_DivMediaMainClk, 2U);
CLOCK_AttachClk(kMAIN_PLL_PFD2_to_MEDIA_MAIN);


#endif

}

static void GlikeyWriteEnable(GLIKEY_Type *base, uint8_t idx)
Expand Down
52 changes: 52 additions & 0 deletions boards/nxp/mimxrt700_evk/mimxrt700_evk-pinctrl.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -193,4 +193,56 @@
slew-rate = "normal";
};
};

pinmux_display: pinmux_display {
group0 {
pinmux = <XSPI2_PCS_A_0_PIO4_0>,
<XSPI2_DATA0_PIO4_1>,
<XSPI2_DATA1_PIO4_2>,
<XSPI2_DATA2_PIO4_3>,
<XSPI2_DATA3_PIO4_4>,
<XSPI2_DQS_A_0_PIO4_5>,
<XSPI2_DATA4_PIO4_6>,
<XSPI2_DATA5_PIO4_7>,
<XSPI2_DATA6_PIO4_8>,
<XSPI2_DATA7_PIO4_9>,
<XSPI2_SCK_A_PIO4_10>,
<XSPI2_SCK_A_N_PIO4_11>,
<XSPI2_DATA8_PIO4_12>,
<XSPI2_DATA9_PIO4_13>,
<XSPI2_DATA10_PIO4_14>,
<XSPI2_DATA11_PIO4_15>,
<XSPI2_DQS_A_1_PIO4_16>,
<XSPI2_DATA12_PIO4_17>,
<XSPI2_DATA13_PIO4_18>,
<XSPI2_DATA14_PIO4_19>,
<XSPI2_DATA15_PIO4_20>;
drive-strength = "normal";
slew-rate = "normal";
input-enable;
};

group1 {
pinmux = <GPIO1_GPIO10_PIO1_10>,
<GPIO1_GPIO14_PIO1_14>,
<GPIO3_GPIO4_PIO3_4>,
<GPIO3_GPIO5_PIO3_5>;
drive-strength = "normal";
slew-rate = "normal";
};

/*
@INCOMPLETE(Emilio): Each mux takes different flags.
Place into seperate groups
group2 {
pinmux = <LP_FLEXCOMM8_P0_PIO0_6>,
<LP_FLEXCOMM8_P1_PIO0_7>,
<GPIO1_GPIO13_PIO1_13>,
<GPIO3_GPIO8_PIO3_8>;
drive-strength = "normal";
slew-rate = "normal";
};
*/

};
};
Original file line number Diff line number Diff line change
Expand Up @@ -403,7 +403,7 @@ zephyr_udc0: &usb0 {
pinctrl-names = "default";
};

p3t1755dp_ard_i2c_interface: &flexcomm8_lpi2c8 {};
//p3t1755dp_ard_i2c_interface: &flexcomm8_lpi2c8 {};

&rtc0 {
status = "okay";
Expand All @@ -421,6 +421,3 @@ p3t1755dp_ard_i2c_interface: &flexcomm8_lpi2c8 {};
status = "okay";
};

&pca9422 {
status = "okay";
};
20 changes: 20 additions & 0 deletions boards/shields/zc143ac72mipi/Kconfig.defconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Copyright 2025 NXP
# SPDX-License-Identifier: Apache-2.0

if SHIELD_ZC143AC72MIPI
if LVGL

# Enable double buffering
# config LV_Z_DOUBLE_VDB
# default y

# config LV_Z_BITS_PER_PIXEL
# default 16

endif # LVGL

if INPUT
# config ---
endif # INPUT

endif # SHIELD_ZC143AC72MIPI
5 changes: 5 additions & 0 deletions boards/shields/zc143ac72mipi/Kconfig.shield
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Copyright 2025 NXP
# SPDX-License-Identifier: Apache-2.0

config SHIELD_ZC143AC72MIPI
def_bool $(shields_list_contains,zc143ac72mipi)
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
CONFIG_REGULATOR=y
CONFIG_DCACHE=n
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
/*
* Copyright 2025 NXP
*
* SPDX-License-Identifier: Apache-2.0
*/

#include <zephyr/dt-bindings/mipi_dbi/mipi_dbi.h>
#include <zephyr/dt-bindings/display/panel.h>

&zephyr_lcdif {
status = "okay";
clock-frequency = <279000000>;
wr-period = <14>;
wr-assert = <6>;
wr-deassert = <13>;
cs-assert = <1>;
cs-deassert = <4>;
};
2 changes: 2 additions & 0 deletions boards/shields/zc143ac72mipi/doc/index.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#EMPTY DOC FOR NOW

6 changes: 6 additions & 0 deletions boards/shields/zc143ac72mipi/shield.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
shields:
- name: zc143ac72mipi
full_name: --- ZC143AC72 MIPI LCD Module
vendor: ---
supported_features:
- display
73 changes: 73 additions & 0 deletions boards/shields/zc143ac72mipi/zc143ac72mipi.overlay
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
/*
* Copyright 2025 NXP
*
* SPDX-License-Identifier: Apache-2.0
*/

/ {
chosen {
zephyr,display = &co5300_zc143ac72mipi;
// zephyr,touch = &tma525b_zc143ac72mipi;
};

/*
en_mipi_display_g1120b0mipi: enable-mipi-display {
compatible = "regulator-fixed";
regulator-name = "en_mipi_display";
enable-gpio = <&nxp_mipi_connector 32 GPIO_ACTIVE_HIGH>;
regulator-boot-on;
};

lvgl_pointer {
compatible = "zephyr,lvgl-pointer-input";
input = <&ft3267_zc143ac72mipi>;
display = <&co5300_zc143ac72mipi>;
invert-y;
};
*/
};
/*
&nxp_mipi_i2c {
status = "okay";

tma525b_zc143ac72mipi: tma525b@24 {
/*
* Note- the actual controller present on this IC is a FT3267,
* but the FT35336 driver in Zephyr supports this IC.
*/
/*
compatible = "focaltech,tma525b";
reg = <0x24>;
int-gpio = <&nxp_mipi_connector 29 GPIO_ACTIVE_LOW>;
reset-gpio = <&nxp_mipi_connector 28 GPIO_ACTIVE_LOW>;
};
};
*/

&zephyr_mipi_dsi {
status = "okay";
autoinsert-eotp;
phy-clock = <319488000>;

co5300_zc143ac72mipi: co5300@0 {
status = "okay";
compatible = "chipone,co5300";
reg = <0x0>;
reset-gpios = <&nxp_mipi_connector 21 GPIO_ACTIVE_HIGH>;
backlight-gpios = <&nxp_mipi_connector 34 GPIO_ACTIVE_HIGH>;
tear-effect-gpios = <&nxp_mipi_connector 22 GPIO_ACTIVE_HIGH>;
power-gpios = <&nxp_mipi_connector 32 GPIO_ACTIVE_HIGH>;
data-lanes = <1>;
width = <466>;
height = <466>;
pixel-format = <MIPI_DSI_PIXFMT_RGB565>;
};
};

&gpio1 {
status = "okay";
};

&gpio3 {
status = "okay";
};
1 change: 1 addition & 0 deletions drivers/display/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ zephyr_library_sources_ifdef(CONFIG_RENESAS_RA_GLCDC display_renesas_ra.c)
zephyr_library_sources_ifdef(CONFIG_ILI9806E_DSI display_ili9806e_dsi.c)
zephyr_library_sources_ifdef(CONFIG_ST7701 display_st7701.c)
zephyr_library_sources_ifdef(CONFIG_LPM013M126 display_lpm013m126.c)
zephyr_library_sources_ifdef(CONFIG_CO5300 display_co5300.c)

zephyr_library_sources_ifdef(CONFIG_MICROBIT_DISPLAY
mb_display.c
Expand Down
1 change: 1 addition & 0 deletions drivers/display/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -60,5 +60,6 @@ source "drivers/display/Kconfig.renesas_ra"
source "drivers/display/Kconfig.ili9806e_dsi"
source "drivers/display/Kconfig.st7701"
source "drivers/display/Kconfig.lpm013m126"
source "drivers/display/Kconfig.co5300"

endif # DISPLAY
15 changes: 15 additions & 0 deletions drivers/display/Kconfig.co5300
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Copyright 2025 NXP
# SPDX-License-Identifier: Apache-2.0


config CO5300
bool "MCUX ---"
default y
select MIPI_DSI
depends on DT_HAS_CHIPONE_CO5300_ENABLED
help
---


if CO5300
endif # CO5300
Loading
Loading