Hi NXP Team,
We are working on a custom board with the i.MX8MP processor and are trying to establish SPI communication with an LED board connected via the following pins:
We have the following device tree configuration:
269 &ecspi1 {
270 pinctrl-names = "default";
271 pinctrl-0 = <&pinctrl_ecspi1>;
272 status = "okay";
273
274 leds-gpio@1 {
275 compatible = "custom,leds-gpio"; /* Update to your specific LED driver */
276 reg = <1>; /* SPI chip select 0 */
278 spi-max-frequency = <1200000>; /* 1 MHz */
279 status = "okay";
282 leds {
283 compatible = "spi,rgb-leds";
284 led-names = "red", "green", "blue";
285 led-count = <8>; /* Adjust based on the number of LEDs */
286 };
287 };
288 };
1154 pinctrl_ecspi1: ecspi1grp {
1155 fsl,pins = <
1157 MX8MP_IOMUXC_ECSPI1_MOSI__ECSPI1_MOSI 0x00
1158 MX8MP_IOMUXC_ECSPI1_MISO__ECSPI1_MISO 0x00
1159 >;
1160 };
No Chip Select (CS) or SCLK Connection
The LED board is only connected to the MISO and MOSI pins, without a CS pin or SCLK connection. Can SPI communication be achieved with only these two pins?
Driver Initialization
The SPI driver initializes without errors, as seen in the logs:
Device Testing Fails
The device appears under /sys/bus/spi/devices/spi1.0:
However, when attempting to test the device using spidev_test, it fails:
No LEDs in /sys/class/leds
The LEDs are not exposed under /sys/class/leds, and I cannot control them directly:
Any guidance or suggestions would be greatly appreciated.
Thank you,
Hello,
Both CS and SCLK are typically essential, along with MOSI and MISO. Without these, the communication protocol would not function correctly.
Best Regards,
Zhiming