IMX6ULEVK ECSPI no react

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

IMX6ULEVK ECSPI no react

730 Views
kr90911
Contributor III

Hi Everyone,

I need spi device on IMX6ULEVK as master to transfer command to peripheral chip.

There are spidev0.0/spidev2.0/spidev3.0 under my /dev now.

I test these port with three ways:

spidev_test.c

echo "hello" > /dev/spidev0.0

mxc_spi_test1.out

I probed CLK/CS/MOSI pins with oscilloscope,found that CLK nerver go high,CS、MOSI go high and nerver go low after I test these port with above ways.

ECSPIx.CONREG.CHANNEL_MODE will turned 0x0/0x1 into 0xf after the tests.

I tried many ways on nxp forum,but I still can't use ECSPI port normally.

Attached is my device tree files,could anyone give me some advice?

Labels (1)
0 Kudos
3 Replies

630 Views
kr90911
Contributor III

Hi all,

The problem solved after I changed my oscilloscope.

My original device tree is work.

0 Kudos

630 Views
igorpadykov
NXP Employee
NXP Employee

Hi west

one can test with Demo Image

Linux Binary Demo Files - i.MX 6UltraLite, i.MX 6ULL, i.MX 7Dual

dts spidev example :

imx6ul-14x14-evk-ecspi.dts\dts\boot\arm\arch - linux-imx - i.MX Linux kernel 

Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos

630 Views
kr90911
Contributor III

Hi igor,

thanks for your reply.

The ECSPI device still not work on IMX6ULEVK.

I burn rootfs from Yocto image-core-base,and replaced zImage and device tree to your attach files,then boot kernel with imx6ul-14x14-evk-ecspi.dtb.

There are spidev0.0 and spidev 3.0(ECSPI4) under /dev,I test spidev3.0 with echo and spidev_test.c.

I probe ECSPI4 CLK pin(R1734),and CLK go low and never high after I test with echo.

The program spidev_test.c can't execute with follow message:

root@imx6ulevk:~# /usr/bin/spitest -D /dev/spidev3.0 -v

spi mode: 0x0imx-sdma 20ec000.sdma: sdma firmware not ready!

bits per word: 8
max speed: 50spidev spi3.0: SPI transfer failed: -22
0000 Hz (500 KHz)
spi_master spi3: failed to transfer one message from queue
can't send spi message: Invalid argument
Aborted (core dumped)

I have seen the message "failed to transfer one message from queue"  before and I deal with it,but ECSPI still no reaction when I execute the test program.

 

Could you give me some further instructions?

0 Kudos