Customer would like set SCLK_POL & SCLK_PHA in ECSPIx_CONFIGREG. There is an function mx51_ecspi_config in kernel driver can do this. How to pass parameter (spi_imx_config->mode
) to this function in correct way? By device tree or other way?
Solved! Go to Solution.
What version of Kernel are you using? or are you planning to use?
If a version 3.10 or latest you need to do it by device tree, if 2.6 it is your version need to it, directly in the driver instance.
You can use SPIDEV in your application.
https://www.kernel.org/doc/Documentation/spi/spidev_test.c
https://www.kernel.org/doc/Documentation/spi/spidev
Have a great day,
Jaime
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
What version of Kernel are you using? or are you planning to use?
If a version 3.10 or latest you need to do it by device tree, if 2.6 it is your version need to it, directly in the driver instance.
You can use SPIDEV in your application.
https://www.kernel.org/doc/Documentation/spi/spidev_test.c
https://www.kernel.org/doc/Documentation/spi/spidev
Have a great day,
Jaime
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
Android KK 4.4.3 2.0.0.
Customer would like to set SPI mode 3 (POL=1 & PHA=1).